sanity 5.0.2-next.2 → 5.1.0-next.10

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/lib/index.js CHANGED
@@ -3022,6 +3022,9 @@ function _isSanityDocumentTypeDefinition(def) {
3022
3022
  function _isCustomDocumentTypeDefinition(def) {
3023
3023
  return def.type === "document" && !_isSanityDocumentTypeDefinition(def);
3024
3024
  }
3025
+ function _isType(schemaType, typeName) {
3026
+ return schemaType.name === typeName ? !0 : schemaType.type ? _isType(schemaType.type, typeName) : !1;
3027
+ }
3025
3028
  const GROQ_KEYWORDS = ["match", "in", "asc", "desc", "true", "false", "null"], VALID_FIELD = /^[a-zA-Z_][a-zA-Z0-9_]*$/, fieldNeedsEscape = (fieldName) => !VALID_FIELD.test(fieldName) || GROQ_KEYWORDS.includes(fieldName), escapeField = (fieldName) => `["${fieldName}"]`, escapeFirst = (fieldName) => `@${escapeField(fieldName)}`, isEmptyArray = (value) => Array.isArray(value) && value.length === 0, joinPath = (pathArray) => {
3026
3029
  let path = "";
3027
3030
  for (let i = 0; i < pathArray.length; i++) {
@@ -3174,9 +3177,9 @@ function useGetI18nText(input) {
3174
3177
  }, $[4] = t, $[5] = t2) : t2 = $[5], t2;
3175
3178
  }
3176
3179
  function _temp2$1I(item) {
3177
- return item?.i18n ? Object.values(item.i18n).map(_temp$49) : [];
3180
+ return item?.i18n ? Object.values(item.i18n).map(_temp$4a) : [];
3178
3181
  }
3179
- function _temp$49(t0) {
3182
+ function _temp$4a(t0) {
3180
3183
  const {
3181
3184
  ns
3182
3185
  } = t0;
@@ -3192,7 +3195,7 @@ function useI18nText(node) {
3192
3195
  break bb0;
3193
3196
  }
3194
3197
  let t12;
3195
- $[1] !== node.i18n ? (t12 = Array.from(new Set(Object.values(node.i18n).map(_temp$48))).sort(), $[1] = node.i18n, $[2] = t12) : t12 = $[2], t0 = t12;
3198
+ $[1] !== node.i18n ? (t12 = Array.from(new Set(Object.values(node.i18n).map(_temp$49))).sort(), $[1] = node.i18n, $[2] = t12) : t12 = $[2], t0 = t12;
3196
3199
  }
3197
3200
  const namespaces = t0, {
3198
3201
  t
@@ -3230,7 +3233,7 @@ function useI18nText(node) {
3230
3233
  }
3231
3234
  return t1;
3232
3235
  }
3233
- function _temp$48(t0) {
3236
+ function _temp$49(t0) {
3234
3237
  const {
3235
3238
  ns
3236
3239
  } = t0;
@@ -3513,7 +3516,7 @@ function useEnsureMediaLibrary(props2) {
3513
3516
  bb0: {
3514
3517
  const handleDefault = defaultIfEmpty({
3515
3518
  status: "inactive"
3516
- }), handleError = catchError$1(_temp$47);
3519
+ }), handleError = catchError$1(_temp$48);
3517
3520
  if (props2.from === "library") {
3518
3521
  let t23;
3519
3522
  $[6] !== props2.libraryId ? (t23 = (organizationId) => ({
@@ -3544,7 +3547,7 @@ function useEnsureMediaLibrary(props2) {
3544
3547
  status: "loading"
3545
3548
  }, $[10] = t2) : t2 = $[10], useObservable(observable, t2);
3546
3549
  }
3547
- function _temp$47(error) {
3550
+ function _temp$48(error) {
3548
3551
  if (error instanceof ProvisionError)
3549
3552
  return of({
3550
3553
  status: "error",
@@ -7710,7 +7713,7 @@ function useDocumentValuePermissions(t0) {
7710
7713
  document: document2,
7711
7714
  permission
7712
7715
  });
7713
- return subscriptionRef.current = permissions$.pipe(distinctUntilChanged$1(_temp$46)).subscribe({
7716
+ return subscriptionRef.current = permissions$.pipe(distinctUntilChanged$1(_temp$47)).subscribe({
7714
7717
  next: (value) => dispatch({
7715
7718
  type: "value",
7716
7719
  value
@@ -7724,7 +7727,7 @@ function useDocumentValuePermissions(t0) {
7724
7727
  };
7725
7728
  }, t2 = [grantsStore, document2, permission], $[0] = document2, $[1] = grantsStore, $[2] = permission, $[3] = t1, $[4] = t2) : (t1 = $[3], t2 = $[4]), useEffect(t1, t2), state;
7726
7729
  }
7727
- function _temp$46(prev, next) {
7730
+ function _temp$47(prev, next) {
7728
7731
  return isEqual$2(prev, next);
7729
7732
  }
7730
7733
  function refCountDelay(duration, scheduler = asapScheduler) {
@@ -8947,7 +8950,7 @@ function useTimelineStore(t0) {
8947
8950
  }, $[32] = t10, $[33] = t11, $[34] = t13, $[35] = t9, $[36] = t14) : t14 = $[36], t14;
8948
8951
  }
8949
8952
  function _temp3$J(innerController_0) {
8950
- const chunks = innerController_0.timeline.mapChunks(_temp$45), lastNonDeletedChunk = chunks.filter(_temp2$1H), hasMoreChunks = !innerController_0.timeline.reachedEarliestEntry;
8953
+ const chunks = innerController_0.timeline.mapChunks(_temp$46), lastNonDeletedChunk = chunks.filter(_temp2$1H), hasMoreChunks = !innerController_0.timeline.reachedEarliestEntry;
8951
8954
  hasMoreChunks && chunks.length > 16 && innerController_0.setLoadMore(!1);
8952
8955
  const timelineReady = !["invalid", "loading"].includes(innerController_0.selectionState);
8953
8956
  return {
@@ -8970,7 +8973,7 @@ function _temp3$J(innerController_0) {
8970
8973
  function _temp2$1H(chunk_1) {
8971
8974
  return !["delete", "initial"].includes(chunk_1.type);
8972
8975
  }
8973
- function _temp$45(c2) {
8976
+ function _temp$46(c2) {
8974
8977
  return c2;
8975
8978
  }
8976
8979
  const handleIncomingMessage = (event) => {
@@ -9283,11 +9286,11 @@ function createMultiKeyWeakMap() {
9283
9286
  function ResourceCacheProvider(t0) {
9284
9287
  const $ = c(3), {
9285
9288
  children
9286
- } = t0, [resourceCache] = useState(_temp$44);
9289
+ } = t0, [resourceCache] = useState(_temp$45);
9287
9290
  let t1;
9288
9291
  return $[0] !== children || $[1] !== resourceCache ? (t1 = /* @__PURE__ */ jsx(ResourceCacheContext.Provider, { value: resourceCache, children }), $[0] = children, $[1] = resourceCache, $[2] = t1) : t1 = $[2], t1;
9289
9292
  }
9290
- function _temp$44() {
9293
+ function _temp$45() {
9291
9294
  const namespaces = /* @__PURE__ */ new Map(), nullReplacer = {}, emptyDependenciesReplacer = [nullReplacer], removeNullDependencies = (dependencies) => dependencies.length ? dependencies.map((dep) => dep === null ? nullReplacer : dep) : emptyDependenciesReplacer;
9292
9295
  return {
9293
9296
  get: (t0) => {
@@ -9568,25 +9571,25 @@ function useComlinkStore() {
9568
9571
  }
9569
9572
  const initial$1 = [], fallback$1 = of(initial$1);
9570
9573
  function useDocumentPresence(documentId) {
9571
- const $ = c(6), [mounted, mount] = useReducer(_temp$43, !1);
9574
+ const $ = c(6), [mounted, mount] = useReducer(_temp$44, !1);
9572
9575
  let t0, t1;
9573
9576
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => startTransition(mount), t1 = [], $[0] = t0, $[1] = t1) : (t0 = $[0], t1 = $[1]), useEffect(t0, t1);
9574
9577
  const presenceStore = usePresenceStore();
9575
9578
  let t2;
9576
9579
  return $[2] !== documentId || $[3] !== mounted || $[4] !== presenceStore ? (t2 = mounted ? presenceStore.documentPresence(documentId) : fallback$1, $[2] = documentId, $[3] = mounted, $[4] = presenceStore, $[5] = t2) : t2 = $[5], useObservable(t2, initial$1);
9577
9580
  }
9578
- function _temp$43() {
9581
+ function _temp$44() {
9579
9582
  return !0;
9580
9583
  }
9581
9584
  const initial = [], fallback = of(initial);
9582
9585
  function useGlobalPresence() {
9583
- const $ = c(2), [mounted, mount] = useReducer(_temp$42, !1);
9586
+ const $ = c(2), [mounted, mount] = useReducer(_temp$43, !1);
9584
9587
  let t0, t1;
9585
9588
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => startTransition(mount), t1 = [], $[0] = t0, $[1] = t1) : (t0 = $[0], t1 = $[1]), useEffect(t0, t1);
9586
9589
  const presenceStore = usePresenceStore();
9587
9590
  return useObservable(mounted ? presenceStore.globalPresence$ : fallback, initial);
9588
9591
  }
9589
- function _temp$42() {
9592
+ function _temp$43() {
9590
9593
  return !0;
9591
9594
  }
9592
9595
  function EventsProvider(t0) {
@@ -10767,7 +10770,7 @@ function useRelativeTime(time, t0) {
10767
10770
  const $ = c(5);
10768
10771
  let t1;
10769
10772
  $[0] !== t0 ? (t1 = t0 === void 0 ? {} : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
10770
- const options = t1, [now, updateNow] = useReducer(_temp$41, null, _temp2$1G), resolved = useFormatRelativeTime(time, options.relativeTo || now, options);
10773
+ const options = t1, [now, updateNow] = useReducer(_temp$42, null, _temp2$1G), resolved = useFormatRelativeTime(time, options.relativeTo || now, options);
10771
10774
  let t2, t3;
10772
10775
  return $[2] !== resolved.refreshInterval ? (t2 = () => {
10773
10776
  let timerId;
@@ -10784,7 +10787,7 @@ function useRelativeTime(time, t0) {
10784
10787
  function _temp2$1G() {
10785
10788
  return Date.now();
10786
10789
  }
10787
- function _temp$41() {
10790
+ function _temp$42() {
10788
10791
  return Date.now();
10789
10792
  }
10790
10793
  function useFormatRelativeTime(date, now, t0) {
@@ -11099,7 +11102,7 @@ const IconBox$1 = styled(Flex)((props2) => {
11099
11102
  let t2;
11100
11103
  $[2] !== t1 ? (t2 = /* @__PURE__ */ jsx(Box, { padding: 1, paddingBottom: 2, children: /* @__PURE__ */ jsx(Text$1, { size: 1, weight: "medium", children: t1 }) }), $[2] = t1, $[3] = t2) : t2 = $[3];
11101
11104
  let t3;
11102
- $[4] !== collaborators ? (t3 = collaborators.map(_temp$40), $[4] = collaborators, $[5] = t3) : t3 = $[5];
11105
+ $[4] !== collaborators ? (t3 = collaborators.map(_temp$41), $[4] = collaborators, $[5] = t3) : t3 = $[5];
11103
11106
  let t4;
11104
11107
  return $[6] !== t2 || $[7] !== t3 ? (t4 = /* @__PURE__ */ jsxs(Stack, { paddingBottom: 1, children: [
11105
11108
  t2,
@@ -11195,7 +11198,7 @@ function Event$1(t0) {
11195
11198
  t23
11196
11199
  ] }), $[52] = t22, $[53] = t23, $[54] = t24) : t24 = $[54], t24;
11197
11200
  }
11198
- function _temp$40(userId) {
11201
+ function _temp$41(userId) {
11199
11202
  return /* @__PURE__ */ jsx(UserLine, { userId }, userId);
11200
11203
  }
11201
11204
  function DiffTooltip(props2) {
@@ -11244,7 +11247,7 @@ function DiffTooltipWithAnnotation(props2) {
11244
11247
  let t2;
11245
11248
  $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, weight: "medium", children: t1 }), $[9] = t1, $[10] = t2) : t2 = $[10];
11246
11249
  let t3;
11247
- $[11] !== annotations ? (t3 = annotations.map(_temp$3$), $[11] = annotations, $[12] = t3) : t3 = $[12];
11250
+ $[11] !== annotations ? (t3 = annotations.map(_temp$40), $[11] = annotations, $[12] = t3) : t3 = $[12];
11248
11251
  let t4;
11249
11252
  $[13] !== t3 ? (t4 = /* @__PURE__ */ jsx(Stack, { space: 2, children: t3 }), $[13] = t3, $[14] = t4) : t4 = $[14];
11250
11253
  let t5;
@@ -11256,7 +11259,7 @@ function DiffTooltipWithAnnotation(props2) {
11256
11259
  let t6;
11257
11260
  return $[18] !== children || $[19] !== content || $[20] !== restProps ? (t6 = /* @__PURE__ */ jsx(LegacyLayerProvider, { zOffset: "paneFooter", children: /* @__PURE__ */ jsx(Tooltip, { content, portal: !0, ...restProps, children }) }), $[18] = children, $[19] = content, $[20] = restProps, $[21] = t6) : t6 = $[21], t6;
11258
11261
  }
11259
- function _temp$3$(annotation, idx) {
11262
+ function _temp$40(annotation, idx) {
11260
11263
  return /* @__PURE__ */ jsx(AnnotationItem, { annotation }, idx);
11261
11264
  }
11262
11265
  function AnnotationItem(t0) {
@@ -12109,7 +12112,7 @@ const SizeDiff = styled.div`
12109
12112
  $[2] !== fields ? (t3 = Object.entries(fields).filter((t42) => {
12110
12113
  const [name, field] = t42;
12111
12114
  return field.isChanged && !ignoredFields.includes(name);
12112
- }).map(_temp$3_), $[2] = fields, $[3] = t3) : t3 = $[3];
12115
+ }).map(_temp$3$), $[2] = fields, $[3] = t3) : t3 = $[3];
12113
12116
  const changedFields = t3, didAssetChange = changedFields.includes("asset");
12114
12117
  let t4;
12115
12118
  if ($[4] !== changedFields || $[5] !== schemaType.fields) {
@@ -12168,7 +12171,7 @@ const SizeDiff = styled.div`
12168
12171
  t15
12169
12172
  ] }), $[50] = t14, $[51] = t15, $[52] = t16) : t16 = $[52], t16;
12170
12173
  };
12171
- function _temp$3_(t0) {
12174
+ function _temp$3$(t0) {
12172
12175
  const [name_0] = t0;
12173
12176
  return name_0;
12174
12177
  }
@@ -12430,7 +12433,7 @@ const IMAGE_META_FIELDS = ["crop", "hotspot"], BASE_IMAGE_FIELDS = ["asset", "me
12430
12433
  let t4;
12431
12434
  if ($[7] !== changedFields || $[8] !== schemaType.fields) {
12432
12435
  let t52;
12433
- $[10] !== changedFields ? (t52 = (field) => !BASE_IMAGE_FIELDS.includes(field.name) && changedFields.includes(field.name), $[10] = changedFields, $[11] = t52) : t52 = $[11], t4 = schemaType.fields.filter(t52).map(_temp$3Z), $[7] = changedFields, $[8] = schemaType.fields, $[9] = t4;
12436
+ $[10] !== changedFields ? (t52 = (field) => !BASE_IMAGE_FIELDS.includes(field.name) && changedFields.includes(field.name), $[10] = changedFields, $[11] = t52) : t52 = $[11], t4 = schemaType.fields.filter(t52).map(_temp$3_), $[7] = changedFields, $[8] = schemaType.fields, $[9] = t4;
12434
12437
  } else
12435
12438
  t4 = $[9];
12436
12439
  const nestedFields = t4;
@@ -12479,7 +12482,7 @@ function getChangeDescription(action, t) {
12479
12482
  return "Unknown change";
12480
12483
  }
12481
12484
  }
12482
- function _temp$3Z(field_0) {
12485
+ function _temp$3_(field_0) {
12483
12486
  return field_0.name;
12484
12487
  }
12485
12488
  const NumberWrapper = styled.div`
@@ -13747,7 +13750,7 @@ function DiffInspectWrapper(props2) {
13747
13750
  } = props2, $[0] = props2, $[1] = as, $[2] = change, $[3] = children, $[4] = restProps) : (as = $[1], change = $[2], children = $[3], restProps = $[4]);
13748
13751
  const isHovering = useRef(!1), [isInspecting, setIsInspecting] = useState(!1);
13749
13752
  let t0;
13750
- $[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setIsInspecting(_temp$3Y), $[5] = t0) : t0 = $[5];
13753
+ $[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setIsInspecting(_temp$3Z), $[5] = t0) : t0 = $[5];
13751
13754
  const toggleInspect = t0;
13752
13755
  let t1;
13753
13756
  $[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => isHovering.current = !0, $[6] = t1) : t1 = $[6];
@@ -13771,7 +13774,7 @@ function DiffInspectWrapper(props2) {
13771
13774
  let t6;
13772
13775
  return $[14] !== as || $[15] !== restProps || $[16] !== t5 ? (t6 = /* @__PURE__ */ jsx(Box, { as, onMouseEnter: handleMouseEnter, onMouseLeave: handleMouseLeave, ...restProps, children: t5 }), $[14] = as, $[15] = restProps, $[16] = t5, $[17] = t6) : t6 = $[17], t6;
13773
13776
  }
13774
- function _temp$3Y(state) {
13777
+ function _temp$3Z(state) {
13775
13778
  return !state;
13776
13779
  }
13777
13780
  const MetaLabel = (t0) => {
@@ -14175,7 +14178,7 @@ function FieldChange(props2) {
14175
14178
  }, $[17] = t7) : t7 = $[17];
14176
14179
  const handleRevertButtonMouseLeave = t7;
14177
14180
  let t8;
14178
- $[18] !== change.parentSchema ? (t8 = change.parentSchema?.jsonType === "array" && !change.parentSchema.of.some(_temp$3X), $[18] = change.parentSchema, $[19] = t8) : t8 = $[19];
14181
+ $[18] !== change.parentSchema ? (t8 = change.parentSchema?.jsonType === "array" && !change.parentSchema.of.some(_temp$3Y), $[18] = change.parentSchema, $[19] = t8) : t8 = $[19];
14179
14182
  const isArray2 = t8;
14180
14183
  let t9;
14181
14184
  $[20] !== change.path || $[21] !== isArray2 ? (t9 = isArray2 ? change.path.slice(0, -1) : change.path, $[20] = change.path, $[21] = isArray2, $[22] = t9) : t9 = $[22];
@@ -14216,7 +14219,7 @@ function FieldChange(props2) {
14216
14219
  t21
14217
14220
  ] }), $[65] = t20, $[66] = t21, $[67] = t22) : t22 = $[67], t22;
14218
14221
  }
14219
- function _temp$3X(ofType) {
14222
+ function _temp$3Y(ofType) {
14220
14223
  return ofType.type?.name === "block";
14221
14224
  }
14222
14225
  const ChangeListWrapper = styled.div`
@@ -14275,7 +14278,7 @@ function GroupChange(props2) {
14275
14278
  isComparingCurrent
14276
14279
  } = useDocumentChange(), FieldWrapper2 = t0 === void 0 ? Fragment : t0;
14277
14280
  let t1;
14278
- $[5] !== changes ? (t1 = changes.every(_temp$3W), $[5] = changes, $[6] = t1) : t1 = $[6];
14281
+ $[5] !== changes ? (t1 = changes.every(_temp$3X), $[5] = changes, $[6] = t1) : t1 = $[6];
14279
14282
  const isPortableText2 = t1;
14280
14283
  let t2;
14281
14284
  $[7] !== diffPath || $[8] !== groupPath ? (t2 = pathsAreEqual(diffPath, groupPath), $[7] = diffPath, $[8] = groupPath, $[9] = t2) : t2 = $[9];
@@ -14330,7 +14333,7 @@ function GroupChange(props2) {
14330
14333
  function _temp2$1E(ofType) {
14331
14334
  return ofType.name === "block";
14332
14335
  }
14333
- function _temp$3W(change) {
14336
+ function _temp$3X(change) {
14334
14337
  return isFieldChange(change) && isPTSchemaType(change.schemaType);
14335
14338
  }
14336
14339
  function useHover(node) {
@@ -14525,7 +14528,7 @@ function ChangesError(t0) {
14525
14528
  $[8] !== error || $[9] !== revisionNotFoundError || $[10] !== t ? (t5 = revisionNotFoundError && /* @__PURE__ */ jsx(Box, { paddingTop: 2, children: /* @__PURE__ */ jsx(Text$1, { as: "p", size: 1, muted: !0, children: /* @__PURE__ */ jsx(Translate, { i18nKey: "changes.missing-since-document-error", t, values: {
14526
14529
  revisionId: error.revisionId
14527
14530
  }, components: {
14528
- Break: _temp$3V
14531
+ Break: _temp$3W
14529
14532
  } }) }) }), $[8] = error, $[9] = revisionNotFoundError, $[10] = t, $[11] = t5) : t5 = $[11];
14530
14533
  let t6;
14531
14534
  return $[12] !== t2 || $[13] !== t4 || $[14] !== t5 ? (t6 = /* @__PURE__ */ jsx(Card, { tone: "caution", padding: 3, children: /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
@@ -14534,7 +14537,7 @@ function ChangesError(t0) {
14534
14537
  t5
14535
14538
  ] }) }), $[12] = t2, $[13] = t4, $[14] = t5, $[15] = t6) : t6 = $[15], t6;
14536
14539
  }
14537
- function _temp$3V() {
14540
+ function _temp$3W() {
14538
14541
  return /* @__PURE__ */ jsx("br", {});
14539
14542
  }
14540
14543
  const RoundedCard = styled.span`
@@ -14616,11 +14619,11 @@ function DiffString(props2) {
14616
14619
  let t0;
14617
14620
  $[0] !== diff.segments ? (t0 = diff.segments || [], $[0] = diff.segments, $[1] = t0) : t0 = $[1];
14618
14621
  let t1;
14619
- $[2] !== t0 ? (t1 = t0.map(_temp$3U), $[2] = t0, $[3] = t1) : t1 = $[3];
14622
+ $[2] !== t0 ? (t1 = t0.map(_temp$3V), $[2] = t0, $[3] = t1) : t1 = $[3];
14620
14623
  let t2;
14621
14624
  return $[4] !== t1 ? (t2 = /* @__PURE__ */ jsx(Fragment$1, { children: t1 }), $[4] = t1, $[5] = t2) : t2 = $[5], t2;
14622
14625
  }
14623
- function _temp$3U(segment, segmentIndex) {
14626
+ function _temp$3V(segment, segmentIndex) {
14624
14627
  return /* @__PURE__ */ jsx(DiffStringSegment, { segment }, segmentIndex);
14625
14628
  }
14626
14629
  const MetaText = styled(Text$1)`
@@ -14701,7 +14704,7 @@ const ArrayOfOptionsFieldDiff = (t0) => {
14701
14704
  ] }) }),
14702
14705
  /* @__PURE__ */ jsx(Flex, { align: "center", children: /* @__PURE__ */ jsx(ItemPreview, { value: title || value, memberType }) })
14703
14706
  ] }, getItemKey(diff, index));
14704
- }, $[8] = colorManager, $[9] = diff, $[10] = t, $[11] = t3) : t3 = $[11], t1 = diff.items.map(t22).filter(_temp$3T).sort(sortItems).map(t3), $[0] = colorManager, $[1] = diff, $[2] = schemaType, $[3] = t, $[4] = t1;
14707
+ }, $[8] = colorManager, $[9] = diff, $[10] = t, $[11] = t3) : t3 = $[11], t1 = diff.items.map(t22).filter(_temp$3U).sort(sortItems).map(t3), $[0] = colorManager, $[1] = diff, $[2] = schemaType, $[3] = t, $[4] = t1;
14705
14708
  } else
14706
14709
  t1 = $[4];
14707
14710
  let t2;
@@ -14771,7 +14774,7 @@ function getItemTitle(item, schemaType) {
14771
14774
  const list = schemaType.options?.list || [], index = getOptionIndex(item, schemaType);
14772
14775
  return index === -1 ? void 0 : list[index].title || void 0;
14773
14776
  }
14774
- function _temp$3T(item_0) {
14777
+ function _temp$3U(item_0) {
14775
14778
  return item_0 !== null;
14776
14779
  }
14777
14780
  const SlugWrapper = styled.div`
@@ -14947,12 +14950,12 @@ function useChildValidation(path, t0) {
14947
14950
  let t1;
14948
14951
  if ($[0] !== inclusive || $[1] !== path || $[2] !== validation2) {
14949
14952
  let t2;
14950
- $[4] !== inclusive || $[5] !== path ? (t2 = (item) => startsWith(path, item.path) && (inclusive || !isEqual$3(path, item.path)), $[4] = inclusive, $[5] = path, $[6] = t2) : t2 = $[6], t1 = validation2.filter(t2).map(_temp$3S), $[0] = inclusive, $[1] = path, $[2] = validation2, $[3] = t1;
14953
+ $[4] !== inclusive || $[5] !== path ? (t2 = (item) => startsWith(path, item.path) && (inclusive || !isEqual$3(path, item.path)), $[4] = inclusive, $[5] = path, $[6] = t2) : t2 = $[6], t1 = validation2.filter(t2).map(_temp$3T), $[0] = inclusive, $[1] = path, $[2] = validation2, $[3] = t1;
14951
14954
  } else
14952
14955
  t1 = $[3];
14953
14956
  return t1;
14954
14957
  }
14955
- function _temp$3S(marker) {
14958
+ function _temp$3T(marker) {
14956
14959
  return {
14957
14960
  message: marker.message,
14958
14961
  level: marker.level,
@@ -15452,7 +15455,7 @@ const DefaultAnnotationComponent = (props2) => {
15452
15455
  selected,
15453
15456
  textElement,
15454
15457
  validation: validation2
15455
- } = props2, isLink = schemaType.name === "link", hasError = validation2.some(_temp$3R), hasWarning = validation2.some(_temp2$1D), hasMarkers = markers.length > 0, isReady = !!children, {
15458
+ } = props2, isLink = schemaType.name === "link", hasError = validation2.some(_temp$3S), hasWarning = validation2.some(_temp2$1D), hasMarkers = markers.length > 0, isReady = !!children, {
15456
15459
  t
15457
15460
  } = useTranslation();
15458
15461
  let t0;
@@ -15483,7 +15486,7 @@ const DefaultAnnotationComponent = (props2) => {
15483
15486
  t7
15484
15487
  ] }), $[15] = t1, $[16] = t2, $[17] = t3, $[18] = t4, $[19] = t5, $[20] = t6, $[21] = t7, $[22] = textElement, $[23] = toneKey, $[24] = t8) : t8 = $[24], t8;
15485
15488
  };
15486
- function _temp$3R(v) {
15489
+ function _temp$3S(v) {
15487
15490
  return v.level === "error";
15488
15491
  }
15489
15492
  function _temp2$1D(v_0) {
@@ -15506,7 +15509,7 @@ function createStore(reportedValues, publish2) {
15506
15509
  };
15507
15510
  }
15508
15511
  function useTrackerStore() {
15509
- const $ = c(9), [reportedValues] = useState(_temp$3Q);
15512
+ const $ = c(9), [reportedValues] = useState(_temp$3R);
15510
15513
  let t0;
15511
15514
  $[0] !== reportedValues ? (t0 = () => Array.from(reportedValues.entries()), $[0] = reportedValues, $[1] = t0) : t0 = $[1];
15512
15515
  let t1;
@@ -15526,7 +15529,7 @@ function useTrackerStore() {
15526
15529
  snapshot: snapshot2
15527
15530
  }, $[6] = snapshot2, $[7] = store, $[8] = t4) : t4 = $[8], t4;
15528
15531
  }
15529
- function _temp$3Q() {
15532
+ function _temp$3R() {
15530
15533
  return /* @__PURE__ */ new Map();
15531
15534
  }
15532
15535
  function useTrackerStoreReporter(store, id2, value, t0) {
@@ -15572,7 +15575,7 @@ const useChangeIndicatorsReporter = (id2, value, isEqual2) => {
15572
15575
  function useHoveredChange() {
15573
15576
  const $ = c(2), reportedValues = useChangeIndicatorsReportedValues();
15574
15577
  let t0;
15575
- $[0] !== reportedValues ? (t0 = reportedValues.filter(_temp$3P).sort(_temp2$1C), $[0] = reportedValues, $[1] = t0) : t0 = $[1];
15578
+ $[0] !== reportedValues ? (t0 = reportedValues.filter(_temp$3Q).sort(_temp2$1C), $[0] = reportedValues, $[1] = t0) : t0 = $[1];
15576
15579
  const hoveredEntry = t0[0];
15577
15580
  if (hoveredEntry) {
15578
15581
  const [, change_0] = hoveredEntry;
@@ -15582,7 +15585,7 @@ function useHoveredChange() {
15582
15585
  function _temp2$1C(a, b) {
15583
15586
  return b[1].path.length - a[1].path.length;
15584
15587
  }
15585
- function _temp$3P(t0) {
15588
+ function _temp$3Q(t0) {
15586
15589
  const [, change] = t0;
15587
15590
  return change.hasHover;
15588
15591
  }
@@ -15798,7 +15801,7 @@ const FieldActionMenu = memo(function(props2) {
15798
15801
  $[4] !== nodes ? (t2 = nodes.filter(renderAsButton), $[4] = nodes, $[5] = t2) : t2 = $[5];
15799
15802
  const buttonNodes = t2;
15800
15803
  let t3;
15801
- $[6] !== nodes ? (t3 = nodes.filter(_temp$3O), $[6] = nodes, $[7] = t3) : t3 = $[7];
15804
+ $[6] !== nodes ? (t3 = nodes.filter(_temp$3P), $[6] = nodes, $[7] = t3) : t3 = $[7];
15802
15805
  const menuNodesProp = t3;
15803
15806
  let t4;
15804
15807
  bb0: {
@@ -15883,7 +15886,7 @@ function RootFieldActionMenuGroup(props2) {
15883
15886
  let t6;
15884
15887
  return $[10] !== onClose || $[11] !== onOpen || $[12] !== t2 || $[13] !== t3 || $[14] !== t5 ? (t6 = /* @__PURE__ */ jsx(MenuButton, { button: t2, id: t3, menu: t5, onOpen, onClose, popover: ROOT_MENU_BUTTON_POPOVER_PROPS }), $[10] = onClose, $[11] = onOpen, $[12] = t2, $[13] = t3, $[14] = t5, $[15] = t6) : t6 = $[15], t6;
15885
15888
  }
15886
- function _temp$3O(node) {
15889
+ function _temp$3P(node) {
15887
15890
  return !renderAsButton(node);
15888
15891
  }
15889
15892
  function useHoveredField() {
@@ -15988,7 +15991,7 @@ const FieldActionsResolver = memo(function(props2) {
15988
15991
  t6 = $[15];
15989
15992
  const FieldActions = t6;
15990
15993
  let t7;
15991
- $[21] !== FieldActions ? (t7 = FieldActions.map(_temp$3N), $[21] = FieldActions, $[22] = t7) : t7 = $[22];
15994
+ $[21] !== FieldActions ? (t7 = FieldActions.map(_temp$3O), $[21] = FieldActions, $[22] = t7) : t7 = $[22];
15992
15995
  let t8;
15993
15996
  return $[23] !== t7 ? (t8 = /* @__PURE__ */ jsx(Fragment$1, { children: t7 }), $[23] = t7, $[24] = t8) : t8 = $[24], t8;
15994
15997
  });
@@ -16020,7 +16023,7 @@ function defineFieldActionComponent({
16020
16023
  }, t2 = [node], $[1] = node, $[2] = t1, $[3] = t2) : (t1 = $[2], t2 = $[3]), useEffect(t1, t2), null;
16021
16024
  });
16022
16025
  }
16023
- function _temp$3N(FieldAction, key) {
16026
+ function _temp$3O(FieldAction, key) {
16024
16027
  return /* @__PURE__ */ jsx(FieldAction, {}, key);
16025
16028
  }
16026
16029
  function useFieldActions() {
@@ -16029,7 +16032,7 @@ function useFieldActions() {
16029
16032
  const HoveredFieldProvider = memo(function(props2) {
16030
16033
  const $ = c(17), {
16031
16034
  children
16032
- } = props2, [listeners] = useState(_temp$3M);
16035
+ } = props2, [listeners] = useState(_temp$3N);
16033
16036
  let t0;
16034
16037
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = [], $[0] = t0) : t0 = $[0];
16035
16038
  const hoveredStackRef = useRef(t0);
@@ -16075,7 +16078,7 @@ const HoveredFieldProvider = memo(function(props2) {
16075
16078
  let t7;
16076
16079
  return $[14] !== children || $[15] !== context ? (t7 = /* @__PURE__ */ jsx(HoveredFieldContext.Provider, { value: context, children }), $[14] = children, $[15] = context, $[16] = t7) : t7 = $[16], t7;
16077
16080
  });
16078
- function _temp$3M() {
16081
+ function _temp$3N() {
16079
16082
  return /* @__PURE__ */ new Set();
16080
16083
  }
16081
16084
  function useDidUpdate(current, didUpdate, t0) {
@@ -16229,7 +16232,7 @@ function ImageOrFileField(field) {
16229
16232
  const $ = c(32), [fieldActionsNodes, setFieldActionNodes] = useState(EMPTY_ARRAY$x), documentId = usePublishedId$1(), focused = !!field.inputProps.focused;
16230
16233
  let t0;
16231
16234
  if ($[0] !== field.inputProps.members || $[1] !== field.presence) {
16232
- const hotspotField = field.inputProps.members.find(_temp$3L);
16235
+ const hotspotField = field.inputProps.members.find(_temp$3M);
16233
16236
  t0 = hotspotField?.open ? field.presence : field.presence.concat(hotspotField?.field.presence || EMPTY_ARRAY$x), $[0] = field.inputProps.members, $[1] = field.presence, $[2] = t0;
16234
16237
  } else
16235
16238
  t0 = $[2];
@@ -16246,7 +16249,7 @@ function ImageOrFileField(field) {
16246
16249
  t3
16247
16250
  ] }), $[29] = t1, $[30] = t3, $[31] = t4) : t4 = $[31], t4;
16248
16251
  }
16249
- function _temp$3L(member) {
16252
+ function _temp$3M(member) {
16250
16253
  return member.kind === "field" && member.name === "hotspot";
16251
16254
  }
16252
16255
  function defaultResolveFieldComponent(schemaType) {
@@ -16864,7 +16867,7 @@ function useSearchMaxFieldDepth(overrideClient) {
16864
16867
  client
16865
16868
  }).pipe(shareReplay()));
16866
16869
  let t1;
16867
- $[2] !== dataset ? (t1 = cachedSettings.get(dataset).pipe(map(_temp$3K), startWith(INITIAL_LOADING_STATE$5), catchError(_temp2$1B)), $[2] = dataset, $[3] = t1) : t1 = $[3];
16870
+ $[2] !== dataset ? (t1 = cachedSettings.get(dataset).pipe(map(_temp$3L), startWith(INITIAL_LOADING_STATE$5), catchError(_temp2$1B)), $[2] = dataset, $[3] = t1) : t1 = $[3];
16868
16871
  const maxFieldDepth = useObservable(t1, INITIAL_LOADING_STATE$5)?.settings?.partialIndexSettings?.maxFieldDepth;
16869
16872
  return isFinite(maxFieldDepth) ? Math.min(maxFieldDepth, DEFAULT_MAX_FIELD_DEPTH) : DEFAULT_MAX_FIELD_DEPTH;
16870
16873
  }
@@ -16879,7 +16882,7 @@ function _temp2$1B(err) {
16879
16882
  }
16880
16883
  });
16881
16884
  }
16882
- function _temp$3K(settings) {
16885
+ function _temp$3L(settings) {
16883
16886
  return {
16884
16887
  isLoading: !1,
16885
16888
  settings
@@ -17023,7 +17026,7 @@ function CreateButton(props2) {
17023
17026
  const currentUser = useCurrentUser(), {
17024
17027
  t
17025
17028
  } = useTranslation(), getI18nText = useGetI18nText(createOptions);
17026
- if (!createOptions.some(_temp$3J)) {
17029
+ if (!createOptions.some(_temp$3K)) {
17027
17030
  let t02;
17028
17031
  $[6] !== currentUser ? (t02 = /* @__PURE__ */ jsx(InsufficientPermissionsMessage, { currentUser, context: "create-new-reference" }), $[6] = currentUser, $[7] = t02) : t02 = $[7];
17029
17032
  let t1;
@@ -17036,7 +17039,7 @@ function CreateButton(props2) {
17036
17039
  let t0;
17037
17040
  return $[15] !== createOptions || $[16] !== currentUser || $[17] !== getI18nText || $[18] !== id2 || $[19] !== menuRef || $[20] !== onCreate || $[21] !== props2.readOnly || $[22] !== rest || $[23] !== t ? (t0 = createOptions.length > 1 ? /* @__PURE__ */ jsx(MenuButton, { button: /* @__PURE__ */ jsx(Button, { ...rest, disabled: props2.readOnly, text: t("inputs.reference.action.create-new-document-select"), mode: "ghost", icon: AddIcon, size: "large" }), id: id2, menu: /* @__PURE__ */ jsx(Menu, { ref: menuRef, children: createOptions.map((createOption) => /* @__PURE__ */ jsx(Tooltip, { disabled: createOption.permission.granted, content: /* @__PURE__ */ jsx(InsufficientPermissionsMessage, { currentUser, context: "create-document-type" }), portal: !0, "data-testid": `create-new-document-select-${createOption.title.toLowerCase().replaceAll(" ", "-")}-selectTypeMenuButton`, children: /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(MenuItem, { disabled: !createOption.permission.granted, icon: createOption.icon, text: getI18nText(createOption).title, onClick: () => onCreate(createOption), "data-testid": `create-new-document-select-${createOption.title.toLowerCase().replaceAll(" ", "-")}-selectTypeMenuItem` }) }) }, createOption.id)) }), popover: POPOVER_PROPS$5 }) : /* @__PURE__ */ jsx(Button, { ...rest, text: t("inputs.reference.action.create-new-document-select"), mode: "ghost", disabled: !createOptions[0].permission.granted || props2.readOnly, onClick: () => onCreate(createOptions[0]), icon: AddIcon, size: "large", "data-testid": `create-new-document-select-${id2}` }), $[15] = createOptions, $[16] = currentUser, $[17] = getI18nText, $[18] = id2, $[19] = menuRef, $[20] = onCreate, $[21] = props2.readOnly, $[22] = rest, $[23] = t, $[24] = t0) : t0 = $[24], t0;
17038
17041
  }
17039
- function _temp$3J(option) {
17042
+ function _temp$3K(option) {
17040
17043
  return option.permission.granted;
17041
17044
  }
17042
17045
  function sortReleases(releases2 = []) {
@@ -17078,7 +17081,7 @@ function useActiveReleases() {
17078
17081
  dispatch
17079
17082
  } = useReleasesStore(), state = useObservable(state$);
17080
17083
  let t0;
17081
- $[0] !== state.releases ? (t0 = sortReleases(Array.from(state.releases.values()).filter(_temp$3I)).reverse(), $[0] = state.releases, $[1] = t0) : t0 = $[1];
17084
+ $[0] !== state.releases ? (t0 = sortReleases(Array.from(state.releases.values()).filter(_temp$3J)).reverse(), $[0] = state.releases, $[1] = t0) : t0 = $[1];
17082
17085
  const releasesAsArray = t0, t1 = state.error;
17083
17086
  let t2;
17084
17087
  $[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = ["loading", "initialising"], $[2] = t2) : t2 = $[2];
@@ -17091,7 +17094,7 @@ function useActiveReleases() {
17091
17094
  loading: t3
17092
17095
  }, $[3] = dispatch, $[4] = releasesAsArray, $[5] = state.error, $[6] = t3, $[7] = t4) : t4 = $[7], t4;
17093
17096
  }
17094
- function _temp$3I(release) {
17097
+ function _temp$3J(release) {
17095
17098
  return !ARCHIVED_RELEASE_STATES.includes(release.state);
17096
17099
  }
17097
17100
  const Dot$2 = styled.div((props2) => {
@@ -17179,7 +17182,7 @@ function DocumentStatusIndicator(t0) {
17179
17182
  $[13] !== t11 || $[14] !== t13 || $[15] !== t5 || $[16] !== t7 || $[17] !== t9 ? (t14 = [t5, t7, t9, t11, t13], $[13] = t11, $[14] = t13, $[15] = t5, $[16] = t7, $[17] = t9, $[18] = t14) : t14 = $[18];
17180
17183
  const indicators = t14;
17181
17184
  let t15;
17182
- return $[19] !== indicators ? (t15 = /* @__PURE__ */ jsx(Flex, { children: indicators.filter(_temp$3H).map(_temp2$1A) }), $[19] = indicators, $[20] = t15) : t15 = $[20], t15;
17185
+ return $[19] !== indicators ? (t15 = /* @__PURE__ */ jsx(Flex, { children: indicators.filter(_temp$3I).map(_temp2$1A) }), $[19] = indicators, $[20] = t15) : t15 = $[20], t15;
17183
17186
  }
17184
17187
  function _temp2$1A(t0, index) {
17185
17188
  const {
@@ -17187,7 +17190,7 @@ function _temp2$1A(t0, index) {
17187
17190
  } = t0;
17188
17191
  return /* @__PURE__ */ jsx(Dot$2, { "data-status": status, $index: index + 1 }, status);
17189
17192
  }
17190
- function _temp$3H(t0) {
17193
+ function _temp$3I(t0) {
17191
17194
  const {
17192
17195
  show
17193
17196
  } = t0;
@@ -17323,7 +17326,7 @@ function PreviewReferenceValue$2(props2) {
17323
17326
  if ($[13] !== value._strengthenOnPublish?.type ? (t62 = (toType) => toType.name === value?._strengthenOnPublish?.type, $[13] = value._strengthenOnPublish?.type, $[14] = t62) : t62 = $[14], refType = t12.find(t62), !refType) {
17324
17327
  const t72 = value._ref, t82 = value._strengthenOnPublish?.type;
17325
17328
  let t92;
17326
- $[15] !== type.to ? (t92 = type.to.map(_temp$3G), $[15] = type.to, $[16] = t92) : t92 = $[16];
17329
+ $[15] !== type.to ? (t92 = type.to.map(_temp$3H), $[15] = type.to, $[16] = t92) : t92 = $[16];
17327
17330
  let t10;
17328
17331
  $[17] !== t82 || $[18] !== t92 || $[19] !== value._ref ? (t10 = /* @__PURE__ */ jsx(InvalidType, { documentId: t72, actualType: t82, declaredTypes: t92 }), $[17] = t82, $[18] = t92, $[19] = value._ref, $[20] = t10) : t10 = $[20], t5 = t10;
17329
17332
  break bb0;
@@ -17393,7 +17396,7 @@ function PreviewReferenceValue$2(props2) {
17393
17396
  function _temp2$1z(toType_2) {
17394
17397
  return toType_2.name;
17395
17398
  }
17396
- function _temp$3G(toType_0) {
17399
+ function _temp$3H(toType_0) {
17397
17400
  return toType_0.name;
17398
17401
  }
17399
17402
  function UnavailableMessage(props2) {
@@ -17506,7 +17509,7 @@ function Details(props2) {
17506
17509
  } = props2, $[0] = props2, $[1] = children, $[2] = icon, $[3] = openProp, $[4] = restProps, $[5] = t0) : (children = $[1], icon = $[2], openProp = $[3], restProps = $[4], t0 = $[5]);
17507
17510
  const title = t0 === void 0 ? "Details" : t0, [open, setOpen] = useState(openProp || !1);
17508
17511
  let t1;
17509
- $[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => setOpen(_temp$3F), $[6] = t1) : t1 = $[6];
17512
+ $[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => setOpen(_temp$3G), $[6] = t1) : t1 = $[6];
17510
17513
  const handleToggle = t1;
17511
17514
  let t2, t3;
17512
17515
  $[7] !== openProp ? (t2 = () => setOpen(openProp || !1), t3 = [openProp], $[7] = openProp, $[8] = t2, $[9] = t3) : (t2 = $[8], t3 = $[9]), useEffect(t2, t3);
@@ -17534,7 +17537,7 @@ function Details(props2) {
17534
17537
  t11
17535
17538
  ] }), $[26] = restProps, $[27] = t11, $[28] = t9, $[29] = t12) : t12 = $[29], t12;
17536
17539
  }
17537
- function _temp$3F(v) {
17540
+ function _temp$3G(v) {
17538
17541
  return !v;
17539
17542
  }
17540
17543
  const STATUS_TONES = {
@@ -17689,7 +17692,7 @@ const noop$4 = () => {
17689
17692
  retry: noop$4
17690
17693
  };
17691
17694
  function useReferenceInfo$2(id2, getReferenceInfo2) {
17692
- const $ = c(10), [t0] = useState(_temp$3E), [onRetry$2, onRetry2] = t0;
17695
+ const $ = c(10), [t0] = useState(_temp$3F), [onRetry$2, onRetry2] = t0;
17693
17696
  let t1;
17694
17697
  if ($[0] !== getReferenceInfo2 || $[1] !== id2 || $[2] !== onRetry2 || $[3] !== onRetry$2) {
17695
17698
  let t2;
@@ -17710,7 +17713,7 @@ function useReferenceInfo$2(id2, getReferenceInfo2) {
17710
17713
  t1 = $[4];
17711
17714
  return useObservable(t1, INITIAL_LOADING_STATE$4);
17712
17715
  }
17713
- function _temp$3E() {
17716
+ function _temp$3F() {
17714
17717
  return observableCallback();
17715
17718
  }
17716
17719
  const READABLE = {
@@ -17836,7 +17839,7 @@ function useReferenceInput(options) {
17836
17839
  let t72;
17837
17840
  if ($[22] !== initialValueTemplateItems || $[23] !== schemaType.to) {
17838
17841
  let t82;
17839
- $[25] !== schemaType.to ? (t82 = (i) => schemaType.to.some((refType) => refType.name === i.template?.schemaType), $[25] = schemaType.to, $[26] = t82) : t82 = $[26], t72 = (initialValueTemplateItems || []).filter(t82).map(_temp$3D).filter(isNonNullable$3), $[22] = initialValueTemplateItems, $[23] = schemaType.to, $[24] = t72;
17842
+ $[25] !== schemaType.to ? (t82 = (i) => schemaType.to.some((refType) => refType.name === i.template?.schemaType), $[25] = schemaType.to, $[26] = t82) : t82 = $[26], t72 = (initialValueTemplateItems || []).filter(t82).map(_temp$3E).filter(isNonNullable$3), $[22] = initialValueTemplateItems, $[23] = schemaType.to, $[24] = t72;
17840
17843
  } else
17841
17844
  t72 = $[24];
17842
17845
  t6 = t72;
@@ -17855,7 +17858,7 @@ function useReferenceInput(options) {
17855
17858
  getReferenceInfo: getReferenceInfo$1
17856
17859
  }, $[31] = EditReferenceLink, $[32] = createOptions, $[33] = getReferenceInfo$1, $[34] = handleEditReference, $[35] = isCurrentDocumentLiveEdit, $[36] = selectedState, $[37] = t8) : t8 = $[37], t8;
17857
17860
  }
17858
- function _temp$3D(item) {
17861
+ function _temp$3E(item) {
17859
17862
  return item.template?.schemaType ? {
17860
17863
  id: item.id,
17861
17864
  title: item.title || `${item.template.schemaType} from template ${item.template.id}`,
@@ -17915,7 +17918,7 @@ function ReferenceInputPreview(props2) {
17915
17918
  $[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = (hadFocus, hasFocus) => {
17916
17919
  !hadFocus && hasFocus && elementRef.current && elementRef.current.focus();
17917
17920
  }, $[6] = t2) : t2 = $[6], useDidUpdate(focused, t2);
17918
- const hasErrors = props2.validation.some(_temp$3C), hasWarnings = props2.validation.some(_temp2$1y), loadableReferenceInfo = useReferenceInfo$2(value?._ref, getReferenceInfo2), refTypeName = loadableReferenceInfo.result?.type || value?._strengthenOnPublish?.type;
17921
+ const hasErrors = props2.validation.some(_temp$3D), hasWarnings = props2.validation.some(_temp2$1y), loadableReferenceInfo = useReferenceInfo$2(value?._ref, getReferenceInfo2), refTypeName = loadableReferenceInfo.result?.type || value?._strengthenOnPublish?.type;
17919
17922
  let t3;
17920
17923
  $[7] !== refTypeName || $[8] !== schemaType.to ? (t3 = refTypeName ? schemaType.to.find((toType) => toType.name === refTypeName) : void 0, $[7] = refTypeName, $[8] = schemaType.to, $[9] = t3) : t3 = $[9];
17921
17924
  const refType = t3, pressed = selectedState === "pressed", selected = selectedState === "selected", hasRef = value?._ref, publishedReferenceExists = hasRef && loadableReferenceInfo.result?.isPublished;
@@ -18009,7 +18012,7 @@ function ReferenceInputPreview(props2) {
18009
18012
  function _temp2$1y(v_0) {
18010
18013
  return v_0.level === "warning";
18011
18014
  }
18012
- function _temp$3C(v) {
18015
+ function _temp$3D(v) {
18013
18016
  return v.level === "error";
18014
18017
  }
18015
18018
  function useReferenceItemRef() {
@@ -18125,7 +18128,7 @@ function ReferenceInput(props2) {
18125
18128
  hits: [],
18126
18129
  searchString,
18127
18130
  isLoading: !1
18128
- })))))), scan(_temp$3B, INITIAL_SEARCH_STATE$3), tap(setSearchState)), $[24] = id2, $[25] = onSearch, $[26] = push, $[27] = t, $[28] = t5) : t5 = $[28];
18131
+ })))))), scan(_temp$3C, INITIAL_SEARCH_STATE$3), tap(setSearchState)), $[24] = id2, $[25] = onSearch, $[26] = push, $[27] = t, $[28] = t5) : t5 = $[28];
18129
18132
  const handleQueryChange = useObservableEvent(t5);
18130
18133
  let t6;
18131
18134
  $[29] !== handleQueryChange ? (t6 = () => {
@@ -18204,7 +18207,7 @@ function _temp2$1x(hit_0) {
18204
18207
  hit: hit_0
18205
18208
  };
18206
18209
  }
18207
- function _temp$3B(prevState, nextState) {
18210
+ function _temp$3C(prevState, nextState) {
18208
18211
  return {
18209
18212
  ...prevState,
18210
18213
  ...nextState
@@ -18371,9 +18374,9 @@ function _temp2$1w(t0) {
18371
18374
  const {
18372
18375
  hits
18373
18376
  } = t0;
18374
- return hits.map(_temp$3A);
18377
+ return hits.map(_temp$3B);
18375
18378
  }
18376
- function _temp$3A(t0) {
18379
+ function _temp$3B(t0) {
18377
18380
  const {
18378
18381
  hit
18379
18382
  } = t0;
@@ -18604,7 +18607,7 @@ function ArrayOfObjectsItem(props2) {
18604
18607
  $[14] !== handleOpenItem || $[15] !== member.item.path || $[16] !== member.key || $[17] !== member.parentSchemaType || $[18] !== onChange || $[19] !== onPathFocus || $[20] !== resolveInitialValue2 || $[21] !== t || $[22] !== telemetryInsertSiblingsTelemetry || $[23] !== toast ? (t4 = (event_0) => {
18605
18608
  if (event_0.items.length === 0)
18606
18609
  throw new Error("Insert event should include at least one item");
18607
- const itemsWithKeys = event_0.items.map(_temp$3z);
18610
+ const itemsWithKeys = event_0.items.map(_temp$3A);
18608
18611
  onChange(PatchEvent.from([insert$1(itemsWithKeys, event_0.position, [{
18609
18612
  _key: member.key
18610
18613
  }])]));
@@ -18784,7 +18787,7 @@ function ArrayOfObjectsItem(props2) {
18784
18787
  let t29;
18785
18788
  return $[163] !== handleChange || $[164] !== onFieldGroupSelect || $[165] !== onPathBlur || $[166] !== onPathFocus || $[167] !== onPathOpen || $[168] !== onSetFieldSetCollapsed || $[169] !== onSetPathCollapsed || $[170] !== t28 ? (t29 = /* @__PURE__ */ jsx(FormCallbacksProvider, { onFieldGroupSelect, onChange: handleChange, onPathOpen, onSetFieldSetCollapsed, onSetPathCollapsed, onPathBlur, onPathFocus, children: t28 }), $[163] = handleChange, $[164] = onFieldGroupSelect, $[165] = onPathBlur, $[166] = onPathFocus, $[167] = onPathOpen, $[168] = onSetFieldSetCollapsed, $[169] = onSetPathCollapsed, $[170] = t28, $[171] = t29) : t29 = $[171], t29;
18786
18789
  }
18787
- function _temp$3z(item) {
18790
+ function _temp$3A(item) {
18788
18791
  return ensureKey(item);
18789
18792
  }
18790
18793
  function RenderInput$5({
@@ -18829,7 +18832,7 @@ function IncompatibleItemType$2(props2) {
18829
18832
  const handleKeyDown = t2;
18830
18833
  let t3;
18831
18834
  $[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = () => {
18832
- setShowDetails(_temp$3y);
18835
+ setShowDetails(_temp$3z);
18833
18836
  }, $[7] = t3) : t3 = $[7];
18834
18837
  const handleShowDetails = t3;
18835
18838
  let t4;
@@ -18898,7 +18901,7 @@ function IncompatibleItemType$2(props2) {
18898
18901
  let t24;
18899
18902
  return $[56] !== showDetails || $[57] !== t19 || $[58] !== t23 ? (t24 = /* @__PURE__ */ jsx(Popover, { open: showDetails, ref: popoverRef, onKeyDown: handleKeyDown, portal: !0, constrainSize: !0, tone: "default", content: t19, children: t23 }), $[56] = showDetails, $[57] = t19, $[58] = t23, $[59] = t24) : t24 = $[59], t24;
18900
18903
  }
18901
- function _temp$3y(v) {
18904
+ function _temp$3z(v) {
18902
18905
  return !v;
18903
18906
  }
18904
18907
  function MemberItemError(props2) {
@@ -19694,7 +19697,7 @@ function ArrayOfObjectsField(props2) {
19694
19697
  let t7;
19695
19698
  $[12] !== member.name || $[13] !== onChange ? (t7 = (event_1) => {
19696
19699
  const patches = PatchEvent.from(event_1).patches;
19697
- if (patches.some(_temp$3x) && (valueRef.current = applyAll(valueRef.current || [], patches), Array.isArray(valueRef.current) && !valueRef.current.length)) {
19700
+ if (patches.some(_temp$3y) && (valueRef.current = applyAll(valueRef.current || [], patches), Array.isArray(valueRef.current) && !valueRef.current.length)) {
19698
19701
  onChange(PatchEvent.from(unset([member.name])));
19699
19702
  return;
19700
19703
  }
@@ -19964,7 +19967,7 @@ function _temp3$G(_file) {
19964
19967
  function _temp2$1v(item) {
19965
19968
  return ensureKey(item);
19966
19969
  }
19967
- function _temp$3x(patch2) {
19970
+ function _temp$3y(patch2) {
19968
19971
  return patch2.type === "unset" && patch2.path.length === 1;
19969
19972
  }
19970
19973
  function RenderInput$3({
@@ -20055,7 +20058,7 @@ function ArrayOfPrimitivesField(props2) {
20055
20058
  let t3;
20056
20059
  $[7] !== member.field.value || $[8] !== member.name || $[9] !== onChange ? (t3 = (event_1) => {
20057
20060
  const patches = PatchEvent.from(event_1).patches;
20058
- if (patches.some(_temp$3w)) {
20061
+ if (patches.some(_temp$3x)) {
20059
20062
  const result = applyAll(member.field.value || [], patches);
20060
20063
  if (Array.isArray(result) && !result.length) {
20061
20064
  onChange(PatchEvent.from(unset([member.name])));
@@ -20201,7 +20204,7 @@ function ArrayOfPrimitivesField(props2) {
20201
20204
  function _temp2$1u(uploadProgressEvent) {
20202
20205
  return PatchEvent.from(uploadProgressEvent.patches || []);
20203
20206
  }
20204
- function _temp$3w(patch2) {
20207
+ function _temp$3x(patch2) {
20205
20208
  return patch2.type === "unset" && patch2.path.length === 1;
20206
20209
  }
20207
20210
  function RenderInput$2({
@@ -20453,7 +20456,7 @@ function PrimitiveField(props2) {
20453
20456
  }, $[23] = handleBlur, $[24] = handleFocus, $[25] = handleNativeChange, $[26] = member.field.id, $[27] = member.field.schemaType.placeholder, $[28] = t10, $[29] = t7, $[30] = t8, $[31] = t11) : t11 = $[31];
20454
20457
  const elementProps = t11;
20455
20458
  let t12;
20456
- $[32] !== member.field.validation ? (t12 = member.field.validation.filter(_temp$3v).map(_temp2$1t).join(`
20459
+ $[32] !== member.field.validation ? (t12 = member.field.validation.filter(_temp$3w).map(_temp2$1t).join(`
20457
20460
  `) || void 0, $[32] = member.field.validation, $[33] = t12) : t12 = $[33];
20458
20461
  const validationError = t12, t13 = member.field.value, t14 = member.field.schemaType, t15 = member.field.displayInlineChanges ?? !1;
20459
20462
  let t16;
@@ -20485,7 +20488,7 @@ function PrimitiveField(props2) {
20485
20488
  function _temp2$1t(item_0) {
20486
20489
  return item_0.message;
20487
20490
  }
20488
- function _temp$3v(item) {
20491
+ function _temp$3w(item) {
20489
20492
  return item.level === "error";
20490
20493
  }
20491
20494
  function RenderInput({
@@ -20665,7 +20668,7 @@ function UntypedValueInput(t0) {
20665
20668
  let t6;
20666
20669
  $[13] !== isSingleValidType || $[14] !== t ? (t6 = !isSingleValidType && /* @__PURE__ */ jsx(Text$1, { as: "p", muted: !0, size: 1, children: t("inputs.untyped-value.details.multi-type-description") }), $[13] = isSingleValidType, $[14] = t, $[15] = t6) : t6 = $[15];
20667
20670
  let t7;
20668
- $[16] !== isSingleValidType || $[17] !== validTypes ? (t7 = !isSingleValidType && /* @__PURE__ */ jsx(Stack, { as: "ul", space: 2, children: validTypes.map(_temp$3u) }), $[16] = isSingleValidType, $[17] = validTypes, $[18] = t7) : t7 = $[18];
20671
+ $[16] !== isSingleValidType || $[17] !== validTypes ? (t7 = !isSingleValidType && /* @__PURE__ */ jsx(Stack, { as: "ul", space: 2, children: validTypes.map(_temp$3v) }), $[16] = isSingleValidType, $[17] = validTypes, $[18] = t7) : t7 = $[18];
20669
20672
  let t8;
20670
20673
  $[19] !== t ? (t8 = t("inputs.untyped-value.details.json-dump-prefix"), $[19] = t, $[20] = t8) : t8 = $[20];
20671
20674
  let t9;
@@ -20704,7 +20707,7 @@ function UntypedValueInput(t0) {
20704
20707
  let t19;
20705
20708
  return $[53] !== t18 || $[54] !== t2 ? (t19 = /* @__PURE__ */ jsx(Alert, { status: "warning", title: t2, children: t18 }), $[53] = t18, $[54] = t2, $[55] = t19) : t19 = $[55], t19;
20706
20709
  }
20707
- function _temp$3u(validType) {
20710
+ function _temp$3v(validType) {
20708
20711
  return /* @__PURE__ */ jsx(Text$1, { as: "li", muted: !0, size: 1, children: /* @__PURE__ */ jsx("code", { children: validType }) }, validType);
20709
20712
  }
20710
20713
  function getConverters(value, actualType, validTypes) {
@@ -20818,11 +20821,11 @@ function ConvertButton(t0) {
20818
20821
  let t3;
20819
20822
  return $[7] !== handleClick || $[8] !== t2 ? (t3 = /* @__PURE__ */ jsx(Button, { onClick: handleClick, text: t2 }), $[7] = handleClick, $[8] = t2, $[9] = t3) : t3 = $[9], t3;
20820
20823
  }
20821
- function _temp$3t() {
20824
+ function _temp$3u() {
20822
20825
  }
20823
20826
  function _temp2$1s() {
20824
20827
  return {
20825
- focus: _temp$3t
20828
+ focus: _temp$3u
20826
20829
  };
20827
20830
  }
20828
20831
  function _temp3$F(validType) {
@@ -21061,7 +21064,7 @@ function FormFieldValidationStatus(props2) {
21061
21064
  __unstable_showSummary: showSummary,
21062
21065
  fontSize,
21063
21066
  placement
21064
- } = props2, validation2 = t0 === void 0 ? EMPTY_ARRAY$w : t0, hasErrors = validation2.some(_temp$3s), hasWarnings = validation2.some(_temp2$1r), status = hasErrors ? "error" : hasWarnings ? "warning" : "info", StatusIcon = VALIDATION_ICONS[status];
21067
+ } = props2, validation2 = t0 === void 0 ? EMPTY_ARRAY$w : t0, hasErrors = validation2.some(_temp$3t), hasWarnings = validation2.some(_temp2$1r), status = hasErrors ? "error" : hasWarnings ? "warning" : "info", StatusIcon = VALIDATION_ICONS[status];
21065
21068
  let t1;
21066
21069
  $[0] !== showSummary || $[1] !== validation2 ? (t1 = showSummary && /* @__PURE__ */ jsx(FormFieldValidationSummary, { validation: validation2 }), $[0] = showSummary, $[1] = validation2, $[2] = t1) : t1 = $[2];
21067
21070
  let t2;
@@ -21086,7 +21089,7 @@ function _temp3$E(item, itemIndex) {
21086
21089
  function _temp2$1r(v_0) {
21087
21090
  return v_0.level === "warning";
21088
21091
  }
21089
- function _temp$3s(v) {
21092
+ function _temp$3t(v) {
21090
21093
  return v.level === "error";
21091
21094
  }
21092
21095
  function FormFieldValidationStatusItem(props2) {
@@ -21499,7 +21502,7 @@ function DuplicateKeysAlert(props2) {
21499
21502
  } = props2;
21500
21503
  let t0;
21501
21504
  $[0] !== error.duplicates || $[1] !== onChange ? (t0 = () => {
21502
- onChange(PatchEvent.from((error.duplicates || []).map(_temp$3r)));
21505
+ onChange(PatchEvent.from((error.duplicates || []).map(_temp$3s)));
21503
21506
  }, $[0] = error.duplicates, $[1] = onChange, $[2] = t0) : t0 = $[2];
21504
21507
  const handleFixDuplicateKeys = t0, {
21505
21508
  t
@@ -21535,7 +21538,7 @@ function DuplicateKeysAlert(props2) {
21535
21538
  let t14;
21536
21539
  return $[31] !== error.schemaType.description || $[32] !== error.schemaType.title || $[33] !== t13 ? (t14 = /* @__PURE__ */ jsx(FormField, { title: t1, description: t2, children: t13 }), $[31] = error.schemaType.description, $[32] = error.schemaType.title, $[33] = t13, $[34] = t14) : t14 = $[34], t14;
21537
21540
  }
21538
- function _temp$3r(t0) {
21541
+ function _temp$3s(t0) {
21539
21542
  const [index, key] = t0;
21540
21543
  return set(`${key}_deduped_${index}`, [index, "_key"]);
21541
21544
  }
@@ -21546,7 +21549,7 @@ function MissingKeysAlert(props2) {
21546
21549
  } = props2;
21547
21550
  let t0;
21548
21551
  $[0] !== error.value || $[1] !== onChange ? (t0 = () => {
21549
- onChange(PatchEvent.from((error.value || []).map(_temp$3q)));
21552
+ onChange(PatchEvent.from((error.value || []).map(_temp$3r)));
21550
21553
  }, $[0] = error.value, $[1] = onChange, $[2] = t0) : t0 = $[2];
21551
21554
  const handleFixMissingKeys = t0, {
21552
21555
  t
@@ -21582,7 +21585,7 @@ function MissingKeysAlert(props2) {
21582
21585
  let t14;
21583
21586
  return $[31] !== error.schemaType.description || $[32] !== error.schemaType.title || $[33] !== t13 ? (t14 = /* @__PURE__ */ jsx(FormField, { title: t1, description: t2, children: t13 }), $[31] = error.schemaType.description, $[32] = error.schemaType.title, $[33] = t13, $[34] = t14) : t14 = $[34], t14;
21584
21587
  }
21585
- function _temp$3q(val, i) {
21588
+ function _temp$3r(val, i) {
21586
21589
  return setIfMissing(randomKey$1(), [i, "_key"]);
21587
21590
  }
21588
21591
  function MixedArrayAlert(props2) {
@@ -21592,7 +21595,7 @@ function MixedArrayAlert(props2) {
21592
21595
  } = props2;
21593
21596
  let t0;
21594
21597
  $[0] !== error.value || $[1] !== onChange ? (t0 = () => {
21595
- const patches = (error.value || []).flatMap(_temp$3p).reverse().map(_temp2$1q);
21598
+ const patches = (error.value || []).flatMap(_temp$3q).reverse().map(_temp2$1q);
21596
21599
  onChange(PatchEvent.from(patches));
21597
21600
  }, $[0] = error.value, $[1] = onChange, $[2] = t0) : t0 = $[2];
21598
21601
  const handleRemoveNonObjectValues = t0, {
@@ -21627,7 +21630,7 @@ function MixedArrayAlert(props2) {
21627
21630
  function _temp2$1q(index_0) {
21628
21631
  return unset([index_0]);
21629
21632
  }
21630
- function _temp$3p(item, index) {
21633
+ function _temp$3q(item, index) {
21631
21634
  return isPlainObject$1(item) ? [] : [index];
21632
21635
  }
21633
21636
  function MemberFieldError(props2) {
@@ -21950,7 +21953,7 @@ function fileTarget(Component2) {
21950
21953
  }, t6 = [pasteTarget, handlePaste], $[16] = handlePaste, $[17] = pasteTarget, $[18] = t5, $[19] = t6) : (t5 = $[18], t6 = $[19]), useEffect(t5, t6);
21951
21954
  let t7;
21952
21955
  $[20] !== emitFiles || $[21] !== onFiles || $[22] !== onFilesOut ? (t7 = (event_2) => {
21953
- if (enteredElements.current = [], Array.from(event_2.dataTransfer.items).map(_temp$3o).some(_temp2$1p))
21956
+ if (enteredElements.current = [], Array.from(event_2.dataTransfer.items).map(_temp$3p).some(_temp2$1p))
21954
21957
  return;
21955
21958
  event_2.preventDefault(), event_2.stopPropagation();
21956
21959
  const dataTransfer = event_2.nativeEvent.dataTransfer;
@@ -22012,7 +22015,7 @@ function select(el) {
22012
22015
  const sel = window.getSelection();
22013
22016
  sel?.removeAllRanges(), sel?.addRange(range2);
22014
22017
  }
22015
- function _temp$3o(item) {
22018
+ function _temp$3p(item) {
22016
22019
  return {
22017
22020
  type: item.type,
22018
22021
  kind: item.kind
@@ -22056,7 +22059,7 @@ function UploadDestinationPicker(props2) {
22056
22059
  onClose
22057
22060
  } = props2, {
22058
22061
  t
22059
- } = useTranslation(), assetSourcesWithUpload = assetSources.filter(_temp$3n);
22062
+ } = useTranslation(), assetSourcesWithUpload = assetSources.filter(_temp$3o);
22060
22063
  let t0;
22061
22064
  $[0] !== assetSources || $[1] !== onSelectAssetSource ? (t0 = (event) => {
22062
22065
  const sourceName2 = event.currentTarget.getAttribute("data-asset-source-name"), assetSource = assetSources.find((source) => source.name === sourceName2);
@@ -22090,7 +22093,7 @@ function UploadDestinationPicker(props2) {
22090
22093
  let t12;
22091
22094
  return $[16] !== T0 || $[17] !== onClose || $[18] !== t11 || $[19] !== t3 ? (t12 = /* @__PURE__ */ jsx(T0, { onClickOutside: onClose, onClose, id: t2, header: t3, width: t4, bodyHeight: t5, children: t11 }), $[16] = T0, $[17] = onClose, $[18] = t11, $[19] = t3, $[20] = t12) : t12 = $[20], t12;
22092
22095
  }
22093
- function _temp$3n(s) {
22096
+ function _temp$3o(s) {
22094
22097
  return !!s.Uploader;
22095
22098
  }
22096
22099
  const Overlay$2 = styled(Layer)`
@@ -22139,7 +22142,7 @@ function uploadTarget$1(Component2) {
22139
22142
  title: t("inputs.array.error.cannot-upload-unable-to-convert", {
22140
22143
  count: rejected.length
22141
22144
  }),
22142
- description: rejected.map(_temp$3m)
22145
+ description: rejected.map(_temp$3n)
22143
22146
  });
22144
22147
  }, $[10] = pushToast, $[11] = t, $[12] = t1) : t1 = $[12];
22145
22148
  const alertRejectedFiles = t1;
@@ -22231,7 +22234,7 @@ function uploadTarget$1(Component2) {
22231
22234
  });
22232
22235
  }
22233
22236
  function getFilesAndAssetSources(files, types, assetSourceDestinationName, formBuilder) {
22234
- const imageType = types.find((type) => type.name === "image"), fileType = types.find((type) => type.name === "file");
22237
+ const imageType = types.find((type) => _isType(type, "image")), fileType = types.find((type) => _isType(type, "file"));
22235
22238
  return files.map((file) => {
22236
22239
  const imageAssetSource = imageType && resolveUploadAssetSources(imageType, formBuilder, file).find((source) => !assetSourceDestinationName || source.name === assetSourceDestinationName) || null;
22237
22240
  if (imageType && file.type.startsWith("image/") && imageAssetSource)
@@ -22252,7 +22255,7 @@ function getFilesAndAssetSources(files, types, assetSourceDestinationName, formB
22252
22255
  };
22253
22256
  });
22254
22257
  }
22255
- function _temp$3m(task, i) {
22258
+ function _temp$3n(task, i) {
22256
22259
  return /* @__PURE__ */ jsxs(Flex, { gap: 2, padding: 2, children: [
22257
22260
  /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$1, { weight: "medium", children: task.file.name }) }),
22258
22261
  /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$1, { size: 1, children: [
@@ -22536,7 +22539,7 @@ function ArrayOfObjectsFunctions(props2) {
22536
22539
  let t6;
22537
22540
  $[18] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t6 = ["top"], $[18] = t6) : t6 = $[18];
22538
22541
  let t7;
22539
- $[19] !== props2.schemaType.options?.insertMenu?.views ? (t7 = props2.schemaType.options?.insertMenu?.views?.some(_temp$3l), $[19] = props2.schemaType.options?.insertMenu?.views, $[20] = t7) : t7 = $[20];
22542
+ $[19] !== props2.schemaType.options?.insertMenu?.views ? (t7 = props2.schemaType.options?.insertMenu?.views?.some(_temp$3m), $[19] = props2.schemaType.options?.insertMenu?.views, $[20] = t7) : t7 = $[20];
22540
22543
  let t8;
22541
22544
  $[21] !== gridElement || $[22] !== popoverToggleElement || $[23] !== t7 ? (t8 = {
22542
22545
  placement: "bottom",
@@ -22580,7 +22583,7 @@ function ArrayOfObjectsFunctions(props2) {
22580
22583
  children
22581
22584
  ] }), $[41] = children, $[42] = t11, $[43] = t12) : t12 = $[43], t12;
22582
22585
  }
22583
- function _temp$3l(view) {
22586
+ function _temp$3m(view) {
22584
22587
  return view.name === "grid";
22585
22588
  }
22586
22589
  const DragHandleButton = styled(Button)((props2) => {
@@ -22734,7 +22737,7 @@ function IncompatibleItemType$1(props2) {
22734
22737
  const handleKeyDown = t2;
22735
22738
  let t3;
22736
22739
  $[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = () => {
22737
- setShowDetails(_temp$3k);
22740
+ setShowDetails(_temp$3l);
22738
22741
  }, $[7] = t3) : t3 = $[7];
22739
22742
  const handleShowDetails = t3;
22740
22743
  let t4;
@@ -22800,7 +22803,7 @@ function IncompatibleItemType$1(props2) {
22800
22803
  let t23;
22801
22804
  return $[51] !== showDetails || $[52] !== t17 || $[53] !== t22 ? (t23 = /* @__PURE__ */ jsx(Popover, { open: showDetails, ref: popoverRef, onKeyDown: handleKeyDown, portal: !0, constrainSize: !0, tone: "default", content: t17, children: t22 }), $[51] = showDetails, $[52] = t17, $[53] = t22, $[54] = t23) : t23 = $[54], t23;
22802
22805
  }
22803
- function _temp$3k(v) {
22806
+ function _temp$3l(v) {
22804
22807
  return !v;
22805
22808
  }
22806
22809
  const MENU_POPOVER_PROPS$8 = {
@@ -22950,7 +22953,7 @@ function useDocumentPreview(props2) {
22950
22953
  viewOptions: {
22951
22954
  ordering
22952
22955
  }
22953
- }).pipe(map(_temp$3j), catchError(_temp2$1n)), $[3] = chosenPerspectiveStack, $[4] = observeForPreview, $[5] = ordering, $[6] = perspectiveStack, $[7] = previewValue, $[8] = schemaType, $[9] = t3;
22956
+ }).pipe(map(_temp$3k), catchError(_temp2$1n)), $[3] = chosenPerspectiveStack, $[4] = observeForPreview, $[5] = ordering, $[6] = perspectiveStack, $[7] = previewValue, $[8] = schemaType, $[9] = t3;
22954
22957
  } else
22955
22958
  t3 = $[9];
22956
22959
  t2 = t3;
@@ -22963,7 +22966,7 @@ function _temp2$1n(error) {
22963
22966
  error
22964
22967
  });
22965
22968
  }
22966
- function _temp$3j(event) {
22969
+ function _temp$3k(event) {
22967
22970
  return {
22968
22971
  isLoading: !1,
22969
22972
  value: event.snapshot || void 0
@@ -23270,7 +23273,7 @@ function useImageObjectUrl(url) {
23270
23273
  let t2, t3;
23271
23274
  return $[5] !== cacheKey || $[6] !== token || $[7] !== url ? (t2 = () => {
23272
23275
  if (!cacheKey) {
23273
- setState(_temp$3i);
23276
+ setState(_temp$3j);
23274
23277
  return;
23275
23278
  }
23276
23279
  let entry_0 = requestCache.get(cacheKey);
@@ -23283,7 +23286,7 @@ function useImageObjectUrl(url) {
23283
23286
  };
23284
23287
  }, t3 = [cacheKey, token, url], $[5] = cacheKey, $[6] = token, $[7] = url, $[8] = t2, $[9] = t3) : (t2 = $[8], t3 = $[9]), useEffect(t2, t3), state;
23285
23288
  }
23286
- function _temp$3i(prev) {
23289
+ function _temp$3j(prev) {
23287
23290
  return prev.objectUrl || prev.isLoading || prev.error ? IDLE_RESULT : prev;
23288
23291
  }
23289
23292
  const noop$3 = () => {
@@ -24211,7 +24214,7 @@ function FormInputInner(props2) {
24211
24214
  if ($[58] !== absolutePath || $[59] !== props2.members || $[60] !== props2.path || $[61] !== t) {
24212
24215
  t6 = /* @__PURE__ */ Symbol.for("react.early_return_sentinel");
24213
24216
  bb1: {
24214
- const childPath_0 = trimLeft(props2.path, absolutePath), fieldMember = props2.members.find((member_0) => member_0.kind == "field" && childPath_0[0] === member_0.name), fieldSetMember = props2.members.filter(_temp$3h).flatMap(_temp2$1m).find((m) => m.kind === "field" && m.name === childPath_0[0]);
24217
+ const childPath_0 = trimLeft(props2.path, absolutePath), fieldMember = props2.members.find((member_0) => member_0.kind == "field" && childPath_0[0] === member_0.name), fieldSetMember = props2.members.filter(_temp$3i).flatMap(_temp2$1m).find((m) => m.kind === "field" && m.name === childPath_0[0]);
24215
24218
  if (member_3 = fieldMember || fieldSetMember, !member_3) {
24216
24219
  const fieldName = typeof childPath_0[0] == "string" ? childPath_0[0] : JSON.stringify(childPath_0[0]);
24217
24220
  t6 = /* @__PURE__ */ jsx("div", { children: t("form.error.field-not-found", {
@@ -24233,7 +24236,7 @@ function FormInputInner(props2) {
24233
24236
  function _temp2$1m(member_2) {
24234
24237
  return member_2.kind === "fieldSet" && member_2.fieldSet?.members || [];
24235
24238
  }
24236
- function _temp$3h(member_1) {
24239
+ function _temp$3i(member_1) {
24237
24240
  return member_1.kind === "fieldSet";
24238
24241
  }
24239
24242
  function NullRender() {
@@ -24790,7 +24793,7 @@ function EnhancedObjectDialog(props2) {
24790
24793
  return isKeySegment(segment) && isKeySegment(relativeSegment) ? segment._key === relativeSegment._key : segment === relativeSegment;
24791
24794
  }))
24792
24795
  return !1;
24793
- if (fullscreenPath.some(_temp$3g))
24796
+ if (fullscreenPath.some(_temp$3h))
24794
24797
  return !0;
24795
24798
  const nextSegment = treeState.relativePath[fullscreenPath.length];
24796
24799
  return !isKeySegment(nextSegment);
@@ -24852,7 +24855,7 @@ function EnhancedObjectDialog(props2) {
24852
24855
  function _temp2$1l(longest, current) {
24853
24856
  return current.length > longest.length ? current : longest;
24854
24857
  }
24855
- function _temp$3g(segment_0) {
24858
+ function _temp$3h(segment_0) {
24856
24859
  return isKeySegment(segment_0);
24857
24860
  }
24858
24861
  const FlexWrapper$1 = styled(Flex)`
@@ -24892,14 +24895,14 @@ function PresenceTooltip(props2) {
24892
24895
  items
24893
24896
  } = props2;
24894
24897
  let t0;
24895
- $[0] !== items ? (t0 = items.map(_temp$3f), $[0] = items, $[1] = t0) : t0 = $[1];
24898
+ $[0] !== items ? (t0 = items.map(_temp$3g), $[0] = items, $[1] = t0) : t0 = $[1];
24896
24899
  let t1;
24897
24900
  $[2] !== t0 ? (t1 = /* @__PURE__ */ jsx(Stack, { sizing: "border", children: t0 }), $[2] = t0, $[3] = t1) : t1 = $[3];
24898
24901
  const content = t1;
24899
24902
  let t2;
24900
24903
  return $[4] !== children || $[5] !== content ? (t2 = /* @__PURE__ */ jsx(Tooltip, { content, placement: "top", portal: "documentScrollElement", children }), $[4] = children, $[5] = content, $[6] = t2) : t2 = $[6], t2;
24901
24904
  }
24902
- function _temp$3f(item) {
24905
+ function _temp$3g(item) {
24903
24906
  return /* @__PURE__ */ jsxs(Flex, { align: "center", gap: 2, children: [
24904
24907
  /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(UserAvatar, { user: item.user, status: "online" }) }),
24905
24908
  /* @__PURE__ */ jsx(Text$1, { size: 1, children: item.user.displayName })
@@ -24915,7 +24918,7 @@ const FieldPresenceInner = memo(function(t0) {
24915
24918
  } = t0, position = t1 === void 0 ? "inside" : t1, animateArrowFrom = t2 === void 0 ? "inside" : t2, maxAvatars = t3 === void 0 ? DEFAULT_MAX_AVATARS_FIELDS : t3, stack = t4 === void 0 ? !0 : t4;
24916
24919
  let t5;
24917
24920
  if ($[0] !== animateArrowFrom || $[1] !== maxAvatars || $[2] !== position || $[3] !== presence || $[4] !== stack) {
24918
- const uniquePresence = uniqBy(presence || [], _temp$3e), sorted = sortBy(uniquePresence, _temp2$1k), [hidden, visible] = stack ? splitRight(sorted, maxAvatars) : [[], sorted];
24921
+ const uniquePresence = uniqBy(presence || [], _temp$3f), sorted = sortBy(uniquePresence, _temp2$1k), [hidden, visible] = stack ? splitRight(sorted, maxAvatars) : [[], sorted];
24919
24922
  let t62;
24920
24923
  $[6] !== animateArrowFrom || $[7] !== position ? (t62 = (_visible) => ({
24921
24924
  key: _visible.user.id,
@@ -24963,7 +24966,7 @@ function _temp4$g(item) {
24963
24966
  return item.user.id;
24964
24967
  }
24965
24968
  const FieldPresenceWithOverlay = FieldPresence;
24966
- function _temp$3e(item) {
24969
+ function _temp$3f(item) {
24967
24970
  return item.user.id;
24968
24971
  }
24969
24972
  function _temp2$1k(_presence) {
@@ -25099,7 +25102,7 @@ const createIntersectionObserver = (options) => {
25099
25102
  }, t8 = [], $[11] = t7, $[12] = t8) : (t7 = $[11], t8 = $[12]), useLayoutEffect(t7, t8);
25100
25103
  const top = intersections["::top"], bottom2 = intersections["::bottom"];
25101
25104
  let t9;
25102
- $[13] !== bottom2 || $[14] !== intersections || $[15] !== regions || $[16] !== top ? (t9 = top && bottom2 ? regions.filter(_temp$3d).map((region_0) => {
25105
+ $[13] !== bottom2 || $[14] !== intersections || $[15] !== regions || $[16] !== top ? (t9 = top && bottom2 ? regions.filter(_temp$3e).map((region_0) => {
25103
25106
  const intersection2 = intersections[region_0.id];
25104
25107
  if (!intersection2)
25105
25108
  return null;
@@ -25148,7 +25151,7 @@ const createIntersectionObserver = (options) => {
25148
25151
  t15
25149
25152
  ] }), $[36] = ref, $[37] = t10, $[38] = t11, $[39] = t13, $[40] = t14, $[41] = t15, $[42] = t16) : t16 = $[42], t16;
25150
25153
  });
25151
- function _temp$3d(region) {
25154
+ function _temp$3e(region) {
25152
25155
  return region.presence?.length > 0;
25153
25156
  }
25154
25157
  const ITEM_TRANSITION = {
@@ -25234,7 +25237,7 @@ function StickyOverlay(props2) {
25234
25237
  const regions = t1;
25235
25238
  let t2;
25236
25239
  $[3] !== margins ? (t2 = (regionsWithIntersectionDetails, containerWidth) => {
25237
- const grouped = group(regionsWithIntersectionDetails.filter(_temp$3c)), topSpacing = sum(grouped.top.map(_temp2$1j)), bottomSpacing = sum([...grouped.inside, ...grouped.bottom].map(_temp3$A)), counts = grouped.inside.reduce(_temp4$f, {
25240
+ const grouped = group(regionsWithIntersectionDetails.filter(_temp$3d)), topSpacing = sum(grouped.top.map(_temp2$1j)), bottomSpacing = sum([...grouped.inside, ...grouped.bottom].map(_temp3$A)), counts = grouped.inside.reduce(_temp4$f, {
25238
25241
  nearTop: 0,
25239
25242
  nearBottom: 0
25240
25243
  });
@@ -25266,7 +25269,7 @@ function _temp3$A(n_0) {
25266
25269
  function _temp2$1j(n) {
25267
25270
  return n.region.rect.height + n.spacerHeight;
25268
25271
  }
25269
- function _temp$3c(item) {
25272
+ function _temp$3d(item) {
25270
25273
  return item.region.presence.length > 0;
25271
25274
  }
25272
25275
  const EMPTY_ARRAY$o = [], PresenceDock = memo(function(props2) {
@@ -25757,7 +25760,7 @@ function TreeEditingMenuItem(props2) {
25757
25760
  $[13] !== item.path || $[14] !== onPathSelect ? (t6 = () => onPathSelect(item.path), $[13] = item.path, $[14] = onPathSelect, $[15] = t6) : t6 = $[15];
25758
25761
  const handleClick = t6;
25759
25762
  let t7;
25760
- $[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = () => setOpen(_temp$3b), $[16] = t7) : t7 = $[16];
25763
+ $[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = () => setOpen(_temp$3c), $[16] = t7) : t7 = $[16];
25761
25764
  const handleExpandClick = t7;
25762
25765
  let t8, t9;
25763
25766
  $[17] !== item || $[18] !== selectedPath ? (t8 = () => {
@@ -25793,7 +25796,7 @@ function TreeEditingMenuItem(props2) {
25793
25796
  t18
25794
25797
  ] }, stringPath), $[53] = open, $[54] = stringPath, $[55] = t17, $[56] = t18, $[57] = t19) : t19 = $[57], t19;
25795
25798
  }
25796
- function _temp$3b(v) {
25799
+ function _temp$3c(v) {
25797
25800
  return !v;
25798
25801
  }
25799
25802
  const TreeEditingMenu = memo(function(props2) {
@@ -25884,7 +25887,7 @@ memo(function(props2) {
25884
25887
  siblings
25885
25888
  } = props2, [scrollElement, setScrollElement] = useState(null), containerElementRef = useRef(null), [open, setOpen] = useState(!1);
25886
25889
  let t0;
25887
- $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setOpen(_temp$3a), $[0] = t0) : t0 = $[0];
25890
+ $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setOpen(_temp$3b), $[0] = t0) : t0 = $[0];
25888
25891
  const toggleOpen = t0;
25889
25892
  let t1;
25890
25893
  $[1] !== setParentScrollElement ? (t1 = (el) => {
@@ -25911,7 +25914,7 @@ memo(function(props2) {
25911
25914
  t6
25912
25915
  ] }), $[24] = t2, $[25] = t6, $[26] = t7) : t7 = $[26], t7;
25913
25916
  });
25914
- function _temp$3a(v) {
25917
+ function _temp$3b(v) {
25915
25918
  return !v;
25916
25919
  }
25917
25920
  function SourceProvider(t0) {
@@ -26166,7 +26169,7 @@ function GridItem(props2) {
26166
26169
  const presence = t7, childValidation = useChildValidation(path, !0);
26167
26170
  let t8;
26168
26171
  $[14] !== childValidation ? (t8 = childValidation.length === 0 ? null : /* @__PURE__ */ jsx(Box, { paddingX: 1, paddingY: 3, children: /* @__PURE__ */ jsx(FormFieldValidationStatus, { validation: childValidation, __unstable_showSummary: !0 }) }), $[14] = childValidation, $[15] = t8) : t8 = $[15];
26169
- const validation2 = t8, hasErrors = childValidation.some(_temp$39), hasWarnings = childValidation.some(_temp2$1i), [contextMenuButtonElement, setContextMenuButtonElement] = useState(null), t9 = parentSchemaType.options?.insertMenu;
26172
+ const validation2 = t8, hasErrors = childValidation.some(_temp$3a), hasWarnings = childValidation.some(_temp2$1i), [contextMenuButtonElement, setContextMenuButtonElement] = useState(null), t9 = parentSchemaType.options?.insertMenu;
26170
26173
  let t10;
26171
26174
  $[16] !== contextMenuButtonElement || $[17] !== handleInsert || $[18] !== insertableTypes || $[19] !== t9 ? (t10 = {
26172
26175
  schemaTypes: insertableTypes,
@@ -26246,7 +26249,7 @@ function GridItem(props2) {
26246
26249
  function _temp2$1i(v_0) {
26247
26250
  return v_0.level === "warning";
26248
26251
  }
26249
- function _temp$39(v) {
26252
+ function _temp$3a(v) {
26250
26253
  return v.level === "error";
26251
26254
  }
26252
26255
  const EMPTY$4 = [];
@@ -26272,7 +26275,7 @@ function GridArrayInput(props2) {
26272
26275
  value: t1
26273
26276
  } = props2, ArrayFunctions = t0 === void 0 ? ArrayOfObjectsFunctions : t0, value = t1 === void 0 ? EMPTY$4 : t1, {
26274
26277
  t
26275
- } = useTranslation(), sortable = schemaType.options?.sortable !== !1, renderItem2 = _temp$38;
26278
+ } = useTranslation(), sortable = schemaType.options?.sortable !== !1, renderItem2 = _temp$39;
26276
26279
  let t2;
26277
26280
  $[0] !== members ? (t2 = members.map(_temp2$1h), $[0] = members, $[1] = t2) : t2 = $[1];
26278
26281
  const memberKeys = t2;
@@ -26301,7 +26304,7 @@ function GridArrayInput(props2) {
26301
26304
  function _temp2$1h(member) {
26302
26305
  return member.key;
26303
26306
  }
26304
- function _temp$38(itemProps) {
26307
+ function _temp$39(itemProps) {
26305
26308
  return /* @__PURE__ */ jsx(GridItem, { ...itemProps });
26306
26309
  }
26307
26310
  function useMemoCompare(next, compare2) {
@@ -26323,7 +26326,7 @@ function useVisibilityDetection(parentRef) {
26323
26326
  if (wasVisible === isNowVisible)
26324
26327
  return;
26325
26328
  const becameVisible = !wasVisible && isNowVisible;
26326
- prevVisible.current = isNowVisible, setIsVisible(isNowVisible), becameVisible && setMountKey(_temp$37);
26329
+ prevVisible.current = isNowVisible, setIsVisible(isNowVisible), becameVisible && setMountKey(_temp$38);
26327
26330
  });
26328
26331
  return parentRef.current && resizeObserver2.observe(parentRef.current), () => resizeObserver2.disconnect();
26329
26332
  }, t1 = [parentRef], $[0] = parentRef, $[1] = t0, $[2] = t1) : (t0 = $[1], t1 = $[2]), useEffect(t0, t1);
@@ -26333,7 +26336,7 @@ function useVisibilityDetection(parentRef) {
26333
26336
  mountKey
26334
26337
  }, $[3] = isVisible2, $[4] = mountKey, $[5] = t2) : t2 = $[5], t2;
26335
26338
  }
26336
- function _temp$37(prev) {
26339
+ function _temp$38(prev) {
26337
26340
  return prev + 1;
26338
26341
  }
26339
26342
  const Root$p = styled(Card)`
@@ -26431,7 +26434,7 @@ function IncompatibleItemType(props2) {
26431
26434
  const handleKeyDown = t2;
26432
26435
  let t3;
26433
26436
  $[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = () => {
26434
- setShowDetails(_temp$36);
26437
+ setShowDetails(_temp$37);
26435
26438
  }, $[7] = t3) : t3 = $[7];
26436
26439
  const handleShowDetails = t3;
26437
26440
  let t4;
@@ -26493,7 +26496,7 @@ function IncompatibleItemType(props2) {
26493
26496
  let t22;
26494
26497
  return $[50] !== showDetails || $[51] !== t17 || $[52] !== t21 ? (t22 = /* @__PURE__ */ jsx(Popover, { open: showDetails, ref: popoverRef, onKeyDown: handleKeyDown, portal: !0, constrainSize: !0, tone: "default", content: t17, children: t21 }), $[50] = showDetails, $[51] = t17, $[52] = t21, $[53] = t22) : t22 = $[53], t22;
26495
26498
  }
26496
- function _temp$36(v) {
26499
+ function _temp$37(v) {
26497
26500
  return !v;
26498
26501
  }
26499
26502
  const MENU_POPOVER_PROPS$6 = {
@@ -26640,7 +26643,7 @@ function ListArrayInput(props2) {
26640
26643
  t
26641
26644
  } = useTranslation(), [activeDragItemIndex, setActiveDragItemIndex] = useState(null);
26642
26645
  let t2;
26643
- $[0] !== members ? (t2 = members.map(_temp$35), $[0] = members, $[1] = t2) : t2 = $[1];
26646
+ $[0] !== members ? (t2 = members.map(_temp$36), $[0] = members, $[1] = t2) : t2 = $[1];
26644
26647
  const memberKeys = useMemoCompare(t2, shallowEquals), parentRef = useRef(null), {
26645
26648
  isVisible: isVisible2,
26646
26649
  mountKey
@@ -26686,7 +26689,7 @@ function ListArrayInput(props2) {
26686
26689
  t9
26687
26690
  ] }), $[42] = t8, $[43] = t9, $[44] = t10) : t10 = $[44], t10;
26688
26691
  }
26689
- function _temp$35(member) {
26692
+ function _temp$36(member) {
26690
26693
  return member.key;
26691
26694
  }
26692
26695
  function ArrayOfObjectsInput(props2) {
@@ -26731,7 +26734,7 @@ function ArrayOfObjectOptionsInput(props2) {
26731
26734
  $[0] !== t0 ? (t1 = t0 === void 0 ? [] : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
26732
26735
  const value = t1, t2 = schemaType.options?.list || EMPTY_ARRAY$m;
26733
26736
  let t3;
26734
- $[2] !== t2 ? (t3 = t2.map(_temp$34), $[2] = t2, $[3] = t3) : t3 = $[3];
26737
+ $[2] !== t2 ? (t3 = t2.map(_temp$35), $[2] = t2, $[3] = t3) : t3 = $[3];
26735
26738
  const options = t3;
26736
26739
  let t4;
26737
26740
  $[4] !== onChange || $[5] !== options || $[6] !== value ? (t4 = (isChecked, changedOption) => {
@@ -26771,7 +26774,7 @@ function ArrayOfObjectOptionsInput(props2) {
26771
26774
  let t9;
26772
26775
  return $[29] !== changed || $[30] !== path || $[31] !== t8 ? (t9 = /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !1, children: t8 }), $[29] = changed, $[30] = path, $[31] = t8, $[32] = t9) : t9 = $[32], t9;
26773
26776
  }
26774
- function _temp$34(option, index) {
26777
+ function _temp$35(option, index) {
26775
26778
  return isKeyedObject(option) ? option : {
26776
26779
  ...option,
26777
26780
  _key: `auto-generated-${index}`
@@ -26813,7 +26816,7 @@ function ArrayOfPrimitiveOptionsInput(props2) {
26813
26816
  const options = t3;
26814
26817
  let t4;
26815
26818
  $[6] !== onChange || $[7] !== options || $[8] !== value ? (t4 = (isChecked, changedValue) => {
26816
- const nextValue = options.map(_temp$33).filter((optionValue) => optionValue === changedValue ? isChecked : value.includes(optionValue));
26819
+ const nextValue = options.map(_temp$34).filter((optionValue) => optionValue === changedValue ? isChecked : value.includes(optionValue));
26817
26820
  onChange(nextValue.length > 0 ? set(nextValue) : unset());
26818
26821
  }, $[6] = onChange, $[7] = options, $[8] = value, $[9] = t4) : t4 = $[9];
26819
26822
  const handleChange = t4, t5 = schemaType.options?.layout === "grid" ? Math.min(options.length, 4) : 1;
@@ -26835,7 +26838,7 @@ function ArrayOfPrimitiveOptionsInput(props2) {
26835
26838
  let t8;
26836
26839
  return $[27] !== changed || $[28] !== path || $[29] !== t7 ? (t8 = /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !1, children: t7 }), $[27] = changed, $[28] = path, $[29] = t7, $[30] = t8) : t8 = $[30], t8;
26837
26840
  }
26838
- function _temp$33(option) {
26841
+ function _temp$34(option) {
26839
26842
  return option.value;
26840
26843
  }
26841
26844
  function ArrayOfOptionsInput(props2) {
@@ -26942,7 +26945,7 @@ function uploadTarget(Component2) {
26942
26945
  const tasks2 = files.map((file_0) => ({
26943
26946
  file: file_0,
26944
26947
  uploaderCandidates: getUploadCandidates(types, resolveUploader2, file_0)
26945
- })), ready = tasks2.filter(_temp$32), rejected = tasks2.filter(_temp2$1g);
26948
+ })), ready = tasks2.filter(_temp$33), rejected = tasks2.filter(_temp2$1g);
26946
26949
  rejected.length > 0 && pushToast({
26947
26950
  closable: !0,
26948
26951
  status: "warning",
@@ -27018,7 +27021,7 @@ function DropMessage(props2) {
27018
27021
  let t2;
27019
27022
  return $[3] !== t1 ? (t2 = /* @__PURE__ */ jsx(Fragment$1, { children: t1 }), $[3] = t1, $[4] = t2) : t2 = $[4], t2;
27020
27023
  }
27021
- function _temp$32(task) {
27024
+ function _temp$33(task) {
27022
27025
  return task.uploaderCandidates.length > 0;
27023
27026
  }
27024
27027
  function _temp2$1g(task_0) {
@@ -27101,7 +27104,7 @@ const MENU_BUTTON_POPOVER_PROPS$2 = {
27101
27104
  children,
27102
27105
  presence,
27103
27106
  schemaType
27104
- } = props2, hasError = validation2.filter(_temp$31).length > 0, hasWarning = validation2.filter(_temp2$1f).length > 0;
27107
+ } = props2, hasError = validation2.filter(_temp$32).length > 0, hasWarning = validation2.filter(_temp2$1f).length > 0;
27105
27108
  let t0;
27106
27109
  $[0] !== onInsert ? (t0 = (pos, insertType) => {
27107
27110
  onInsert({
@@ -27168,7 +27171,7 @@ const MENU_BUTTON_POPOVER_PROPS$2 = {
27168
27171
  let t17;
27169
27172
  return $[50] !== menu || $[51] !== sortable || $[52] !== t11 || $[53] !== t12 || $[54] !== t13 || $[55] !== t16 || $[56] !== tone ? (t17 = /* @__PURE__ */ jsx(RowLayout, { tone, readOnly: t11, menu, dragHandle: sortable, presence: t12, validation: t13, children: t16 }), $[50] = menu, $[51] = sortable, $[52] = t11, $[53] = t12, $[54] = t13, $[55] = t16, $[56] = tone, $[57] = t17) : t17 = $[57], t17;
27170
27173
  });
27171
- function _temp$31(item) {
27174
+ function _temp$32(item) {
27172
27175
  return item.level === "error";
27173
27176
  }
27174
27177
  function _temp2$1f(item_0) {
@@ -27537,7 +27540,7 @@ const TIME_ZONE_SCOPE_TYPE = {
27537
27540
  let t6;
27538
27541
  $[22] !== allTimeZones ? (t6 = () => {
27539
27542
  const localTzName = Intl.DateTimeFormat().resolvedOptions().timeZone, foundLocal = allTimeZones.find((tz_3) => tz_3.name === localTzName);
27540
- return foundLocal || allTimeZones.find(_temp$30) || allTimeZones[0];
27543
+ return foundLocal || allTimeZones.find(_temp$31) || allTimeZones[0];
27541
27544
  }, $[22] = allTimeZones, $[23] = t6) : t6 = $[23];
27542
27545
  const getLocalTimeZone = t6;
27543
27546
  let t7;
@@ -27635,7 +27638,7 @@ function getErrorMessage$1(err) {
27635
27638
  let message;
27636
27639
  return isClientError$1(err) ? err.response.statusCode === 403 ? message = "Forbidden. Please check that your project has access to the feature." : message = err.message : (err instanceof Error && (message = err.message), message = String(err)), message;
27637
27640
  }
27638
- function _temp$30(timeZone) {
27641
+ function _temp$31(timeZone) {
27639
27642
  return timeZone.abbreviation === "GMT";
27640
27643
  }
27641
27644
  const TimeZoneCitySpan = styled.span(({
@@ -27693,7 +27696,7 @@ const TimeZoneCitySpan = styled.span(({
27693
27696
  const handleTimeZoneUpdate = t6, isDirty = selectedTz?.name !== timeZone.name;
27694
27697
  let t7;
27695
27698
  $[18] !== getLocalTimeZone ? (t7 = getLocalTimeZone(), $[18] = getLocalTimeZone, $[19] = t7) : t7 = $[19];
27696
- const isLocalTzSelected = selectedTz?.name === t7.name, renderOption = _temp$2$, renderValue = _temp2$1e, t8 = !isDirty || !selectedTz;
27699
+ const isLocalTzSelected = selectedTz?.name === t7.name, renderOption = _temp$30, renderValue = _temp2$1e, t8 = !isDirty || !selectedTz;
27697
27700
  let t9;
27698
27701
  $[20] !== handleTimeZoneUpdate || $[21] !== t8 ? (t9 = {
27699
27702
  confirmButton: {
@@ -27752,7 +27755,7 @@ const TimeZoneCitySpan = styled.span(({
27752
27755
  let t25;
27753
27756
  return $[60] !== onClose || $[61] !== t24 || $[62] !== t9 ? (t25 = /* @__PURE__ */ jsx(Dialog, { footer: t9, header: "Select time zone", id: "time-zone", onClose, width: 1, children: t24 }), $[60] = onClose, $[61] = t24, $[62] = t9, $[63] = t25) : t25 = $[63], t25;
27754
27757
  };
27755
- function _temp$2$(option) {
27758
+ function _temp$30(option) {
27756
27759
  return /* @__PURE__ */ jsx(Card, { as: "button", padding: 3, children: /* @__PURE__ */ jsxs(Text$1, { size: 1, textOverflow: "ellipsis", children: [
27757
27760
  /* @__PURE__ */ jsx(TimeZoneCitySpan, { children: option.city }),
27758
27761
  /* @__PURE__ */ jsxs(TimeZoneOffsetSpan, { children: [
@@ -27856,9 +27859,9 @@ const DEFAULT_MONTH_NAMES = ["January", "February", "March", "April", "May", "Ju
27856
27859
  weekInfo
27857
27860
  } = useCurrentLocale();
27858
27861
  let t0;
27859
- return $[0] !== date || $[1] !== weekInfo.firstDay ? (t0 = getWeekDaysFromWeekStarts$2(getWeekStartsOfMonth$2(date, weekInfo.firstDay)).map(_temp$2_), $[0] = date, $[1] = weekInfo.firstDay, $[2] = t0) : t0 = $[2], t0;
27862
+ return $[0] !== date || $[1] !== weekInfo.firstDay ? (t0 = getWeekDaysFromWeekStarts$2(getWeekStartsOfMonth$2(date, weekInfo.firstDay)).map(_temp$2$), $[0] = date, $[1] = weekInfo.firstDay, $[2] = t0) : t0 = $[2], t0;
27860
27863
  };
27861
- function _temp$2_(days) {
27864
+ function _temp$2$(days) {
27862
27865
  return {
27863
27866
  number: getWeek(days[0]),
27864
27867
  days
@@ -27884,7 +27887,7 @@ function CalendarMonth$3(props2) {
27884
27887
  gridTemplateColumns: "repeat(7, minmax(44px, 46px))"
27885
27888
  }, $[4] = t2) : t2 = $[4];
27886
27889
  let t3;
27887
- $[5] !== weekDayNames ? (t3 = weekDayNames.map(_temp$2Z), $[5] = weekDayNames, $[6] = t3) : t3 = $[6];
27890
+ $[5] !== weekDayNames ? (t3 = weekDayNames.map(_temp$2_), $[5] = weekDayNames, $[6] = t3) : t3 = $[6];
27888
27891
  const t4 = useWeeksOfMonth$1(props2.date);
27889
27892
  let t5;
27890
27893
  if ($[7] !== props2.focused || $[8] !== props2.isPastDisabled || $[9] !== props2.onSelect || $[10] !== props2.selected || $[11] !== t4) {
@@ -27903,7 +27906,7 @@ function CalendarMonth$3(props2) {
27903
27906
  let t7;
27904
27907
  return $[21] !== t1 || $[22] !== t6 ? (t7 = /* @__PURE__ */ jsx(Box, { "aria-hidden": t1, "data-ui": "CalendarMonth", children: t6 }), $[21] = t1, $[22] = t6, $[23] = t7) : t7 = $[23], t7;
27905
27908
  }
27906
- function _temp$2Z(weekday) {
27909
+ function _temp$2_(weekday) {
27907
27910
  return /* @__PURE__ */ jsx(Box, { paddingY: 2, children: /* @__PURE__ */ jsx(Text$1, { size: 1, weight: "medium", style: {
27908
27911
  textAlign: "center"
27909
27912
  }, children: weekday }) }, weekday);
@@ -28208,11 +28211,11 @@ function CalendarMonthSelect$1(props2) {
28208
28211
  monthNames
28209
28212
  } = props2;
28210
28213
  let t0;
28211
- $[0] !== monthNames ? (t0 = monthNames.map(_temp$2Y), $[0] = monthNames, $[1] = t0) : t0 = $[1];
28214
+ $[0] !== monthNames ? (t0 = monthNames.map(_temp$2Z), $[0] = monthNames, $[1] = t0) : t0 = $[1];
28212
28215
  let t1;
28213
28216
  return $[2] !== onChange || $[3] !== t0 || $[4] !== value ? (t1 = /* @__PURE__ */ jsx(Flex, { flex: 1, gap: 1, children: /* @__PURE__ */ jsx(Box, { flex: 1, children: /* @__PURE__ */ jsx(Select, { fontSize: 1, radius: 2, value, onChange, padding: 2, children: t0 }) }) }), $[2] = onChange, $[3] = t0, $[4] = value, $[5] = t1) : t1 = $[5], t1;
28214
28217
  }
28215
- function _temp$2Y(monthName, i) {
28218
+ function _temp$2Z(monthName, i) {
28216
28219
  return /* @__PURE__ */ jsx("option", { value: i, children: monthName }, i);
28217
28220
  }
28218
28221
  function CalendarYearSelect$1(props2) {
@@ -28787,7 +28790,7 @@ const GroupTab = forwardRef(function(props2, ref) {
28787
28790
  } = useTranslation();
28788
28791
  let t3;
28789
28792
  $[2] !== t ? (t3 = t("inputs.object.field-group-tabs.aria-label"), $[2] = t, $[3] = t3) : t3 = $[3];
28790
- const t4 = groups.find(_temp$2X)?.name;
28793
+ const t4 = groups.find(_temp$2Y)?.name;
28791
28794
  let t5;
28792
28795
  if ($[4] !== groups || $[5] !== inputId || $[6] !== t) {
28793
28796
  let t62;
@@ -28821,7 +28824,7 @@ const GroupTab = forwardRef(function(props2, ref) {
28821
28824
  /* @__PURE__ */ jsx(GroupSelect, { ...props2, disabled, onSelect: handleClick })
28822
28825
  ] }), $[6] = disabled, $[7] = handleClick, $[8] = props2, $[9] = t3) : t3 = $[9], t3;
28823
28826
  });
28824
- function _temp$2X(g) {
28827
+ function _temp$2Y(g) {
28825
28828
  return g.selected;
28826
28829
  }
28827
28830
  const FieldGroupTabsWrapper = styled(Card)`
@@ -28964,7 +28967,7 @@ const RootStack$2 = styled(Stack)`
28964
28967
  }
28965
28968
  let t42;
28966
28969
  if ($[5] !== schemaType.fields || $[6] !== value) {
28967
- const knownFieldNames = schemaType.fields.map(_temp$2W);
28970
+ const knownFieldNames = schemaType.fields.map(_temp$2X);
28968
28971
  t42 = Object.keys(value || {}).filter((key) => !key.startsWith("_") && !knownFieldNames.includes(key)), $[5] = schemaType.fields, $[6] = value, $[7] = t42;
28969
28972
  } else
28970
28973
  t42 = $[7];
@@ -29010,7 +29013,7 @@ const RootStack$2 = styled(Stack)`
29010
29013
  t12
29011
29014
  ] }), $[43] = arrayEditingModal, $[44] = t12, $[45] = t13) : t13 = $[45], t13;
29012
29015
  });
29013
- function _temp$2W(field) {
29016
+ function _temp$2X(field) {
29014
29017
  return field.name;
29015
29018
  }
29016
29019
  function _temp2$1d(t0) {
@@ -29089,7 +29092,7 @@ function SlugInput(props2) {
29089
29092
  focusPath
29090
29093
  } = props2, sourceField = schemaType.options?.source;
29091
29094
  let t0;
29092
- $[0] !== validation2 ? (t0 = validation2.filter(_temp$2V), $[0] = validation2, $[1] = t0) : t0 = $[1];
29095
+ $[0] !== validation2 ? (t0 = validation2.filter(_temp$2W), $[0] = validation2, $[1] = t0) : t0 = $[1];
29093
29096
  const errors = t0, inputRef = useRef(null), slugContext = useSlugContext(), {
29094
29097
  t
29095
29098
  } = useTranslation();
@@ -29155,7 +29158,7 @@ function SlugInput(props2) {
29155
29158
  t13
29156
29159
  ] }) }), $[38] = t12, $[39] = t13, $[40] = t14) : t14 = $[40], t14;
29157
29160
  }
29158
- function _temp$2V(item) {
29161
+ function _temp$2W(item) {
29159
29162
  return item.level === "error";
29160
29163
  }
29161
29164
  function StringInputBasic(props2) {
@@ -29420,7 +29423,7 @@ const ScrollContainerComponent = forwardRef(function(props2, forwardedRef) {
29420
29423
  const As = t0 === void 0 ? "div" : t0, ref = useRef(null);
29421
29424
  let t1;
29422
29425
  $[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => ref.current, $[4] = t1) : t1 = $[4], useImperativeHandle(forwardedRef, t1);
29423
- const parentContext = useContext(ScrollContext), [childContext] = useState(_temp$2U);
29426
+ const parentContext = useContext(ScrollContext), [childContext] = useState(_temp$2V);
29424
29427
  let t2, t3;
29425
29428
  $[5] !== childContext || $[6] !== onScroll ? (t2 = () => {
29426
29429
  if (onScroll)
@@ -29450,7 +29453,7 @@ const ScrollContainerComponent = forwardRef(function(props2, forwardedRef) {
29450
29453
  return $[19] !== childContext || $[20] !== t8 ? (t9 = /* @__PURE__ */ jsx(ScrollContext.Provider, { value: childContext, children: t8 }), $[19] = childContext, $[20] = t8, $[21] = t9) : t9 = $[21], t9;
29451
29454
  }), ScrollContainer = memo(ScrollContainerComponent);
29452
29455
  ScrollContainer.displayName = "Memo(Forwardref(ScrollContainer))";
29453
- function _temp$2U() {
29456
+ function _temp$2V() {
29454
29457
  return createPubSub();
29455
29458
  }
29456
29459
  const TEXT_LEVELS = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], TEXT_BULLET_MARKERS = ["\u25CF", "\u25CB", "\u25A0"], TEXT_NUMBER_FORMATS = ["number", "lower-alpha", "lower-roman"], TEXT_DECORATOR_TAGS = {
@@ -29840,7 +29843,7 @@ function BlockActions(props2) {
29840
29843
  renderBlockActions
29841
29844
  } = props2;
29842
29845
  let t0;
29843
- $[0] !== editor2.schemaTypes.decorators ? (t0 = editor2.schemaTypes.decorators.map(_temp$2T), $[0] = editor2.schemaTypes.decorators, $[1] = t0) : t0 = $[1];
29846
+ $[0] !== editor2.schemaTypes.decorators ? (t0 = editor2.schemaTypes.decorators.map(_temp$2U), $[0] = editor2.schemaTypes.decorators, $[1] = t0) : t0 = $[1];
29844
29847
  const decoratorValues = t0;
29845
29848
  let t1;
29846
29849
  bb0: {
@@ -29879,7 +29882,7 @@ function BlockActions(props2) {
29879
29882
  let t2;
29880
29883
  return $[8] !== blockActions ? (t2 = /* @__PURE__ */ jsx(Root$j, { contentEditable: !1, children: blockActions }), $[8] = blockActions, $[9] = t2) : t2 = $[9], t2;
29881
29884
  }
29882
- function _temp$2T(d) {
29885
+ function _temp$2U(d) {
29883
29886
  return d.value;
29884
29887
  }
29885
29888
  function textBlockStyle(props2) {
@@ -30612,13 +30615,13 @@ const MENU_BUTTON_POPOVER_PROPS$1 = {
30612
30615
  onMenuClose
30613
30616
  } = props2;
30614
30617
  let t0;
30615
- $[0] !== menuOptions ? (t0 = menuOptions.map(_temp$2S), $[0] = menuOptions, $[1] = t0) : t0 = $[1];
30618
+ $[0] !== menuOptions ? (t0 = menuOptions.map(_temp$2T), $[0] = menuOptions, $[1] = t0) : t0 = $[1];
30616
30619
  let t1;
30617
30620
  $[2] !== t0 ? (t1 = /* @__PURE__ */ jsx(Menu, { children: t0 }), $[2] = t0, $[3] = t1) : t1 = $[3];
30618
30621
  let t2;
30619
30622
  return $[4] !== disableRestoreFocusOnClose || $[5] !== forwardedRef || $[6] !== menuButton || $[7] !== menuButtonProps || $[8] !== onMenuClose || $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(MenuButton, { __unstable_disableRestoreFocusOnClose: disableRestoreFocusOnClose, id: "menu-button", ref: forwardedRef, onClose: onMenuClose, popover: MENU_BUTTON_POPOVER_PROPS$1, ...menuButtonProps, button: menuButton, menu: t1 }), $[4] = disableRestoreFocusOnClose, $[5] = forwardedRef, $[6] = menuButton, $[7] = menuButtonProps, $[8] = onMenuClose, $[9] = t1, $[10] = t2) : t2 = $[10], t2;
30620
30623
  });
30621
- function _temp$2S(c2, index) {
30624
+ function _temp$2T(c2, index) {
30622
30625
  const {
30623
30626
  collapsedProps,
30624
30627
  expandedProps,
@@ -30745,7 +30748,7 @@ const CollapseMenu = forwardRef(function(props2, ref) {
30745
30748
  }, $[10] = rootEl, $[11] = t3) : t3 = $[11];
30746
30749
  const intersectionOptions = t3;
30747
30750
  let t4;
30748
- $[12] !== menuOptions ? (t4 = menuOptions.map(_temp$2R), $[12] = menuOptions, $[13] = t4) : t4 = $[13];
30751
+ $[12] !== menuOptions ? (t4 = menuOptions.map(_temp$2S), $[12] = menuOptions, $[13] = t4) : t4 = $[13];
30749
30752
  const menuOptionKeys = t4;
30750
30753
  let t5;
30751
30754
  $[14] !== collapsedIntersections || $[15] !== expandedIntersections || $[16] !== menuOptionKeys ? (t5 = [...difference(menuOptionKeys, Object.keys(expandedIntersections)), ...difference(menuOptionKeys, Object.keys(collapsedIntersections))], $[14] = collapsedIntersections, $[15] = expandedIntersections, $[16] = menuOptionKeys, $[17] = t5) : t5 = $[17];
@@ -30883,7 +30886,7 @@ const CollapseMenu = forwardRef(function(props2, ref) {
30883
30886
  let t1;
30884
30887
  return $[7] !== gap || $[8] !== t0 ? (t1 = /* @__PURE__ */ jsx(RowFlex, { "data-hidden": !0, "aria-hidden": "true", gap, overflow: "hidden", children: t0 }), $[7] = gap, $[8] = t0, $[9] = t1) : t1 = $[9], t1;
30885
30888
  });
30886
- function _temp$2R(child) {
30889
+ function _temp$2S(child) {
30887
30890
  return child.key;
30888
30891
  }
30889
30892
  const CollapseMenuButton = forwardRef(function(props2, ref) {
@@ -31056,9 +31059,9 @@ function useActiveActionKeys(t0) {
31056
31059
  actions
31057
31060
  } = t0, editor2 = usePortableTextEditor(), selection = usePortableTextEditorSelection();
31058
31061
  let t1;
31059
- return $[0] !== actions || $[1] !== editor2 || $[2] !== selection ? (t1 = selection ? actions.filter((a) => a.type === "annotation" ? PortableTextEditor.isAnnotationActive(editor2, a.key) : a.type === "listStyle" ? PortableTextEditor.hasListStyle(editor2, a.key) : PortableTextEditor.isMarkActive(editor2, a.key)).map(_temp$2Q) : [], $[0] = actions, $[1] = editor2, $[2] = selection, $[3] = t1) : t1 = $[3], useUnique(t1);
31062
+ return $[0] !== actions || $[1] !== editor2 || $[2] !== selection ? (t1 = selection ? actions.filter((a) => a.type === "annotation" ? PortableTextEditor.isAnnotationActive(editor2, a.key) : a.type === "listStyle" ? PortableTextEditor.hasListStyle(editor2, a.key) : PortableTextEditor.isMarkActive(editor2, a.key)).map(_temp$2R) : [], $[0] = actions, $[1] = editor2, $[2] = selection, $[3] = t1) : t1 = $[3], useUnique(t1);
31060
31063
  }
31061
- function _temp$2Q(a_0) {
31064
+ function _temp$2R(a_0) {
31062
31065
  return a_0.key;
31063
31066
  }
31064
31067
  function useActiveStyleKeys(t0) {
@@ -31132,14 +31135,14 @@ const CollapseMenuMemo$1 = memo(CollapseMenu), MENU_POPOVER_PROPS$4 = {
31132
31135
  let t7;
31133
31136
  return $[28] !== children || $[29] !== collapsed || $[30] !== handleMenuClose || $[31] !== menuButtonProps ? (t7 = /* @__PURE__ */ jsx(CollapseMenuMemo$1, { "data-testid": "action-menu-auto-collapse-menu", collapsed, disableRestoreFocusOnClose: !0, gap: 1, menuButtonProps, onMenuClose: handleMenuClose, children }), $[28] = children, $[29] = collapsed, $[30] = handleMenuClose, $[31] = menuButtonProps, $[32] = t7) : t7 = $[32], t7;
31134
31137
  });
31135
- function _temp$2P(action, actionIndex) {
31138
+ function _temp$2Q(action, actionIndex) {
31136
31139
  return actionIndex === 0 ? {
31137
31140
  ...action,
31138
31141
  firstInGroup: !0
31139
31142
  } : action;
31140
31143
  }
31141
31144
  function _temp2$1b(acc, group2) {
31142
- return acc.concat(group2.actions.map(_temp$2P));
31145
+ return acc.concat(group2.actions.map(_temp$2Q));
31143
31146
  }
31144
31147
  const MenuButtonMemo = memo(MenuButton), StyledMenuItem = styled(MenuItem$1)`
31145
31148
  // Change the border color variable used by BlockQuote
@@ -31320,7 +31323,7 @@ const MenuButtonMemo = memo(MenuButton), StyledMenuItem = styled(MenuItem$1)`
31320
31323
  onToggleFullscreen
31321
31324
  } = t0, {
31322
31325
  t
31323
- } = useTranslation(), showActionMenu = actionGroups.reduce(_temp$2O, 0) > 0, showInsertMenu = insertMenuItems.length > 0, [rootElement, setRootElement] = useState(null), rootElementRect = useElementRect(rootElement), collapsed = collapsible && rootElementRect ? rootElementRect?.width < 400 : !1, showBlockStyleSelect = blockStyles.length > 1;
31326
+ } = useTranslation(), showActionMenu = actionGroups.reduce(_temp$2P, 0) > 0, showInsertMenu = insertMenuItems.length > 0, [rootElement, setRootElement] = useState(null), rootElementRect = useElementRect(rootElement), collapsed = collapsible && rootElementRect ? rootElementRect?.width < 400 : !1, showBlockStyleSelect = blockStyles.length > 1;
31324
31327
  let t1;
31325
31328
  $[0] !== rootElement ? (t1 = {
31326
31329
  rootElement
@@ -31429,7 +31432,7 @@ function Toolbar(props2) {
31429
31432
  let t6;
31430
31433
  return $[22] !== actionGroups || $[23] !== blockStyles || $[24] !== collapsible || $[25] !== disabled || $[26] !== insertMenuItems || $[27] !== isFullscreen || $[28] !== onToggleFullscreen ? (t6 = /* @__PURE__ */ jsx(InnerToolbar, { actionGroups, blockStyles, collapsible, disabled, insertMenuItems, isFullscreen, onToggleFullscreen }), $[22] = actionGroups, $[23] = blockStyles, $[24] = collapsible, $[25] = disabled, $[26] = insertMenuItems, $[27] = isFullscreen, $[28] = onToggleFullscreen, $[29] = t6) : t6 = $[29], t6;
31431
31434
  }
31432
- function _temp$2O(acc, x) {
31435
+ function _temp$2P(acc, x) {
31433
31436
  return acc + x.actions.length;
31434
31437
  }
31435
31438
  function _temp2$1a(e) {
@@ -31587,7 +31590,7 @@ function useTrackFocusPath(props2) {
31587
31590
  $[0] !== boundaryElement || $[1] !== editor2 || $[2] !== elementRefs || $[3] !== focusPath || $[4] !== portableTextMemberItems || $[5] !== selection ? (t0 = () => {
31588
31591
  if (focusPath.length === 0 || selection?.focus.path && isEqual$3(selection.focus.path, focusPath.slice(0, selection.focus.path.length)))
31589
31592
  return;
31590
- const focusedItem = portableTextMemberItems.find(_temp$2N), openItem = portableTextMemberItems.find(_temp2$19), relatedEditorItem = focusedItem || openItem, elementRef = relatedEditorItem ? elementRefs[relatedEditorItem.member.key] : void 0;
31593
+ const focusedItem = portableTextMemberItems.find(_temp$2O), openItem = portableTextMemberItems.find(_temp2$19), relatedEditorItem = focusedItem || openItem, elementRef = relatedEditorItem ? elementRefs[relatedEditorItem.member.key] : void 0;
31591
31594
  if (relatedEditorItem && elementRef) {
31592
31595
  boundaryElement && (scrollIntoView$1(boundaryElement, {
31593
31596
  scrollMode: "if-needed",
@@ -31627,7 +31630,7 @@ function useTrackFocusPath(props2) {
31627
31630
  function _temp2$19(m_0) {
31628
31631
  return m_0.member.open;
31629
31632
  }
31630
- function _temp$2N(m) {
31633
+ function _temp$2O(m) {
31631
31634
  return m.member.item.focused;
31632
31635
  }
31633
31636
  const Root$h = styled(Card)(rootStyle), PreviewSpan = styled.span`
@@ -32097,7 +32100,7 @@ const InlineObject = (props2) => {
32097
32100
  t
32098
32101
  } = useTranslation(), hasMarkers = markers.length > 0, popoverTitle = schemaType?.title || schemaType.name;
32099
32102
  let t0;
32100
- $[0] !== validation2 ? (t0 = validation2.filter(_temp$2M), $[0] = validation2, $[1] = t0) : t0 = $[1];
32103
+ $[0] !== validation2 ? (t0 = validation2.filter(_temp$2N), $[0] = validation2, $[1] = t0) : t0 = $[1];
32101
32104
  const hasError = t0.length > 0;
32102
32105
  let t1;
32103
32106
  $[2] !== validation2 ? (t1 = validation2.filter(_temp2$18), $[2] = validation2, $[3] = t1) : t1 = $[3];
@@ -32151,7 +32154,7 @@ const InlineObject = (props2) => {
32151
32154
  t16
32152
32155
  ] }), $[44] = t14, $[45] = t15, $[46] = t16, $[47] = t17) : t17 = $[47], t17;
32153
32156
  };
32154
- function _temp$2M(v) {
32157
+ function _temp$2N(v) {
32155
32158
  return v.level === "error";
32156
32159
  }
32157
32160
  function _temp2$18(v_0) {
@@ -32160,7 +32163,7 @@ function _temp2$18(v_0) {
32160
32163
  function AnnotationObjectEditModal(props2) {
32161
32164
  const $ = c(14), editor2 = usePortableTextEditor(), boundaryElement = useBoundaryElement().element, portableTextMemberItems = usePortableTextMemberItems(), elementRefs = usePortableTextMemberItemElementRefs();
32162
32165
  let t0;
32163
- $[0] !== portableTextMemberItems ? (t0 = portableTextMemberItems.find(_temp$2L), $[0] = portableTextMemberItems, $[1] = t0) : t0 = $[1];
32166
+ $[0] !== portableTextMemberItems ? (t0 = portableTextMemberItems.find(_temp$2M), $[0] = portableTextMemberItems, $[1] = t0) : t0 = $[1];
32164
32167
  const openAnnotation = t0;
32165
32168
  let t1;
32166
32169
  $[2] !== editor2 || $[3] !== openAnnotation || $[4] !== props2 ? (t1 = () => {
@@ -32176,7 +32179,7 @@ function AnnotationObjectEditModal(props2) {
32176
32179
  let t3;
32177
32180
  return $[6] !== boundaryElement || $[7] !== elementRef || $[8] !== onClose || $[9] !== openAnnotation.input || $[10] !== openAnnotation.node.schemaType || $[11] !== props2.referenceBoundary || $[12] !== t2 ? (t3 = /* @__PURE__ */ jsx(ObjectEditModal, { defaultType: "popover", floatingBoundary: boundaryElement, onClose, autoFocus: t2, referenceBoundary: props2.referenceBoundary, referenceElement: elementRef, schemaType: openAnnotation.node.schemaType, children: openAnnotation.input }), $[6] = boundaryElement, $[7] = elementRef, $[8] = onClose, $[9] = openAnnotation.input, $[10] = openAnnotation.node.schemaType, $[11] = props2.referenceBoundary, $[12] = t2, $[13] = t3) : t3 = $[13], t3;
32178
32181
  }
32179
- function _temp$2L(m) {
32182
+ function _temp$2M(m) {
32180
32183
  return m.kind === "annotation" && m.member.open;
32181
32184
  }
32182
32185
  function Compositor(props2) {
@@ -32571,7 +32574,7 @@ function useOptimisticPortableTextDiff(t0) {
32571
32574
  t22 = Object.values(optimisticRangeDecorations).concat(Object.entries(definitiveRangeDecorations).filter((t32) => {
32572
32575
  const [blockKey] = t32;
32573
32576
  return typeof optimisticRangeDecorations[blockKey] > "u";
32574
- }).map(_temp$2K)).flat(), $[2] = definitiveValue, $[3] = optimisticValue, $[4] = perspective, $[5] = upstreamValue, $[6] = t22;
32577
+ }).map(_temp$2L)).flat(), $[2] = definitiveValue, $[3] = optimisticValue, $[4] = perspective, $[5] = upstreamValue, $[6] = t22;
32575
32578
  } else
32576
32579
  t22 = $[6];
32577
32580
  t1 = t22;
@@ -32609,7 +32612,7 @@ function useOptimisticPortableTextDiff(t0) {
32609
32612
  onOptimisticChange
32610
32613
  }, $[14] = onOptimisticChange, $[15] = rangeDecorations, $[16] = t5) : t5 = $[16], t5;
32611
32614
  }
32612
- function _temp$2K(t0) {
32615
+ function _temp$2L(t0) {
32613
32616
  const [, blockRangeDecorations] = t0;
32614
32617
  return blockRangeDecorations;
32615
32618
  }
@@ -32827,14 +32830,14 @@ const RenderDefault = (props2) => {
32827
32830
  let t1;
32828
32831
  return $[1] !== RenderPlugins || $[2] !== props2 ? (t1 = /* @__PURE__ */ jsx(RenderPlugins, { ...props2 }), $[1] = RenderPlugins, $[2] = props2, $[3] = t1) : t1 = $[3], t1;
32829
32832
  };
32830
- function _temp$2J(decorator) {
32833
+ function _temp$2K(decorator) {
32831
32834
  return decorator.name === "code" ? [] : [decorator.name];
32832
32835
  }
32833
32836
  function _temp2$17(t0) {
32834
32837
  const {
32835
32838
  context
32836
32839
  } = t0;
32837
- return context.schema.decorators.flatMap(_temp$2J);
32840
+ return context.schema.decorators.flatMap(_temp$2K);
32838
32841
  }
32839
32842
  const DOT_SIZE = 6, CONTENT_BOX_VARIANTS = {
32840
32843
  animate: {
@@ -32991,7 +32994,7 @@ function usePresenceCursorDecorations(props2) {
32991
32994
  const handleRangeDecorationMoved = t2;
32992
32995
  let t3, t4;
32993
32996
  $[3] !== fieldPresence || $[4] !== path ? (t3 = () => {
32994
- const nextPresence = fieldPresence.filter((p_0) => startsWith(path, p_0.path) && !isEqual$2(path, p_0.path)), filteredNext = nextPresence.map(_temp$2I), filteredPrevious = previousPresence.current.map(_temp2$16);
32997
+ const nextPresence = fieldPresence.filter((p_0) => startsWith(path, p_0.path) && !isEqual$2(path, p_0.path)), filteredNext = nextPresence.map(_temp$2J), filteredPrevious = previousPresence.current.map(_temp2$16);
32995
32998
  if (!isEqual$2(filteredNext, filteredPrevious)) {
32996
32999
  const value = nextPresence.length > 0 ? nextPresence : EMPTY_ARRAY$B;
32997
33000
  setCurrentPresence(value), previousPresence.current = value;
@@ -33029,7 +33032,7 @@ function _temp2$16(d_0) {
33029
33032
  sessionId: d_0.sessionId
33030
33033
  };
33031
33034
  }
33032
- function _temp$2I(d) {
33035
+ function _temp$2J(d) {
33033
33036
  return {
33034
33037
  ...d.selection,
33035
33038
  sessionId: d.sessionId
@@ -33910,12 +33913,12 @@ function useFeatureEnabled(featureKey) {
33910
33913
  features: features2,
33911
33914
  error: null
33912
33915
  };
33913
- }, $[6] = featureKey, $[7] = t2) : t2 = $[7], t1 = req.pipe(map(t2), startWith(INITIAL_LOADING_STATE$3), catchError(_temp$2H)), $[3] = featureKey, $[4] = req, $[5] = t1;
33916
+ }, $[6] = featureKey, $[7] = t2) : t2 = $[7], t1 = req.pipe(map(t2), startWith(INITIAL_LOADING_STATE$3), catchError(_temp$2I)), $[3] = featureKey, $[4] = req, $[5] = t1;
33914
33917
  } else
33915
33918
  t1 = $[5];
33916
33919
  return useObservable(t1, INITIAL_LOADING_STATE$3);
33917
33920
  }
33918
- function _temp$2H(error) {
33921
+ function _temp$2I(error) {
33919
33922
  return of({
33920
33923
  isLoading: !1,
33921
33924
  enabled: !1,
@@ -33932,7 +33935,7 @@ function DisabledFeatureWarning(t0) {
33932
33935
  } = useTranslation();
33933
33936
  let t1;
33934
33937
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = {
33935
- DocumentationLink: _temp$2G
33938
+ DocumentationLink: _temp$2H
33936
33939
  }, $[0] = t1) : t1 = $[0];
33937
33940
  let t2;
33938
33941
  $[1] !== t ? (t2 = /* @__PURE__ */ jsx(Translate, { t, i18nKey: "inputs.reference.cross-dataset.feature-disabled-description", components: t1 }), $[1] = t, $[2] = t2) : t2 = $[2];
@@ -33969,7 +33972,7 @@ function DisabledFeatureWarning(t0) {
33969
33972
  t11
33970
33973
  ] }), $[26] = t10, $[27] = t11, $[28] = t12) : t12 = $[28], t12;
33971
33974
  }
33972
- function _temp$2G(t0) {
33975
+ function _temp$2H(t0) {
33973
33976
  const {
33974
33977
  children
33975
33978
  } = t0;
@@ -34065,7 +34068,7 @@ function useReferenceInfo$1(doc, getReferenceInfo2) {
34065
34068
  const $ = c(8), [retryAttempt, setRetryAttempt] = useState(0);
34066
34069
  let t0;
34067
34070
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => {
34068
- setRetryAttempt(_temp$2F);
34071
+ setRetryAttempt(_temp$2G);
34069
34072
  }, $[0] = t0) : t0 = $[0];
34070
34073
  const retry2 = t0;
34071
34074
  let t1;
@@ -34089,7 +34092,7 @@ function useReferenceInfo$1(doc, getReferenceInfo2) {
34089
34092
  retryAttempt
34090
34093
  })))) : of(EMPTY_STATE$1), $[4] = docInfo, $[5] = getReferenceInfo2, $[6] = retryAttempt, $[7] = t2) : t2 = $[7], useObservable(t2, INITIAL_LOADING_STATE$2);
34091
34094
  }
34092
- function _temp$2F(current) {
34095
+ function _temp$2G(current) {
34093
34096
  return current + 1;
34094
34097
  }
34095
34098
  function useProjectId$1() {
@@ -34329,7 +34332,7 @@ function CrossDatasetReferenceInput(props2) {
34329
34332
  push
34330
34333
  } = useToast();
34331
34334
  let t12;
34332
- $[29] !== validation2 ? (t12 = validation2.filter(_temp$2E), $[29] = validation2, $[30] = t12) : t12 = $[30];
34335
+ $[29] !== validation2 ? (t12 = validation2.filter(_temp$2F), $[29] = validation2, $[30] = t12) : t12 = $[30];
34333
34336
  const errors = t12;
34334
34337
  let t13;
34335
34338
  $[31] !== onPathFocus ? (t13 = (event_0) => {
@@ -34417,7 +34420,7 @@ function _temp2$15(prevState, nextState) {
34417
34420
  ...nextState
34418
34421
  };
34419
34422
  }
34420
- function _temp$2E(item) {
34423
+ function _temp$2F(item) {
34421
34424
  return item.level === "error";
34422
34425
  }
34423
34426
  const REQUEST_TAG_BASE$1 = "cross-dataset-refs", AVAILABILITY_READABLE$2 = {
@@ -34663,7 +34666,7 @@ function useReferenceInfo(doc, getReferenceInfo2) {
34663
34666
  const $ = c(10), [retryAttempt, setRetryAttempt] = useState(0);
34664
34667
  let t0;
34665
34668
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => {
34666
- setRetryAttempt(_temp$2D);
34669
+ setRetryAttempt(_temp$2E);
34667
34670
  }, $[0] = t0) : t0 = $[0];
34668
34671
  const retry2 = t0;
34669
34672
  let t1;
@@ -34697,7 +34700,7 @@ function useReferenceInfo(doc, getReferenceInfo2) {
34697
34700
  }
34698
34701
  return useObservable(t1, INITIAL_LOADING_STATE$1);
34699
34702
  }
34700
- function _temp$2D(current) {
34703
+ function _temp$2E(current) {
34701
34704
  return current + 1;
34702
34705
  }
34703
34706
  function OptionPreview(props2) {
@@ -34940,7 +34943,7 @@ function GlobalDocumentReferenceInput(props2) {
34940
34943
  push
34941
34944
  } = useToast();
34942
34945
  let t11;
34943
- $[31] !== validation2 ? (t11 = validation2.filter(_temp$2C), $[31] = validation2, $[32] = t11) : t11 = $[32];
34946
+ $[31] !== validation2 ? (t11 = validation2.filter(_temp$2D), $[31] = validation2, $[32] = t11) : t11 = $[32];
34944
34947
  const errors = t11;
34945
34948
  let t12;
34946
34949
  $[33] !== onPathFocus ? (t12 = (event_0) => {
@@ -35044,7 +35047,7 @@ function _temp2$14(prevState, nextState) {
35044
35047
  ...nextState
35045
35048
  };
35046
35049
  }
35047
- function _temp$2C(item) {
35050
+ function _temp$2D(item) {
35048
35051
  return item.level === "error";
35049
35052
  }
35050
35053
  function getReferenceClient(client, schemaType) {
@@ -35552,7 +35555,7 @@ const TRANSFORMATIONS = {
35552
35555
  const controller = new AbortController(), signal = controller.signal;
35553
35556
  return fetch(props2.icon.url, {
35554
35557
  signal
35555
- }).then(_temp$2B).then((data) => setHtml(data)).catch(_temp2$13), () => {
35558
+ }).then(_temp$2C).then((data) => setHtml(data)).catch(_temp2$13), () => {
35556
35559
  controller.abort();
35557
35560
  };
35558
35561
  }, t1 = [props2.icon.url], $[0] = props2.icon.url, $[1] = t0, $[2] = t1) : (t0 = $[1], t1 = $[2]), useEffect(t0, t1);
@@ -35703,7 +35706,7 @@ function UpsellDescriptionSerializer(props2) {
35703
35706
  let t2;
35704
35707
  return $[5] !== components2 || $[6] !== value ? (t2 = /* @__PURE__ */ jsx(Card, { tone: "default", children: /* @__PURE__ */ jsx(SerializerContainer, { children: /* @__PURE__ */ jsx(PortableText$1, { value, components: components2, onMissingComponent: !1 }) }) }), $[5] = components2, $[6] = value, $[7] = t2) : t2 = $[7], t2;
35705
35708
  }
35706
- function _temp$2B(response) {
35709
+ function _temp$2C(response) {
35707
35710
  if (!response.ok)
35708
35711
  throw new Error(`HTTP error! status: ${response.status}`);
35709
35712
  return response.text();
@@ -35838,9 +35841,9 @@ function useReferringDocuments(id2, t0) {
35838
35841
  docId: id2
35839
35842
  }, {
35840
35843
  tag: "use-referring-documents"
35841
- }).pipe(map(_temp$2A), startWith(INITIAL_STATE$8)), $[2] = documentStore, $[3] = id2, $[4] = projection, $[5] = t2) : t2 = $[5], useObservable(t2, INITIAL_STATE$8);
35844
+ }).pipe(map(_temp$2B), startWith(INITIAL_STATE$8)), $[2] = documentStore, $[3] = id2, $[4] = projection, $[5] = t2) : t2 = $[5], useObservable(t2, INITIAL_STATE$8);
35842
35845
  }
35843
- function _temp$2A(docs) {
35846
+ function _temp$2B(docs) {
35844
35847
  return {
35845
35848
  referringDocuments: docs,
35846
35849
  isLoading: !1
@@ -35868,7 +35871,7 @@ const AssetUsageList = (t0) => {
35868
35871
  let t6;
35869
35872
  $[8] !== t1 || $[9] !== t5 ? (t6 = /* @__PURE__ */ jsx(Card, { borderBottom: t1, marginTop: 2, paddingBottom: 2, marginBottom: 1, children: t5 }), $[8] = t1, $[9] = t5, $[10] = t6) : t6 = $[10];
35870
35873
  let t7;
35871
- $[11] !== referringDocuments ? (t7 = referringDocuments.map(_temp$2z), $[11] = referringDocuments, $[12] = t7) : t7 = $[12];
35874
+ $[11] !== referringDocuments ? (t7 = referringDocuments.map(_temp$2A), $[11] = referringDocuments, $[12] = t7) : t7 = $[12];
35872
35875
  let t8;
35873
35876
  return $[13] !== t6 || $[14] !== t7 ? (t8 = /* @__PURE__ */ jsxs(Fragment$1, { children: [
35874
35877
  t6,
@@ -35896,7 +35899,7 @@ const AssetUsageList = (t0) => {
35896
35899
  let t6;
35897
35900
  return $[11] !== LinkComponent2 || $[12] !== document2._id || $[13] !== t5 ? (t6 = /* @__PURE__ */ jsx(Card, { as: LinkComponent2, radius: 2, "data-as": "a", tabIndex: 0, children: t5 }, t2), $[11] = LinkComponent2, $[12] = document2._id, $[13] = t5, $[14] = t6) : t6 = $[14], t6;
35898
35901
  };
35899
- function _temp$2z(document2) {
35902
+ function _temp$2A(document2) {
35900
35903
  return /* @__PURE__ */ jsx(DocumentLink, { document: document2 }, document2._id);
35901
35904
  }
35902
35905
  const STYLE_ASSET_IMAGE = {
@@ -35992,7 +35995,7 @@ function AssetDeleteDialog(t0) {
35992
35995
  } = useLegacyReferringDocuments(asset._id);
35993
35996
  let t2;
35994
35997
  if ($[0] !== referringDocuments) {
35995
- const drafts = referringDocuments.reduce(_temp$2y, []);
35998
+ const drafts = referringDocuments.reduce(_temp$2z, []);
35996
35999
  t2 = referringDocuments.filter((doc_0) => !drafts.includes(doc_0._id)), $[0] = referringDocuments, $[1] = t2;
35997
36000
  } else
35998
36001
  t2 = $[1];
@@ -36033,7 +36036,7 @@ function AssetDeleteDialog(t0) {
36033
36036
  let t10;
36034
36037
  return $[26] !== isLoading || $[27] !== onClose || $[28] !== t7 || $[29] !== t8 || $[30] !== t9 ? (t10 = /* @__PURE__ */ jsx(Dialog, { __unstable_autoFocus: isLoading, footer: t7, header: t8, id: "asset-dialog", onClickOutside: onClose, onClose, width: 1, children: t9 }), $[26] = isLoading, $[27] = onClose, $[28] = t7, $[29] = t8, $[30] = t9, $[31] = t10) : t10 = $[31], t10;
36035
36038
  }
36036
- function _temp$2y(acc, doc) {
36039
+ function _temp$2z(acc, doc) {
36037
36040
  return doc._id.startsWith("drafts.") ? acc.concat(doc._id.slice(7)) : acc;
36038
36041
  }
36039
36042
  const MENU_POPOVER_PROPS$2 = {
@@ -36089,7 +36092,7 @@ function AssetUsageDialog(t0) {
36089
36092
  } = useLegacyReferringDocuments(asset._id);
36090
36093
  let t1;
36091
36094
  if ($[0] !== referringDocuments) {
36092
- const drafts = referringDocuments.reduce(_temp$2x, []);
36095
+ const drafts = referringDocuments.reduce(_temp$2y, []);
36093
36096
  t1 = referringDocuments.filter((doc_0) => !drafts.includes(doc_0._id)), $[0] = referringDocuments, $[1] = t1;
36094
36097
  } else
36095
36098
  t1 = $[1];
@@ -36105,7 +36108,7 @@ function AssetUsageDialog(t0) {
36105
36108
  let t4;
36106
36109
  return $[10] !== onClose || $[11] !== t2 || $[12] !== t3 ? (t4 = /* @__PURE__ */ jsx(Dialog, { __unstable_autoFocus: !0, header: t2, id: "asset-dialog", onClickOutside: onClose, onClose, width: 1, children: t3 }), $[10] = onClose, $[11] = t2, $[12] = t3, $[13] = t4) : t4 = $[13], t4;
36107
36110
  }
36108
- function _temp$2x(acc, doc) {
36111
+ function _temp$2y(acc, doc) {
36109
36112
  return doc._id.startsWith("drafts.") ? acc.concat(doc._id.slice(7)) : acc;
36110
36113
  }
36111
36114
  const MIME_TYPES = {
@@ -36384,7 +36387,7 @@ const CardIconWrapper = styled.span`
36384
36387
  const handleToggleUsageDialog = t9;
36385
36388
  let t10;
36386
36389
  $[22] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t10 = () => {
36387
- setIsOpen(_temp$2w);
36390
+ setIsOpen(_temp$2x);
36388
36391
  }, $[22] = t10) : t10 = $[22];
36389
36392
  const handleToggleOpen = t10;
36390
36393
  let t11;
@@ -36500,7 +36503,7 @@ const CardIconWrapper = styled.span`
36500
36503
  t27
36501
36504
  ] }), $[100] = asset, $[101] = isSelected, $[102] = t26, $[103] = t27, $[104] = t28) : t28 = $[104], t28;
36502
36505
  };
36503
- function _temp$2w(prev) {
36506
+ function _temp$2x(prev) {
36504
36507
  return !prev;
36505
36508
  }
36506
36509
  const STYLES_FILENAME = {
@@ -36770,7 +36773,7 @@ const PER_PAGE = 200, ASSET_TYPE_IMAGE = "sanity.imageAsset", ASSET_TYPE_FILE =
36770
36773
  $[0] !== client ? (t0 = client.withConfig({
36771
36774
  apiVersion: "2023-02-14"
36772
36775
  }), $[0] = client, $[1] = t0) : t0 = $[1];
36773
- const versionedClient2 = t0, [_elementId] = useState(_temp$2v), currentPageNumber = useRef(0), {
36776
+ const versionedClient2 = t0, [_elementId] = useState(_temp$2w), currentPageNumber = useRef(0), {
36774
36777
  t
36775
36778
  } = useTranslation(), fetch$ = useRef(void 0);
36776
36779
  let t1;
@@ -36876,7 +36879,7 @@ const PER_PAGE = 200, ASSET_TYPE_IMAGE = "sanity.imageAsset", ASSET_TYPE_FILE =
36876
36879
  let t21;
36877
36880
  return $[61] !== _elementId || $[62] !== handleClose || $[63] !== hasResetAutoFocus || $[64] !== ref || $[65] !== t15 || $[66] !== t20 ? (t21 = /* @__PURE__ */ jsx(Dialog, { __unstable_autoFocus: hasResetAutoFocus, header: t15, id: _elementId, onClickOutside: handleClose, onClose: handleClose, ref, width: 2, children: t20 }), $[61] = _elementId, $[62] = handleClose, $[63] = hasResetAutoFocus, $[64] = ref, $[65] = t15, $[66] = t20, $[67] = t21) : t21 = $[67], t21;
36878
36881
  }, SelectAssetsDialog$1 = memo(forwardRef(SelectAssetsComponent));
36879
- function _temp$2v() {
36882
+ function _temp$2w() {
36880
36883
  return `default-asset-source-${uniqueId()}`;
36881
36884
  }
36882
36885
  function _temp2$12(type) {
@@ -37335,7 +37338,7 @@ function UploadPlaceholderComponent(props2) {
37335
37338
  } = useTranslation(), client = useClient(DEFAULT_STUDIO_CLIENT_OPTIONS), source = useSource();
37336
37339
  let result;
37337
37340
  if ($[0] !== assetSources || $[1] !== client || $[2] !== source || $[3] !== type) {
37338
- if (result = assetSources.filter(_temp$2u), result.length === 0) {
37341
+ if (result = assetSources.filter(_temp$2v), result.length === 0) {
37339
37342
  const options = {
37340
37343
  client,
37341
37344
  title: source.title || source.name
@@ -37387,7 +37390,7 @@ function UploadPlaceholderComponent(props2) {
37387
37390
  ] })
37388
37391
  ] }), $[26] = assetSourcesWithUpload.length, $[27] = browse, $[28] = collapsed, $[29] = directUploads, $[30] = hoveringFiles, $[31] = readOnly, $[32] = type, $[33] = uploadButton, $[34] = t3) : t3 = $[34], t3;
37389
37392
  }
37390
- function _temp$2u(s) {
37393
+ function _temp$2v(s) {
37391
37394
  return !!s.Uploader;
37392
37395
  }
37393
37396
  const UploadPlaceholder = memo(UploadPlaceholderComponent), STALE_UPLOAD_MS = 12e4, RatioBox$2 = styled(Card)`
@@ -37785,7 +37788,7 @@ function FilePreview$1(props2) {
37785
37788
  $[0] !== schemaType ? (t0 = get(schemaType, "options.accept", ""), $[0] = schemaType, $[1] = t0) : t0 = $[1];
37786
37789
  const accept = t0;
37787
37790
  let t1;
37788
- $[2] !== assetSources ? (t1 = assetSources.filter(_temp$2t), $[2] = assetSources, $[3] = t1) : t1 = $[3];
37791
+ $[2] !== assetSources ? (t1 = assetSources.filter(_temp$2u), $[2] = assetSources, $[3] = t1) : t1 = $[3];
37789
37792
  const assetSourcesWithUpload = t1;
37790
37793
  let t2;
37791
37794
  $[4] !== assetSources || $[5] !== setSelectedAssetSource ? (t2 = (event) => {
@@ -37870,7 +37873,7 @@ function FilePreview$1(props2) {
37870
37873
  let t9;
37871
37874
  return $[53] !== asset || $[54] !== observeAsset || $[55] !== t8 ? (t9 = /* @__PURE__ */ jsx(WithReferencedAsset, { reference: asset, observeAsset, waitPlaceholder: t7, children: t8 }), $[53] = asset, $[54] = observeAsset, $[55] = t8, $[56] = t9) : t9 = $[56], t9;
37872
37875
  }
37873
- function _temp$2t(s) {
37876
+ function _temp$2u(s) {
37874
37877
  return !!s.Uploader;
37875
37878
  }
37876
37879
  function InvalidFileWarning(t0) {
@@ -38131,7 +38134,7 @@ function BaseFileInput(props2) {
38131
38134
  break bb68;
38132
38135
  }
38133
38136
  case "error": {
38134
- event.files.forEach(_temp$2s), push({
38137
+ event.files.forEach(_temp$2t), push({
38135
38138
  status: "error",
38136
38139
  description: t("asset-sources.common.uploader.upload-failed.description"),
38137
38140
  title: t("asset-sources.common.uploader.upload-failed.title")
@@ -38192,7 +38195,7 @@ function BaseFileInput(props2) {
38192
38195
  function _temp2$11(file_0) {
38193
38196
  return file_0.status === "error" && isAssetLimitError(file_0.error);
38194
38197
  }
38195
- function _temp$2s(file_1) {
38198
+ function _temp$2t(file_1) {
38196
38199
  console.error(file_1.error);
38197
38200
  }
38198
38201
  function StudioFileInput(props2) {
@@ -38412,7 +38415,7 @@ function ImageInputAssetMenuWithReferenceAssetComponent(props2) {
38412
38415
  $[0] !== documentId || $[1] !== observeAsset ? (t0 = observeAsset(documentId), $[0] = documentId, $[1] = observeAsset, $[2] = t0) : t0 = $[2];
38413
38416
  const asset = useObservable(t0);
38414
38417
  let t1;
38415
- $[3] !== assetSources ? (t1 = assetSources.filter(_temp$2r), $[3] = assetSources, $[4] = t1) : t1 = $[4];
38418
+ $[3] !== assetSources ? (t1 = assetSources.filter(_temp$2s), $[3] = assetSources, $[4] = t1) : t1 = $[4];
38416
38419
  const assetSourcesWithUpload = t1;
38417
38420
  let t2;
38418
38421
  $[5] !== onSelectFile ? (t2 = (assetSource, files) => {
@@ -38467,7 +38470,7 @@ function ImageInputAssetMenuWithReferenceAssetComponent(props2) {
38467
38470
  let t6;
38468
38471
  return $[39] !== handleOpenDialog || $[40] !== isMenuOpen || $[41] !== setHotspotButtonElement || $[42] !== setMenuButtonElement || $[43] !== setMenuOpen || $[44] !== t4 || $[45] !== t5 ? (t6 = /* @__PURE__ */ jsx(ImageActionsMenu, { isMenuOpen, onEdit: handleOpenDialog, onMenuOpen: setMenuOpen, setHotspotButtonElement, setMenuButtonElement, showEdit: t4, children: t5 }), $[39] = handleOpenDialog, $[40] = isMenuOpen, $[41] = setHotspotButtonElement, $[42] = setMenuButtonElement, $[43] = setMenuOpen, $[44] = t4, $[45] = t5, $[46] = t6) : t6 = $[46], t6;
38469
38472
  }
38470
- function _temp$2r(s) {
38473
+ function _temp$2s(s) {
38471
38474
  return !!s.Uploader;
38472
38475
  }
38473
38476
  const ImageInputAssetMenuWithReferenceAsset = memo(ImageInputAssetMenuWithReferenceAssetComponent);
@@ -39643,7 +39646,7 @@ function ToolSVGComponent(props2) {
39643
39646
  const svgElement = svgRef.current;
39644
39647
  if (!svgElement)
39645
39648
  return;
39646
- const handleTouchMove = _temp$2q;
39649
+ const handleTouchMove = _temp$2r;
39647
39650
  return svgElement.addEventListener("touchmove", handleTouchMove, {
39648
39651
  passive: !1
39649
39652
  }), () => {
@@ -39894,7 +39897,7 @@ function ToolSVGComponent(props2) {
39894
39897
  t83
39895
39898
  ] }) }), $[217] = handlePointerMove, $[218] = handlePointerUp, $[219] = t19, $[220] = t23, $[221] = t24, $[222] = t30, $[223] = t35, $[224] = t36, $[225] = t47, $[226] = t77, $[227] = t83, $[228] = t84) : t84 = $[228], t84;
39896
39899
  }
39897
- function _temp$2q(e) {
39900
+ function _temp$2r(e) {
39898
39901
  e.preventDefault();
39899
39902
  }
39900
39903
  const ToolSVG = memo(ToolSVGComponent);
@@ -40041,7 +40044,7 @@ function ImageToolInput(props2) {
40041
40044
  $[8] !== onChange || $[9] !== readOnly || $[10] !== schemaType.fields ? (t7 = (finalValue) => {
40042
40045
  if (readOnly)
40043
40046
  return;
40044
- const cropField = schemaType.fields.find(_temp$2p), hotspotField = schemaType.fields.find(_temp2$10), crop = cropField ? {
40047
+ const cropField = schemaType.fields.find(_temp$2q), hotspotField = schemaType.fields.find(_temp2$10), crop = cropField ? {
40045
40048
  _type: cropField.type.name,
40046
40049
  ...finalValue.crop || DEFAULT_CROP
40047
40050
  } : finalValue.crop, hotspot = hotspotField ? {
@@ -40124,7 +40127,7 @@ function _temp3$v(t0) {
40124
40127
  function _temp2$10(field_0) {
40125
40128
  return field_0.type.name !== "object" && field_0.name === "hotspot";
40126
40129
  }
40127
- function _temp$2p(field) {
40130
+ function _temp$2q(field) {
40128
40131
  return field.name === "crop" && field.type.name !== "object";
40129
40132
  }
40130
40133
  function ImageInputHotspotInput(props2) {
@@ -40387,7 +40390,7 @@ function BaseImageInputComponent(props2) {
40387
40390
  const handleClearField = t5;
40388
40391
  let t6;
40389
40392
  $[19] !== onChange || $[20] !== value || $[21] !== valueIsArrayElement ? (t6 = () => {
40390
- const allKeys = Object.keys(value || {}), isEmpty2 = allKeys.filter(_temp$2o).length === 0, removeKeys = ["asset", "media"].concat(allKeys.filter(_temp2$$)).map(_temp3$u);
40393
+ const allKeys = Object.keys(value || {}), isEmpty2 = allKeys.filter(_temp$2p).length === 0, removeKeys = ["asset", "media"].concat(allKeys.filter(_temp2$$)).map(_temp3$u);
40391
40394
  onChange(isEmpty2 && !valueIsArrayElement() ? unset() : removeKeys);
40392
40395
  }, $[19] = onChange, $[20] = value, $[21] = valueIsArrayElement, $[22] = t6) : t6 = $[22];
40393
40396
  const handleRemoveButtonClick = t6;
@@ -40547,7 +40550,7 @@ function _temp3$u(key_1) {
40547
40550
  function _temp2$$(key_0) {
40548
40551
  return ["crop", "hotspot", "_upload"].includes(key_0);
40549
40552
  }
40550
- function _temp$2o(key) {
40553
+ function _temp$2p(key) {
40551
40554
  return !["_type", "_key", "_upload", "asset", "crop", "hotspot", "media"].includes(key);
40552
40555
  }
40553
40556
  const BaseImageInput = memo(BaseImageInputComponent);
@@ -40832,7 +40835,7 @@ function TagsArrayInput(props2) {
40832
40835
  $[0] !== t0 ? (t1 = t0 === void 0 ? [] : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
40833
40836
  const value = t1;
40834
40837
  let t2;
40835
- $[2] !== value ? (t2 = value?.map(_temp$2n), $[2] = value, $[3] = t2) : t2 = $[3];
40838
+ $[2] !== value ? (t2 = value?.map(_temp$2o), $[2] = value, $[3] = t2) : t2 = $[3];
40836
40839
  const tagInputValue = t2;
40837
40840
  let t3;
40838
40841
  $[4] !== onChange ? (t3 = (nextValue) => {
@@ -40847,7 +40850,7 @@ function TagsArrayInput(props2) {
40847
40850
  function _temp2$_(v_0) {
40848
40851
  return v_0.value;
40849
40852
  }
40850
- function _temp$2n(v) {
40853
+ function _temp$2o(v) {
40851
40854
  return {
40852
40855
  value: v
40853
40856
  };
@@ -40924,11 +40927,11 @@ function SelectInput(props2) {
40924
40927
  }
40925
40928
  handleChange(nextItem_0);
40926
40929
  }, $[12] = handleChange, $[13] = itemFromOptionValue, $[14] = t6) : t6 = $[14];
40927
- const handleSelectChange = t6, content = isRadio ? /* @__PURE__ */ jsx(RadioSelect, { ...elementProps, value: currentItem, inputId, items, direction: schemaType.options?.direction || "vertical", customValidity: validationError, onChange: handleChange, readOnly }) : /* @__PURE__ */ jsx(Select, { ...elementProps, customValidity: validationError, value: optionValueFromItem(currentItem), readOnly, onChange: handleSelectChange, children: [EMPTY_ITEM, ...items].map(_temp$2m) }), t7 = !!focused;
40930
+ const handleSelectChange = t6, content = isRadio ? /* @__PURE__ */ jsx(RadioSelect, { ...elementProps, value: currentItem, inputId, items, direction: schemaType.options?.direction || "vertical", customValidity: validationError, onChange: handleChange, readOnly }) : /* @__PURE__ */ jsx(Select, { ...elementProps, customValidity: validationError, value: optionValueFromItem(currentItem), readOnly, onChange: handleSelectChange, children: [EMPTY_ITEM, ...items].map(_temp$2n) }), t7 = !!focused;
40928
40931
  let t8;
40929
40932
  return $[15] !== changed || $[16] !== content || $[17] !== path || $[18] !== t7 ? (t8 = /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: t7, children: content }), $[15] = changed, $[16] = content, $[17] = path, $[18] = t7, $[19] = t8) : t8 = $[19], t8;
40930
40933
  }
40931
- function _temp$2m(item_1, i) {
40934
+ function _temp$2n(item_1, i) {
40932
40935
  return /* @__PURE__ */ jsx("option", { value: i - 1, children: item_1.title }, `${i - 1}`);
40933
40936
  }
40934
40937
  const RadioSelect = forwardRef(function(props2, ref) {
@@ -41080,7 +41083,7 @@ function PreviewItem(props2) {
41080
41083
  const presence = t7, childValidation = useChildValidation(path, !0);
41081
41084
  let t8;
41082
41085
  $[14] !== childValidation ? (t8 = childValidation.length === 0 ? null : /* @__PURE__ */ jsx(Box, { paddingX: 1, paddingY: 3, children: /* @__PURE__ */ jsx(FormFieldValidationStatus, { validation: childValidation, __unstable_showSummary: !0 }) }), $[14] = childValidation, $[15] = t8) : t8 = $[15];
41083
- const validation2 = t8, hasErrors = childValidation.some(_temp$2l), hasWarnings = childValidation.some(_temp2$Z), [contextMenuButtonElement, setContextMenuButtonElement] = useState(null), t9 = parentSchemaType.options?.insertMenu;
41086
+ const validation2 = t8, hasErrors = childValidation.some(_temp$2m), hasWarnings = childValidation.some(_temp2$Z), [contextMenuButtonElement, setContextMenuButtonElement] = useState(null), t9 = parentSchemaType.options?.insertMenu;
41084
41087
  let t10;
41085
41088
  $[16] !== contextMenuButtonElement || $[17] !== handleInsert || $[18] !== insertableTypes || $[19] !== t9 ? (t10 = {
41086
41089
  schemaTypes: insertableTypes,
@@ -41161,7 +41164,7 @@ function PreviewItem(props2) {
41161
41164
  function _temp2$Z(v_0) {
41162
41165
  return v_0.level === "warning";
41163
41166
  }
41164
- function _temp$2l(v) {
41167
+ function _temp$2m(v) {
41165
41168
  return v.level === "error";
41166
41169
  }
41167
41170
  function ReferenceItemRefProvider(props2) {
@@ -41233,7 +41236,7 @@ function ReferenceItem(props2) {
41233
41236
  $[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = (hadFocus, hasFocus) => {
41234
41237
  !hadFocus && hasFocus && elementRef.current && elementRef.current?.focus();
41235
41238
  }, $[4] = t2) : t2 = $[4], useDidUpdate(focused, t2);
41236
- const hasErrors = props2.validation.some(_temp$2k), hasWarnings = props2.validation.some(_temp2$Y), resolvingInitialValue = value._resolvingInitialValue;
41239
+ const hasErrors = props2.validation.some(_temp$2l), hasWarnings = props2.validation.some(_temp2$Y), resolvingInitialValue = value._resolvingInitialValue;
41237
41240
  let t3;
41238
41241
  $[5] !== onInsert || $[6] !== value ? (t3 = () => {
41239
41242
  onInsert({
@@ -41370,7 +41373,7 @@ function ReferenceItem(props2) {
41370
41373
  function _temp2$Y(v_0) {
41371
41374
  return v_0.level === "warning";
41372
41375
  }
41373
- function _temp$2k(v) {
41376
+ function _temp$2l(v) {
41374
41377
  return v.level === "error";
41375
41378
  }
41376
41379
  function defaultResolveItemComponent(schemaType) {
@@ -42421,14 +42424,14 @@ function useVisibility(props2) {
42421
42424
  if (!element || disabled)
42422
42425
  return;
42423
42426
  element && "checkVisibility" in element && setVisible(element.checkVisibility());
42424
- const isDocumentVisible$ = concat(of(!document.hidden), visibilityChange$.pipe(map(_temp$2j))).pipe(distinctUntilChanged()), inViewport$ = intersectionObservableFor(element).pipe(map(_temp2$X)), sub2 = isDocumentVisible$.pipe(switchMap((isDocumentVisible) => isDocumentVisible ? inViewport$ : of(!1)), switchMap((isVisible2) => isVisible2 ? of(!0) : of(!1).pipe(delay(hideDelay))), distinctUntilChanged()).subscribe(setVisible);
42427
+ const isDocumentVisible$ = concat(of(!document.hidden), visibilityChange$.pipe(map(_temp$2k))).pipe(distinctUntilChanged()), inViewport$ = intersectionObservableFor(element).pipe(map(_temp2$X)), sub2 = isDocumentVisible$.pipe(switchMap((isDocumentVisible) => isDocumentVisible ? inViewport$ : of(!1)), switchMap((isVisible2) => isVisible2 ? of(!0) : of(!1).pipe(delay(hideDelay))), distinctUntilChanged()).subscribe(setVisible);
42425
42428
  return () => sub2.unsubscribe();
42426
42429
  }, t2 = [element, hideDelay, disabled], $[0] = disabled, $[1] = element, $[2] = hideDelay, $[3] = t1, $[4] = t2) : (t1 = $[3], t2 = $[4]), useLayoutEffect(t1, t2), disabled ? !1 : visible;
42427
42430
  }
42428
42431
  function _temp2$X(event_0) {
42429
42432
  return event_0.isIntersecting;
42430
42433
  }
42431
- function _temp$2j(event) {
42434
+ function _temp$2k(event) {
42432
42435
  return event.target instanceof Document ? !event?.target?.hidden : !1;
42433
42436
  }
42434
42437
  const _HIDE_DELAY = 2e3;
@@ -42582,7 +42585,7 @@ function FormBuilderProvider(props2) {
42582
42585
  assetSources: file.assetSources,
42583
42586
  directUploads: t6
42584
42587
  }, $[5] = file.assetSources, $[6] = t6, $[7] = t7) : t7 = $[7];
42585
- const t8 = filterField || _temp$2i, t9 = image?.directUploads !== !1;
42588
+ const t8 = filterField || _temp$2j, t9 = image?.directUploads !== !1;
42586
42589
  let t10;
42587
42590
  $[8] !== image.assetSources || $[9] !== t9 ? (t10 = {
42588
42591
  assetSources: image.assetSources,
@@ -42634,7 +42637,7 @@ function FormBuilderProvider(props2) {
42634
42637
  let t18;
42635
42638
  return $[58] !== formBuilder || $[59] !== t17 ? (t18 = /* @__PURE__ */ jsx(FormBuilderContext.Provider, { value: formBuilder, children: t17 }), $[58] = formBuilder, $[59] = t17, $[60] = t18) : t18 = $[60], t18;
42636
42639
  }
42637
- function _temp$2i() {
42640
+ function _temp$2j() {
42638
42641
  return !0;
42639
42642
  }
42640
42643
  function FormProvider(props2) {
@@ -42789,7 +42792,7 @@ function FormBuilder(props2) {
42789
42792
  }, $[40] = handleBlur, $[41] = handleFocus, $[42] = id2, $[43] = t19) : t19 = $[43];
42790
42793
  const t20 = diffProps.__unstable_computeDiff;
42791
42794
  let t21;
42792
- $[44] !== members ? (t21 = members.some(_temp$2h), $[44] = members, $[45] = t21) : t21 = $[45];
42795
+ $[44] !== members ? (t21 = members.some(_temp$2i), $[44] = members, $[45] = t21) : t21 = $[45];
42793
42796
  let t22;
42794
42797
  $[46] !== compareValue || $[47] !== diffProps.__unstable_computeDiff || $[48] !== diffProps.hasUpstreamVersion || $[49] !== focusPath || $[50] !== focused || $[51] !== groups || $[52] !== handleChange || $[53] !== handleCloseField || $[54] !== handleCollapseField || $[55] !== handleCollapseFieldSet || $[56] !== handleExpandField || $[57] !== handleExpandFieldSet || $[58] !== handleOpenField || $[59] !== handleSelectFieldGroup || $[60] !== id2 || $[61] !== members || $[62] !== onPathFocus || $[63] !== readOnly || $[64] !== renderAnnotation || $[65] !== renderBlock2 || $[66] !== renderField || $[67] !== renderInlineBlock || $[68] !== renderInput || $[69] !== renderItem2 || $[70] !== renderPreview || $[71] !== schemaType || $[72] !== t19 || $[73] !== t21 || $[74] !== value ? (t22 = {
42795
42798
  focusPath,
@@ -42841,7 +42844,7 @@ function FormBuilder(props2) {
42841
42844
  let t29;
42842
42845
  return $[93] !== autoFocus || $[94] !== changesOpen || $[95] !== collapsedFieldSets || $[96] !== collapsedPaths || $[97] !== fieldActions || $[98] !== focusPath || $[99] !== focused || $[100] !== groups || $[101] !== id2 || $[102] !== onChange || $[103] !== onFieldGroupSelect || $[104] !== onPathBlur || $[105] !== onPathFocus || $[106] !== onPathOpen || $[107] !== onSetFieldSetCollapsed || $[108] !== onSetPathCollapsed || $[109] !== patchChannel || $[110] !== presence || $[111] !== readOnly || $[112] !== schemaType || $[113] !== t28 || $[114] !== validation2 ? (t29 = /* @__PURE__ */ jsx(FormProvider, { __internal_fieldActions: fieldActions, __internal_patchChannel: patchChannel, autoFocus, changesOpen, collapsedFieldSets, collapsedPaths, focusPath, focused, groups, id: id2, onChange, onPathBlur, onPathFocus, onPathOpen, onFieldGroupSelect, onSetPathCollapsed, onSetFieldSetCollapsed, presence, validation: validation2, readOnly, schemaType, children: t28 }), $[93] = autoFocus, $[94] = changesOpen, $[95] = collapsedFieldSets, $[96] = collapsedPaths, $[97] = fieldActions, $[98] = focusPath, $[99] = focused, $[100] = groups, $[101] = id2, $[102] = onChange, $[103] = onFieldGroupSelect, $[104] = onPathBlur, $[105] = onPathFocus, $[106] = onPathOpen, $[107] = onSetFieldSetCollapsed, $[108] = onSetPathCollapsed, $[109] = patchChannel, $[110] = presence, $[111] = readOnly, $[112] = schemaType, $[113] = t28, $[114] = validation2, $[115] = t29) : t29 = $[115], t29;
42843
42846
  }
42844
- function _temp$2h(m) {
42847
+ function _temp$2i(m) {
42845
42848
  return m.kind === "field" && m.field.changed;
42846
42849
  }
42847
42850
  function RootInput(props2) {
@@ -43276,7 +43279,7 @@ const DefaultBlockObjectComponent = (props2) => {
43276
43279
  validation: validation2
43277
43280
  } = props2, {
43278
43281
  t
43279
- } = useTranslation(), isImagePreview = isImage(value), hasError = validation2.filter(_temp$2g).length > 0, hasWarning = validation2.filter(_temp2$W).length > 0, hasMarkers = markers.length > 0, tone = selected || focused ? "primary" : "default", uploadState = value[UPLOAD_STATUS_KEY], uploadProgress = typeof uploadState?.progress == "number" ? uploadState?.progress : void 0;
43282
+ } = useTranslation(), isImagePreview = isImage(value), hasError = validation2.filter(_temp$2h).length > 0, hasWarning = validation2.filter(_temp2$W).length > 0, hasMarkers = markers.length > 0, tone = selected || focused ? "primary" : "default", uploadState = value[UPLOAD_STATUS_KEY], uploadProgress = typeof uploadState?.progress == "number" ? uploadState?.progress : void 0;
43280
43283
  let t0;
43281
43284
  $[0] !== onOpen ? (t0 = (e) => {
43282
43285
  e.preventDefault(), e.stopPropagation(), onOpen();
@@ -43307,7 +43310,7 @@ const DefaultBlockObjectComponent = (props2) => {
43307
43310
  t14
43308
43311
  ] }), $[40] = t13, $[41] = t14, $[42] = t15) : t15 = $[42], t15;
43309
43312
  };
43310
- function _temp$2g(v) {
43313
+ function _temp$2h(v) {
43311
43314
  return v.level === "error";
43312
43315
  }
43313
43316
  function _temp2$W(v_0) {
@@ -44247,9 +44250,9 @@ const INITIAL_STATE$6 = {
44247
44250
  function useObserveDocument(documentId, apiConfig) {
44248
44251
  const $ = c(4), documentPreviewStore = useDocumentPreviewStore();
44249
44252
  let t0;
44250
- return $[0] !== apiConfig || $[1] !== documentId || $[2] !== documentPreviewStore ? (t0 = documentPreviewStore.unstable_observeDocument(documentId, apiConfig).pipe(map(_temp$2f)), $[0] = apiConfig, $[1] = documentId, $[2] = documentPreviewStore, $[3] = t0) : t0 = $[3], useObservable(t0, INITIAL_STATE$6);
44253
+ return $[0] !== apiConfig || $[1] !== documentId || $[2] !== documentPreviewStore ? (t0 = documentPreviewStore.unstable_observeDocument(documentId, apiConfig).pipe(map(_temp$2g)), $[0] = apiConfig, $[1] = documentId, $[2] = documentPreviewStore, $[3] = t0) : t0 = $[3], useObservable(t0, INITIAL_STATE$6);
44251
44254
  }
44252
- function _temp$2f(document2) {
44255
+ function _temp$2g(document2) {
44253
44256
  return {
44254
44257
  loading: !1,
44255
44258
  document: document2
@@ -44293,14 +44296,14 @@ function getPreviewValueWithFallback({
44293
44296
  function useReleasesIds(releases2) {
44294
44297
  const $ = c(4);
44295
44298
  let t0;
44296
- $[0] !== releases2 ? (t0 = releases2.map(_temp$2e), $[0] = releases2, $[1] = t0) : t0 = $[1];
44299
+ $[0] !== releases2 ? (t0 = releases2.map(_temp$2f), $[0] = releases2, $[1] = t0) : t0 = $[1];
44297
44300
  const releasesIds = t0;
44298
44301
  let t1;
44299
44302
  return $[2] !== releasesIds ? (t1 = {
44300
44303
  releasesIds
44301
44304
  }, $[2] = releasesIds, $[3] = t1) : t1 = $[3], t1;
44302
44305
  }
44303
- function _temp$2e(release) {
44306
+ function _temp$2f(release) {
44304
44307
  return getReleaseIdFromReleaseDocumentId(release._id);
44305
44308
  }
44306
44309
  function exists(value) {
@@ -44320,7 +44323,7 @@ function useDocumentVersionInfo(documentId) {
44320
44323
  if ($[7] !== documentPreviewStore || $[8] !== draftId || $[9] !== publishedId || $[10] !== releaseIds) {
44321
44324
  const releaseVersions = releaseIds.length > 0 ? combineLatest(Object.fromEntries(releaseIds.map((releaseId) => [releaseId, documentPreviewStore.observePaths({
44322
44325
  _id: getVersionId(publishedId, releaseId)
44323
- }, DOCUMENT_STUB_PATHS).pipe(map(_temp$2d))]))) : of(NO_VERSIONS);
44326
+ }, DOCUMENT_STUB_PATHS).pipe(map(_temp$2e))]))) : of(NO_VERSIONS);
44324
44327
  t3 = combineLatest({
44325
44328
  isLoading: of(!1),
44326
44329
  draft: documentPreviewStore.observePaths({
@@ -44348,7 +44351,7 @@ function _temp3$t(value_1) {
44348
44351
  function _temp2$V(value_0) {
44349
44352
  return exists(value_0) ? value_0 : void 0;
44350
44353
  }
44351
- function _temp$2d(value) {
44354
+ function _temp$2e(value) {
44352
44355
  return exists(value) ? value : void 0;
44353
44356
  }
44354
44357
  function useCopyToDrafts(options) {
@@ -44485,7 +44488,7 @@ const orderedReleaseTypes$1 = ["asap", "scheduled", "undecided"], useDocumentVer
44485
44488
  _id
44486
44489
  } = t4;
44487
44490
  return documentVersions.some((id2) => getVersionFromId(id2) === getReleaseIdFromReleaseDocumentId(_id));
44488
- }, $[5] = documentVersions, $[6] = t32) : t32 = $[6], t2 = releases2.filter(t32).sort(_temp$2c), $[2] = documentVersions, $[3] = releases2, $[4] = t2;
44491
+ }, $[5] = documentVersions, $[6] = t32) : t32 = $[6], t2 = releases2.filter(t32).sort(_temp$2d), $[2] = documentVersions, $[3] = releases2, $[4] = t2;
44489
44492
  } else
44490
44493
  t2 = $[4];
44491
44494
  const sortedDocumentList = t2;
@@ -44494,7 +44497,7 @@ const orderedReleaseTypes$1 = ["asap", "scheduled", "undecided"], useDocumentVer
44494
44497
  sortedDocumentList
44495
44498
  }, $[7] = sortedDocumentList, $[8] = t3) : t3 = $[8], t3;
44496
44499
  };
44497
- function _temp$2c(releasesList, compareReleasesList) {
44500
+ function _temp$2d(releasesList, compareReleasesList) {
44498
44501
  if (releasesList.metadata.releaseType === "scheduled" && compareReleasesList.metadata.releaseType === "scheduled") {
44499
44502
  const aPublishAt = releasesList.publishAt || releasesList.metadata.intendedPublishAt;
44500
44503
  if (!aPublishAt)
@@ -44522,9 +44525,9 @@ const useIsReleaseActive = () => {
44522
44525
  data: documentVersions
44523
44526
  } = useDocumentVersions(t1);
44524
44527
  let t2;
44525
- return $[2] !== documentVersions ? (t2 = documentVersions && documentVersions.length > 0 && !documentVersions.some(_temp$2b), $[2] = documentVersions, $[3] = t2) : t2 = $[3], t2;
44528
+ return $[2] !== documentVersions ? (t2 = documentVersions && documentVersions.length > 0 && !documentVersions.some(_temp$2c), $[2] = documentVersions, $[3] = t2) : t2 = $[3], t2;
44526
44529
  };
44527
- function _temp$2b(version2) {
44530
+ function _temp$2c(version2) {
44528
44531
  return !isVersionId(version2);
44529
44532
  }
44530
44533
  function useGetDefaultPerspective() {
@@ -44823,7 +44826,7 @@ const Z_OFFSET$1 = {
44823
44826
  type: "contentReleases"
44824
44827
  }, RELEASE_FORM_STORAGE_KEY = "studio.release-form.recovery";
44825
44828
  function useReleaseFormStorage() {
44826
- const $ = c(1), getStoredReleaseData = _temp$2a, saveReleaseDataToStorage = _temp2$U, clearReleaseDataFromStorage = _temp3$s;
44829
+ const $ = c(1), getStoredReleaseData = _temp$2b, saveReleaseDataToStorage = _temp2$U, clearReleaseDataFromStorage = _temp3$s;
44827
44830
  let t0;
44828
44831
  return $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
44829
44832
  getStoredReleaseData,
@@ -44837,7 +44840,7 @@ function _temp3$s() {
44837
44840
  function _temp2$U(data) {
44838
44841
  localStorage.setItem(RELEASE_FORM_STORAGE_KEY, JSON.stringify(data));
44839
44842
  }
44840
- function _temp$2a() {
44843
+ function _temp$2b() {
44841
44844
  const stored = localStorage.getItem(RELEASE_FORM_STORAGE_KEY);
44842
44845
  return stored ? JSON.parse(stored) : void 0;
44843
44846
  }
@@ -45058,7 +45061,7 @@ function TitleDescriptionForm(t0) {
45058
45061
  $[2] !== release ? (t2 = {
45059
45062
  externalValue: release,
45060
45063
  id: release._id,
45061
- extractData: _temp$29
45064
+ extractData: _temp$2a
45062
45065
  }, $[2] = release, $[3] = t2) : t2 = $[3];
45063
45066
  const {
45064
45067
  localData,
@@ -45120,7 +45123,7 @@ function TitleDescriptionForm(t0) {
45120
45123
  t12
45121
45124
  ] }), $[38] = t11, $[39] = t12, $[40] = t13) : t13 = $[40], t13;
45122
45125
  }
45123
- function _temp$29(t0) {
45126
+ function _temp$2a(t0) {
45124
45127
  const {
45125
45128
  metadata
45126
45129
  } = t0;
@@ -45399,7 +45402,7 @@ function InsufficientPermissionsMessage(t0) {
45399
45402
  }, $[0] = t1) : t1 = $[0];
45400
45403
  const list = useListFormat(t1), roles = currentUser?.roles || EMPTY_ARRAY$i;
45401
45404
  let t2;
45402
- $[1] !== list || $[2] !== roles ? (t2 = () => /* @__PURE__ */ jsx(Fragment$1, { children: list.formatToParts(roles.map(_temp$28)).map(_temp2$T) }), $[1] = list, $[2] = roles, $[3] = t2) : t2 = $[3];
45405
+ $[1] !== list || $[2] !== roles ? (t2 = () => /* @__PURE__ */ jsx(Fragment$1, { children: list.formatToParts(roles.map(_temp$29)).map(_temp2$T) }), $[1] = list, $[2] = roles, $[3] = t2) : t2 = $[3];
45403
45406
  const Roles = t2;
45404
45407
  let t3;
45405
45408
  $[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = /* @__PURE__ */ jsx(Text$1, { size: 0, children: /* @__PURE__ */ jsx(AccessDeniedIcon, {}) }), $[4] = t3) : t3 = $[4];
@@ -45428,7 +45431,7 @@ function InsufficientPermissionsMessage(t0) {
45428
45431
  function _temp2$T(i, index) {
45429
45432
  return i.type === "element" ? /* @__PURE__ */ jsx("code", { children: i.value }, `${i.value}-${index}`) : /* @__PURE__ */ jsx(Fragment, { children: i.value }, `${i.value}-${index}`);
45430
45433
  }
45431
- function _temp$28(role) {
45434
+ function _temp$29(role) {
45432
45435
  return role.title || startCase(role.name);
45433
45436
  }
45434
45437
  const useDiscardVersionAction = (props2) => {
@@ -45518,7 +45521,7 @@ function useArchivedReleases() {
45518
45521
  loading
45519
45522
  } = useAllReleases();
45520
45523
  let t0;
45521
- $[0] !== releases2 ? (t0 = Array.from(releases2.values()).filter(_temp$27), $[0] = releases2, $[1] = t0) : t0 = $[1];
45524
+ $[0] !== releases2 ? (t0 = Array.from(releases2.values()).filter(_temp$28), $[0] = releases2, $[1] = t0) : t0 = $[1];
45522
45525
  const archivedReleases = t0;
45523
45526
  let t1;
45524
45527
  return $[2] !== archivedReleases || $[3] !== error || $[4] !== loading ? (t1 = {
@@ -45527,7 +45530,7 @@ function useArchivedReleases() {
45527
45530
  loading
45528
45531
  }, $[2] = archivedReleases, $[3] = error, $[4] = loading, $[5] = t1) : t1 = $[5], t1;
45529
45532
  }
45530
- function _temp$27(release) {
45533
+ function _temp$28(release) {
45531
45534
  return ARCHIVED_RELEASE_STATES.includes(release.state);
45532
45535
  }
45533
45536
  function UnpublishVersionDialog(props2) {
@@ -45757,7 +45760,7 @@ const RELEASES_NAME = "sanity/releases", RELEASES_INTENT = "release", releases =
45757
45760
  getMetadataStateForSlugs$
45758
45761
  } = useReleasesStore(), [releasesMetadata, setReleasesMetadata] = useState(null);
45759
45762
  let t2;
45760
- $[1] !== getMetadataStateForSlugs$ || $[2] !== listenerReleaseIds ? (t2 = getMetadataStateForSlugs$(listenerReleaseIds.map(_temp$26)), $[1] = getMetadataStateForSlugs$, $[2] = listenerReleaseIds, $[3] = t2) : t2 = $[3];
45763
+ $[1] !== getMetadataStateForSlugs$ || $[2] !== listenerReleaseIds ? (t2 = getMetadataStateForSlugs$(listenerReleaseIds.map(_temp$27)), $[1] = getMetadataStateForSlugs$, $[2] = listenerReleaseIds, $[3] = t2) : t2 = $[3];
45761
45764
  const observedResult = useObservable(t2) || DEFAULT_METADATA_STATE;
45762
45765
  let t3, t4;
45763
45766
  $[4] !== observedResult.data ? (t3 = () => setReleasesMetadata((prevReleaseMetadata) => observedResult.data ? {
@@ -45823,7 +45826,7 @@ const RELEASES_NAME = "sanity/releases", RELEASES_INTENT = "release", releases =
45823
45826
  removeReleaseIdsFromListener: _temp4$b
45824
45827
  }, $[0] = contextValue, $[1] = t0) : t0 = $[1], t0;
45825
45828
  };
45826
- function _temp$26(slug) {
45829
+ function _temp$27(slug) {
45827
45830
  return slug;
45828
45831
  }
45829
45832
  function _temp2$S(releaseId) {
@@ -45982,7 +45985,7 @@ function ReleasesUpsellProvider(props2) {
45982
45985
  t
45983
45986
  } = useTranslation();
45984
45987
  let t1;
45985
- $[1] !== allActiveReleases ? (t1 = allActiveReleases.filter(_temp$25), $[1] = allActiveReleases, $[2] = t1) : t1 = $[2];
45988
+ $[1] !== allActiveReleases ? (t1 = allActiveReleases.filter(_temp$26), $[1] = allActiveReleases, $[2] = t1) : t1 = $[2];
45986
45989
  const meteredActiveReleases = t1;
45987
45990
  let t2;
45988
45991
  bb0: {
@@ -46101,7 +46104,7 @@ function ReleasesUpsellProvider(props2) {
46101
46104
  t12
46102
46105
  ] }), $[43] = ctxValue, $[44] = props2.children, $[45] = t12, $[46] = t13) : t13 = $[46], t13;
46103
46106
  }
46104
- function _temp$25(release) {
46107
+ function _temp$26(release) {
46105
46108
  return !isCardinalityOneRelease(release);
46106
46109
  }
46107
46110
  function ReleasesStudioLayout(props2) {
@@ -46903,7 +46906,7 @@ function useProjectSubscriptions() {
46903
46906
  }), $[2] = t1) : t1 = $[2], t0 = t1;
46904
46907
  break bb0;
46905
46908
  }
46906
- t0 = projectSubscriptions$.pipe(map(_temp$24), startWith(INITIAL_LOADING_STATE), catchError(_temp2$R));
46909
+ t0 = projectSubscriptions$.pipe(map(_temp$25), startWith(INITIAL_LOADING_STATE), catchError(_temp2$R));
46907
46910
  }
46908
46911
  $[0] = projectId, $[1] = t0;
46909
46912
  } else
@@ -46917,7 +46920,7 @@ function _temp2$R(error) {
46917
46920
  error
46918
46921
  });
46919
46922
  }
46920
- function _temp$24(cachedSubscriptions) {
46923
+ function _temp$25(cachedSubscriptions) {
46921
46924
  return {
46922
46925
  isLoading: !1,
46923
46926
  projectSubscriptions: cachedSubscriptions,
@@ -46962,7 +46965,7 @@ function ArchivedReleaseBanner(t0) {
46962
46965
  retentionDays,
46963
46966
  removalDate: removalDate || ""
46964
46967
  }, components: {
46965
- Link: _temp$23
46968
+ Link: _temp$24
46966
46969
  } }) }), $[10] = removalDate, $[11] = retentionDays, $[12] = tRelease, $[13] = t5) : t5 = $[13];
46967
46970
  let t6;
46968
46971
  return $[14] !== t4 || $[15] !== t5 ? (t6 = /* @__PURE__ */ jsx(Card, { padding: 4, radius: 4, tone: "primary", "data-testid": "retention-policy-card", children: /* @__PURE__ */ jsxs(Flex, { gap: 3, children: [
@@ -46973,7 +46976,7 @@ function ArchivedReleaseBanner(t0) {
46973
46976
  ] })
46974
46977
  ] }) }), $[14] = t4, $[15] = t5, $[16] = t6) : t6 = $[16], t6;
46975
46978
  }
46976
- function _temp$23(t0) {
46979
+ function _temp$24(t0) {
46977
46980
  const {
46978
46981
  children
46979
46982
  } = t0;
@@ -47256,7 +47259,7 @@ function ProgressIcon(props2) {
47256
47259
  let t0;
47257
47260
  if ($[3] !== progress) {
47258
47261
  const circlePath = partialCircle(12.5, 12.5, 4.5, degreesToRadians(-90), degreesToRadians(progress * 360 - 90));
47259
- t0 = circlePath.length > 0 ? `${circlePath.map(_temp$22).join(" ")} L 12.5 12.5 Z` : void 0, $[3] = progress, $[4] = t0;
47262
+ t0 = circlePath.length > 0 ? `${circlePath.map(_temp$23).join(" ")} L 12.5 12.5 Z` : void 0, $[3] = progress, $[4] = t0;
47260
47263
  } else
47261
47264
  t0 = $[4];
47262
47265
  const d = t0;
@@ -47270,7 +47273,7 @@ function ProgressIcon(props2) {
47270
47273
  t2
47271
47274
  ] }), $[8] = rest, $[9] = t1, $[10] = t3) : t3 = $[10], t3;
47272
47275
  }
47273
- function _temp$22(vs) {
47276
+ function _temp$23(vs) {
47274
47277
  return vs.join(" ");
47275
47278
  }
47276
47279
  function partialCircle(cx, cy, r, start, end) {
@@ -47460,7 +47463,7 @@ const ReleasePublishAllButton = (t0) => {
47460
47463
  enabled: isDraftModelEnabled
47461
47464
  } = t2, [publishBundleStatus, setPublishBundleStatus] = useState("idle"), [publishPermission, setPublishPermission] = useState(!1);
47462
47465
  let t3;
47463
- $[0] !== documents ? (t3 = documents.some(_temp$21), $[0] = documents, $[1] = t3) : t3 = $[1];
47466
+ $[0] !== documents ? (t3 = documents.some(_temp$22), $[0] = documents, $[1] = t3) : t3 = $[1];
47464
47467
  const isValidatingDocuments = t3;
47465
47468
  let t4;
47466
47469
  $[2] !== documents ? (t4 = documents.some(_temp2$Q), $[2] = documents, $[3] = t4) : t4 = $[3];
@@ -47586,7 +47589,7 @@ const ReleasePublishAllButton = (t0) => {
47586
47589
  confirmPublishDialog
47587
47590
  ] }), $[82] = confirmPublishDialog, $[83] = t17, $[84] = t18) : t18 = $[84], t18;
47588
47591
  };
47589
- function _temp$21(t0) {
47592
+ function _temp$22(t0) {
47590
47593
  const {
47591
47594
  validation: validation2
47592
47595
  } = t0;
@@ -47642,7 +47645,7 @@ const useIsReleasesPlus = () => {
47642
47645
  }
47643
47646
  let t42;
47644
47647
  if ($[5] !== client || $[6] !== dataset || $[7] !== observableClient || $[8] !== releaseDocuments || $[9] !== transactionId) {
47645
- const publishedDocuments = releaseDocuments.map(_temp$20);
47648
+ const publishedDocuments = releaseDocuments.map(_temp$21);
47646
47649
  t42 = from(getTransactionsLogs(client, publishedDocuments.map(_temp2$P), {
47647
47650
  toTransaction: transactionId,
47648
47651
  reverse: !0
@@ -47690,7 +47693,7 @@ const useIsReleasesPlus = () => {
47690
47693
  let t6;
47691
47694
  return $[14] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t6 = () => resolvedDocumentRevertStatesResultRef.current ? Promise.resolve(resolvedDocumentRevertStatesResultRef.current) : resultPromiseRef.current, $[14] = t6) : t6 = $[14], t6;
47692
47695
  };
47693
- function _temp$20(t0) {
47696
+ function _temp$21(t0) {
47694
47697
  const {
47695
47698
  document: document2
47696
47699
  } = t0;
@@ -47727,14 +47730,14 @@ const usePostPublishTransactions = (documents) => {
47727
47730
  break bb0;
47728
47731
  }
47729
47732
  let t1;
47730
- $[1] !== client || $[2] !== documents || $[3] !== transactionId ? (t1 = from(getTransactionsLogs(client, documents.map(_temp$1$), {
47733
+ $[1] !== client || $[2] !== documents || $[3] !== transactionId ? (t1 = from(getTransactionsLogs(client, documents.map(_temp$20), {
47731
47734
  fromTransaction: transactionId,
47732
47735
  limit: 2
47733
47736
  })).pipe(map$1(_temp2$O), catchError$1(_temp3$p)), $[1] = client, $[2] = documents, $[3] = transactionId, $[4] = t1) : t1 = $[4], t0 = t1;
47734
47737
  }
47735
47738
  return useObservable(t0, null);
47736
47739
  };
47737
- function _temp$1$(t0) {
47740
+ function _temp$20(t0) {
47738
47741
  const {
47739
47742
  document: document2
47740
47743
  } = t0;
@@ -47841,7 +47844,7 @@ const ConfirmReleaseDialog = (t0) => {
47841
47844
  let t11;
47842
47845
  $[29] !== description || $[30] !== t || $[31] !== t10 ? (t11 = /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, children: /* @__PURE__ */ jsx(Translate, { t, i18nKey: description, values: t10 }) }), $[29] = description, $[30] = t, $[31] = t10, $[32] = t11) : t11 = $[32];
47843
47846
  let t12;
47844
- $[33] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t12 = () => setStageNewRevertRelease(_temp$1_), $[33] = t12) : t12 = $[33];
47847
+ $[33] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t12 = () => setStageNewRevertRelease(_temp$1$), $[33] = t12) : t12 = $[33];
47845
47848
  let t13;
47846
47849
  $[34] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t13 = {
47847
47850
  display: "block"
@@ -47915,7 +47918,7 @@ const ConfirmReleaseDialog = (t0) => {
47915
47918
  t10
47916
47919
  ] }), $[22] = t10, $[23] = t9, $[24] = t11) : t11 = $[24], t11;
47917
47920
  };
47918
- function _temp$1_(current) {
47921
+ function _temp$1$(current) {
47919
47922
  return !current;
47920
47923
  }
47921
47924
  const ReleaseScheduleButton = (t0) => {
@@ -47944,7 +47947,7 @@ const ReleaseScheduleButton = (t0) => {
47944
47947
  $[0] !== publishAt || $[1] !== utcToCurrentZoneDate ? (t2 = publishAt ? utcToCurrentZoneDate(publishAt) : void 0, $[0] = publishAt, $[1] = utcToCurrentZoneDate, $[2] = t2) : t2 = $[2];
47945
47948
  const timeZoneAdjustedPublishAt = t2;
47946
47949
  let t3;
47947
- $[3] !== documents ? (t3 = documents.some(_temp$1Z), $[3] = documents, $[4] = t3) : t3 = $[4];
47950
+ $[3] !== documents ? (t3 = documents.some(_temp$1_), $[3] = documents, $[4] = t3) : t3 = $[4];
47948
47951
  const isValidatingDocuments = t3;
47949
47952
  let t4;
47950
47953
  $[5] !== documents ? (t4 = documents.some(_temp2$N), $[5] = documents, $[6] = t4) : t4 = $[6];
@@ -48176,7 +48179,7 @@ const ReleaseScheduleButton = (t0) => {
48176
48179
  confirmScheduleDialog
48177
48180
  ] }), $[140] = confirmScheduleDialog, $[141] = t25, $[142] = t26) : t26 = $[142], t26;
48178
48181
  };
48179
- function _temp$1Z(t0) {
48182
+ function _temp$1_(t0) {
48180
48183
  const {
48181
48184
  validation: validation2
48182
48185
  } = t0;
@@ -48359,7 +48362,7 @@ function mapHooksToStates(states, {
48359
48362
  function useHookCollectionStates(t0) {
48360
48363
  const $ = c(12), {
48361
48364
  hooks
48362
- } = t0, [states] = useState(_temp$1Y);
48365
+ } = t0, [states] = useState(_temp$1Z);
48363
48366
  let t1;
48364
48367
  $[0] !== hooks || $[1] !== states ? (t1 = () => mapHooksToStates(states, {
48365
48368
  hooks
@@ -48401,7 +48404,7 @@ function _temp2$M(error) {
48401
48404
  if (error.name !== "AbortError")
48402
48405
  throw error;
48403
48406
  }
48404
- function _temp$1Y() {
48407
+ function _temp$1Z() {
48405
48408
  return /* @__PURE__ */ new Map();
48406
48409
  }
48407
48410
  function GetHookCollectionState(props2) {
@@ -48425,7 +48428,7 @@ function GetHookCollectionState(props2) {
48425
48428
  }), $[2] = children, $[3] = states, $[4] = t1) : t1 = $[4];
48426
48429
  const result = t1, [forceReset, setForceReset] = useState(0);
48427
48430
  let t2, t3;
48428
- $[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = () => () => setForceReset(_temp$1X), t3 = [], $[5] = t2, $[6] = t3) : (t2 = $[5], t3 = $[6]), useImperativeHandle(resetRef, t2, t3);
48431
+ $[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = () => () => setForceReset(_temp$1Y), t3 = [], $[5] = t2, $[6] = t3) : (t2 = $[5], t3 = $[6]), useImperativeHandle(resetRef, t2, t3);
48429
48432
  const t4 = `render-${forceReset}`;
48430
48433
  let t5;
48431
48434
  $[7] !== args || $[8] !== handleNext || $[9] !== hooks || $[10] !== t4 ? (t5 = /* @__PURE__ */ jsx(HookCollectionState, { hooks, args, handleNext }, t4), $[7] = args, $[8] = handleNext, $[9] = hooks, $[10] = t4, $[11] = t5) : t5 = $[11];
@@ -48435,7 +48438,7 @@ function GetHookCollectionState(props2) {
48435
48438
  result
48436
48439
  ] }), $[12] = result, $[13] = t5, $[14] = t6) : t6 = $[14], t6;
48437
48440
  }
48438
- function _temp$1X(n) {
48441
+ function _temp$1Y(n) {
48439
48442
  return n + 1;
48440
48443
  }
48441
48444
  const ReleaseActionsStateHandler = memo(function(t0) {
@@ -48819,7 +48822,7 @@ const toastActionComponents = {
48819
48822
  $[15] !== documents || $[16] !== duplicateRelease || $[17] !== guardWithReleaseLimitUpsell || $[18] !== release.metadata || $[19] !== t ? (t8 = async () => {
48820
48823
  const duplicateReleaseId = createReleaseId();
48821
48824
  return await guardWithReleaseLimitUpsell(async () => {
48822
- const releaseDocuments = documents?.map(_temp$1W), duplicatedMetadata = {
48825
+ const releaseDocuments = documents?.map(_temp$1X), duplicatedMetadata = {
48823
48826
  ...release.metadata,
48824
48827
  title: `${release.metadata.title} (${t("copy-suffix")})`
48825
48828
  };
@@ -48999,7 +49002,7 @@ const toastActionComponents = {
48999
49002
  confirmActionDialog
49000
49003
  ] }), $[130] = confirmActionDialog, $[131] = t20, $[132] = t32, $[133] = t33) : t33 = $[133], t33;
49001
49004
  };
49002
- function _temp$1W(doc) {
49005
+ function _temp$1X(doc) {
49003
49006
  return doc.document;
49004
49007
  }
49005
49008
  function StatusItem(props2) {
@@ -49040,7 +49043,7 @@ function ReleaseStatusItems(t0) {
49040
49043
  } = useTranslation(releasesLocaleNamespace);
49041
49044
  let t1;
49042
49045
  if ($[0] !== events2) {
49043
- const createEvent = events2.find(isCreateReleaseEvent), extraEvent = events2.find(_temp$1V);
49046
+ const createEvent = events2.find(isCreateReleaseEvent), extraEvent = events2.find(_temp$1W);
49044
49047
  t1 = [createEvent, extraEvent].filter(isNonNullable$3), $[0] = events2, $[1] = t1;
49045
49048
  } else
49046
49049
  t1 = $[1];
@@ -49066,7 +49069,7 @@ function ReleaseStatusItems(t0) {
49066
49069
  /* @__PURE__ */ jsx(RelativeTime, { time: event_0.timestamp, useTemporalPhrase: !0, minimal: !0 })
49067
49070
  ] }) }, event_0.id)) }), $[10] = footerEvents, $[11] = t, $[12] = t2) : t2 = $[12], t2;
49068
49071
  }
49069
- function _temp$1V(event) {
49072
+ function _temp$1W(event) {
49070
49073
  return isPublishReleaseEvent(event) || isArchiveReleaseEvent(event) || isUnarchiveReleaseEvent(event);
49071
49074
  }
49072
49075
  function ReleaseDashboardFooter(props2) {
@@ -49167,7 +49170,7 @@ function ReleaseDashboardHeader(props2) {
49167
49170
  const handleNavigateToReleasesList = t1;
49168
49171
  let t2;
49169
49172
  $[6] !== setInspector ? (t2 = () => {
49170
- setInspector(_temp$1U);
49173
+ setInspector(_temp$1V);
49171
49174
  }, $[6] = setInspector, $[7] = t2) : t2 = $[7];
49172
49175
  const handleActivityClick = t2;
49173
49176
  let t3;
@@ -49200,7 +49203,7 @@ function ReleaseDashboardHeader(props2) {
49200
49203
  t12
49201
49204
  ] }), $[31] = t12, $[32] = t9, $[33] = t13) : t13 = $[33], t13;
49202
49205
  }
49203
- function _temp$1U(prev) {
49206
+ function _temp$1V(prev) {
49204
49207
  return prev === "activity" ? void 0 : "activity";
49205
49208
  }
49206
49209
  const emptyCellStyle = {
@@ -50504,7 +50507,7 @@ function DocumentTypesPopoverContent() {
50504
50507
  return index;
50505
50508
  }
50506
50509
  }, $[4] = documentTypeItems, $[5] = t5) : t5 = $[5];
50507
- const getItemKey2 = t5, renderItem2 = _temp$1T;
50510
+ const getItemKey2 = t5, renderItem2 = _temp$1U;
50508
50511
  let t6;
50509
50512
  $[6] !== documentTypeItems ? (t6 = (index_0) => documentTypeItems[index_0].type !== "item", $[6] = documentTypeItems, $[7] = t6) : t6 = $[7];
50510
50513
  const getItemDisabled = t6;
@@ -50538,7 +50541,7 @@ function DocumentTypesPopoverContent() {
50538
50541
  t13
50539
50542
  ] }), $[33] = t12, $[34] = t13, $[35] = t9, $[36] = t14) : t14 = $[36], t14;
50540
50543
  }
50541
- function _temp$1T(item) {
50544
+ function _temp$1U(item) {
50542
50545
  return item.type === "divider" ? /* @__PURE__ */ jsx(Box, { paddingY: 1, children: /* @__PURE__ */ jsx(MenuDivider, {}) }) : item.type === "header" ? /* @__PURE__ */ jsx(Box, { margin: 2, padding: 1, children: /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, weight: "medium", children: item.title }) }) : item.type === "item" ? /* @__PURE__ */ jsx(DocumentTypeFilterItem, { paddingBottom: 1, selected: item.selected, type: item.item }) : null;
50543
50546
  }
50544
50547
  function ClearButton(t0) {
@@ -51204,7 +51207,7 @@ function useRecentSearchesStore() {
51204
51207
  let t5;
51205
51208
  return $[11] !== fieldDefinitions || $[12] !== filterDefinitions2 || $[13] !== operatorDefinitions2 || $[14] !== schema2 || $[15] !== setStoredSearch || $[16] !== storedSearch ? (t5 = {
51206
51209
  addSearch: (searchTerm, searchFilters) => {
51207
- const validStoredFilters = (searchFilters || []).map(_temp$1S).filter((filter_0) => validateFilter({
51210
+ const validStoredFilters = (searchFilters || []).map(_temp$1T).filter((filter_0) => validateFilter({
51208
51211
  fieldDefinitions,
51209
51212
  filter: filter_0,
51210
51213
  filterDefinitions: filterDefinitions2,
@@ -51279,7 +51282,7 @@ function useRecentSearchesStore() {
51279
51282
  function _temp2$L(s) {
51280
51283
  return s.name;
51281
51284
  }
51282
- function _temp$1S(filter2) {
51285
+ function _temp$1T(filter2) {
51283
51286
  return {
51284
51287
  fieldId: filter2.fieldId,
51285
51288
  filterName: filter2.filterName,
@@ -51340,12 +51343,12 @@ function Instructions() {
51340
51343
  } = useTranslation();
51341
51344
  let t0;
51342
51345
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
51343
- ControlsIcon: _temp$1R
51346
+ ControlsIcon: _temp$1S
51344
51347
  }, $[0] = t0) : t0 = $[0];
51345
51348
  let t1;
51346
51349
  return $[1] !== t ? (t1 = /* @__PURE__ */ jsx(Flex, { align: "center", direction: "column", gap: 4, paddingX: 4, paddingY: 5, children: /* @__PURE__ */ jsx(Inline, { space: 3, children: /* @__PURE__ */ jsx(Text$1, { muted: !0, children: /* @__PURE__ */ jsx(Translate, { t, i18nKey: "search.instructions", components: t0 }) }) }) }), $[1] = t, $[2] = t1) : t1 = $[2], t1;
51347
51350
  }
51348
- function _temp$1R() {
51351
+ function _temp$1S() {
51349
51352
  return /* @__PURE__ */ jsx(ControlsIcon, { style: {
51350
51353
  padding: "0 0.25rem"
51351
51354
  } }, 0);
@@ -51436,7 +51439,7 @@ function RecentSearchItem(t0) {
51436
51439
  let t6;
51437
51440
  $[15] !== availableCharacters || $[16] !== value.types ? (t6 = value.types.length > 0 && /* @__PURE__ */ jsx(SearchItemPillsBox, { children: /* @__PURE__ */ jsx(DocumentTypesPill, { availableCharacters, types: value.types }) }), $[15] = availableCharacters, $[16] = value.types, $[17] = t6) : t6 = $[17];
51438
51441
  let t7;
51439
- $[18] !== value.filters ? (t7 = value?.filters?.map(_temp$1Q), $[18] = value.filters, $[19] = t7) : t7 = $[19];
51442
+ $[18] !== value.filters ? (t7 = value?.filters?.map(_temp$1R), $[18] = value.filters, $[19] = t7) : t7 = $[19];
51440
51443
  let t8;
51441
51444
  $[20] !== t5 || $[21] !== t6 || $[22] !== t7 ? (t8 = /* @__PURE__ */ jsxs(Flex, { align: "stretch", flex: 1, gap: 2, justify: "flex-start", marginLeft: 3, wrap: "wrap", children: [
51442
51445
  t5,
@@ -51458,7 +51461,7 @@ function RecentSearchItem(t0) {
51458
51461
  let t13;
51459
51462
  return $[33] !== rest || $[34] !== t12 ? (t13 = /* @__PURE__ */ jsx(Box, { ...rest, children: t12 }), $[33] = rest, $[34] = t12, $[35] = t13) : t13 = $[35], t13;
51460
51463
  }
51461
- function _temp$1Q(filter2, i) {
51464
+ function _temp$1R(filter2, i) {
51462
51465
  return /* @__PURE__ */ jsx(FilterPill, { filter: filter2 }, i);
51463
51466
  }
51464
51467
  const VIRTUAL_LIST_RECENT_SEARCH_ITEM_HEIGHT = 36, MAX_COMBINED_TYPE_COUNT_SMALL = 20, MAX_COMBINED_TYPE_COUNT_LARGE = 40, RecentSearchesBox = styled(Card)`
@@ -51765,7 +51768,7 @@ function SortMenu() {
51765
51768
  $[25] !== T0 || $[26] !== t5 || $[27] !== t6 || $[28] !== t7 ? (t13 = /* @__PURE__ */ jsx(T0, { mode: t5, icon: t6, text: t7 }), $[25] = T0, $[26] = t5, $[27] = t6, $[28] = t7, $[29] = t13) : t13 = $[29];
51766
51769
  const t14 = menuButtonId || "";
51767
51770
  let t15;
51768
- $[30] !== menuOrderings ? (t15 = /* @__PURE__ */ jsx(Menu, { children: menuOrderings.map(_temp$1P) }), $[30] = menuOrderings, $[31] = t15) : t15 = $[31];
51771
+ $[30] !== menuOrderings ? (t15 = /* @__PURE__ */ jsx(Menu, { children: menuOrderings.map(_temp$1Q) }), $[30] = menuOrderings, $[31] = t15) : t15 = $[31];
51769
51772
  let t16;
51770
51773
  $[32] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t16 = {
51771
51774
  portal: !0,
@@ -51778,7 +51781,7 @@ function SortMenu() {
51778
51781
  let t19;
51779
51782
  return $[44] !== T3 || $[45] !== t11 || $[46] !== t18 ? (t19 = /* @__PURE__ */ jsx(T3, { borderBottom: t11, children: t18 }), $[44] = T3, $[45] = t11, $[46] = t18, $[47] = t19) : t19 = $[47], t19;
51780
51783
  }
51781
- function _temp$1P(item_0, index) {
51784
+ function _temp$1Q(item_0, index) {
51782
51785
  return isSearchDivider(item_0) ? /* @__PURE__ */ jsx(MenuDivider, {}, index) : /* @__PURE__ */ jsx(CustomMenuItem$1, { ordering: item_0 }, index);
51783
51786
  }
51784
51787
  const DebugScoreCard = styled(Card)`
@@ -51797,7 +51800,7 @@ function DebugOverlay(t0) {
51797
51800
  score <= 0.1 ? tone = "critical" : score >= 0.5 && (tone = "primary");
51798
51801
  let T0, T1, t1, t2;
51799
51802
  if ($[0] !== data.stories) {
51800
- const matchingStories = data.stories.filter(_temp$1O);
51803
+ const matchingStories = data.stories.filter(_temp$1P);
51801
51804
  T1 = Tooltip, T0 = Stack, t1 = 2, t2 = matchingStories.length ? /* @__PURE__ */ jsx(Fragment$1, { children: matchingStories.map(_temp2$K) }) : /* @__PURE__ */ jsx(Code, { size: 0, children: "No matches" }), $[0] = data.stories, $[1] = T0, $[2] = T1, $[3] = t1, $[4] = t2;
51802
51805
  } else
51803
51806
  T0 = $[1], T1 = $[2], t1 = $[3], t2 = $[4];
@@ -51819,7 +51822,7 @@ function _temp2$K(story_0) {
51819
51822
  /* @__PURE__ */ jsx(Code, { size: 0, children: story_0.why })
51820
51823
  ] }, story_0.path);
51821
51824
  }
51822
- function _temp$1O(story) {
51825
+ function _temp$1P(story) {
51823
51826
  return story.score > 0;
51824
51827
  }
51825
51828
  const SearchResultItemPreviewBox = styled(Box)`
@@ -52178,7 +52181,7 @@ function useSearch(t0) {
52178
52181
  }), $[0] = client, $[1] = maxFieldDepth, $[2] = schema2, $[3] = strategy, $[4] = t1) : t1 = $[4];
52179
52182
  const search2 = t1;
52180
52183
  let t2;
52181
- $[5] !== allowEmptyQueries || $[6] !== onComplete || $[7] !== onError || $[8] !== onStart || $[9] !== search2 ? (t2 = (inputValue$) => inputValue$.pipe(filter(nonNullable), map(sanitizeRequest), distinctUntilChanged(isEqual$2), debounce$1(_temp$1N), tap(onStart), switchMap((request_0) => concat(of({
52184
+ $[5] !== allowEmptyQueries || $[6] !== onComplete || $[7] !== onError || $[8] !== onStart || $[9] !== search2 ? (t2 = (inputValue$) => inputValue$.pipe(filter(nonNullable), map(sanitizeRequest), distinctUntilChanged(isEqual$2), debounce$1(_temp$1O), tap(onStart), switchMap((request_0) => concat(of({
52182
52185
  ...INITIAL_SEARCH_STATE,
52183
52186
  loading: !0,
52184
52187
  options: request_0.options,
@@ -52223,7 +52226,7 @@ function _temp2$J(prevState, nextState) {
52223
52226
  ...nextState
52224
52227
  };
52225
52228
  }
52226
- function _temp$1N(request) {
52229
+ function _temp$1O(request) {
52227
52230
  return timer(request?.debounceTime || DEFAULT_DEBOUNCE_TIME);
52228
52231
  }
52229
52232
  function isRecentSearchTerms(terms) {
@@ -52863,7 +52866,7 @@ function ReleaseActionBadges(t0) {
52863
52866
  t
52864
52867
  } = useTranslation(releasesLocaleNamespace);
52865
52868
  let t2;
52866
- $[0] !== documents ? (t2 = documents.reduce(_temp$1M, {
52869
+ $[0] !== documents ? (t2 = documents.reduce(_temp$1N, {
52867
52870
  added: 0,
52868
52871
  changed: 0,
52869
52872
  unpublished: 0
@@ -52900,7 +52903,7 @@ function ReleaseActionBadges(t0) {
52900
52903
  t4
52901
52904
  ] }), $[8] = t3, $[9] = t4, $[10] = t5) : t5 = $[10], t5;
52902
52905
  }
52903
- function _temp$1M(acc, doc) {
52906
+ function _temp$1N(acc, doc) {
52904
52907
  const actionType = getDocumentActionType(doc);
52905
52908
  return actionType && (acc[actionType] = acc[actionType] + 1), acc;
52906
52909
  }
@@ -53073,7 +53076,7 @@ function useReleaseHistory(releaseDocumentId, releaseId, documentRevision) {
53073
53076
  });
53074
53077
  })().catch((error) => {
53075
53078
  console.error("Failed to fetch or parse document history:", error), cancelledRef.current || setHistory([]);
53076
- }).finally(_temp$1L);
53079
+ }).finally(_temp$1M);
53077
53080
  }, $[3] = client, $[4] = documentRevision, $[5] = releaseDocumentId, $[6] = versionId, $[7] = t1) : t1 = $[7];
53078
53081
  const fetchAndParse = t1;
53079
53082
  let t2, t3;
@@ -53117,7 +53120,7 @@ function useReleaseHistory(releaseDocumentId, releaseId, documentRevision) {
53117
53120
  function _temp2$I(mutation) {
53118
53121
  return "create" in mutation;
53119
53122
  }
53120
- function _temp$1L() {
53123
+ function _temp$1M() {
53121
53124
  releaseHistorySlot();
53122
53125
  }
53123
53126
  const MemoReleaseDocumentPreview = memo(function(t0) {
@@ -53296,7 +53299,7 @@ function ReleaseSummary(props2) {
53296
53299
  const documentTableColumnDefs = t4;
53297
53300
  let t5;
53298
53301
  $[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t5 = () => setAddDocumentDialog(!0), $[10] = t5) : t5 = $[10];
53299
- const handleAddDocumentClick = t5, filterRows = _temp$1K;
53302
+ const handleAddDocumentClick = t5, filterRows = _temp$1L;
53300
53303
  let t6;
53301
53304
  $[11] !== createVersion || $[12] !== releaseId || $[13] !== t || $[14] !== telemetry || $[15] !== toast ? (t6 = async (documentToAdd) => {
53302
53305
  if (setAddDocumentDialog(!1), !documentToAdd)
@@ -53404,7 +53407,7 @@ function _temp2$H(t0) {
53404
53407
  } = t0;
53405
53408
  return document_3._id;
53406
53409
  }
53407
- function _temp$1K(data, searchTerm) {
53410
+ function _temp$1L(data, searchTerm) {
53408
53411
  return data.filter((t0) => {
53409
53412
  const {
53410
53413
  document: document2
@@ -53745,7 +53748,7 @@ function CalendarMonth$2(props2) {
53745
53748
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = {
53746
53749
  gridGap: "1px",
53747
53750
  gridTemplateColumns: "repeat(7, 1fr)"
53748
- }, t2 = DEFAULT_WEEK_DAY_NAMES.map(_temp$1J), $[0] = t1, $[1] = t2) : (t1 = $[0], t2 = $[1]);
53751
+ }, t2 = DEFAULT_WEEK_DAY_NAMES.map(_temp$1K), $[0] = t1, $[1] = t2) : (t1 = $[0], t2 = $[1]);
53749
53752
  let t3;
53750
53753
  if ($[2] !== CalendarDay2 || $[3] !== date || $[4] !== disabled || $[5] !== getCurrentZoneDate || $[6] !== props2.focused || $[7] !== props2.onSelect || $[8] !== props2.selected || $[9] !== weeksOfMonth) {
53751
53754
  let t42;
@@ -53763,7 +53766,7 @@ function CalendarMonth$2(props2) {
53763
53766
  let t5;
53764
53767
  return $[21] !== t0 || $[22] !== t4 ? (t5 = /* @__PURE__ */ jsx(Box, { "aria-hidden": t0, "data-ui": "CalendarMonth", children: t4 }), $[21] = t0, $[22] = t4, $[23] = t5) : t5 = $[23], t5;
53765
53768
  }
53766
- function _temp$1J(weekday) {
53769
+ function _temp$1K(weekday) {
53767
53770
  return /* @__PURE__ */ jsx(Card, { paddingY: 3, children: /* @__PURE__ */ jsx(Label, { size: 1, style: {
53768
53771
  textAlign: "center"
53769
53772
  }, children: weekday.slice(0, 1) }) }, weekday);
@@ -54021,7 +54024,7 @@ function CreateReleaseDialog(props2) {
54021
54024
  const releaseValue = createReleaseMetadata(release);
54022
54025
  await createRelease(releaseValue), onCancel(), telemetry.log(CreatedRelease, {
54023
54026
  origin
54024
- }), await new Promise(_temp$1I), setPerspective(getReleaseIdFromReleaseDocumentId(release._id)), onSubmit(getReleaseIdFromReleaseDocumentId(release._id));
54027
+ }), await new Promise(_temp$1J), setPerspective(getReleaseIdFromReleaseDocumentId(release._id)), onSubmit(getReleaseIdFromReleaseDocumentId(release._id));
54025
54028
  } catch (t22) {
54026
54029
  const err = t22;
54027
54030
  isReleaseLimitError(err) ? (onCancel(), clearReleaseDataFromStorage()) : (console.error(err), toast.push({
@@ -54062,7 +54065,7 @@ function CreateReleaseDialog(props2) {
54062
54065
  let t10;
54063
54066
  return $[33] !== dialogTitle || $[34] !== handleOnClose || $[35] !== onCancel || $[36] !== t9 ? (t10 = /* @__PURE__ */ jsx(Dialog, { onClickOutside: onCancel, header: dialogTitle, id: "create-release-dialog", onClose: handleOnClose, width: 1, padding: !1, children: t9 }), $[33] = dialogTitle, $[34] = handleOnClose, $[35] = onCancel, $[36] = t9, $[37] = t10) : t10 = $[37], t10;
54064
54067
  }
54065
- function _temp$1I(resolve) {
54068
+ function _temp$1J(resolve) {
54066
54069
  return setTimeout(resolve, 1e3);
54067
54070
  }
54068
54071
  const useReleasesMetadata = (releaseIds) => {
@@ -54105,7 +54108,7 @@ function CalendarPopover(t0) {
54105
54108
  let t3;
54106
54109
  $[2] !== t ? (t3 = t("overview.calendar.tooltip"), $[2] = t, $[3] = t3) : t3 = $[3];
54107
54110
  let t4;
54108
- $[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t4 = () => setIsCalendarOpen(_temp$1H), $[4] = t4) : t4 = $[4];
54111
+ $[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t4 = () => setIsCalendarOpen(_temp$1I), $[4] = t4) : t4 = $[4];
54109
54112
  let t5;
54110
54113
  $[5] !== isCalendarOpen ? (t5 = /* @__PURE__ */ jsx(Button$1, { name: "calendar", "data-as": "a", icon: CalendarIcon, mode: "bleed", padding: 2, radius: "full", selected: isCalendarOpen, onClick: t4, ref: buttonRef, space: 2 }), $[5] = isCalendarOpen, $[6] = t5) : t5 = $[6];
54111
54114
  let t6;
@@ -54113,7 +54116,7 @@ function CalendarPopover(t0) {
54113
54116
  let t7;
54114
54117
  return $[10] !== content || $[11] !== isCalendarOpen || $[12] !== t6 ? (t7 = /* @__PURE__ */ jsx(Popover, { content, placement: "bottom", open: isCalendarOpen, ref: popoverRef, children: t6 }), $[10] = content, $[11] = isCalendarOpen, $[12] = t6, $[13] = t7) : t7 = $[13], t7;
54115
54118
  }
54116
- function _temp$1H(prev) {
54119
+ function _temp$1I(prev) {
54117
54120
  return !prev;
54118
54121
  }
54119
54122
  const getPickerView = ({
@@ -54247,7 +54250,7 @@ const ScheduledDraftDocumentPreview = (t0) => {
54247
54250
  }
54248
54251
  let T0, T1, T2, t1, t10, t11, t12, t2, t3, t4, t5, t6, t7, t8, t9;
54249
54252
  if ($[3] !== cellProps || $[4] !== firstDocument._id || $[5] !== firstDocument._rev || $[6] !== firstDocument._type || $[7] !== firstDocumentValidation || $[8] !== release._id || $[9] !== release.state || $[10] !== t) {
54250
- const validationErrorCount = firstDocumentValidation?.filter(_temp$1G).length || 0;
54253
+ const validationErrorCount = firstDocumentValidation?.filter(_temp$1H).length || 0;
54251
54254
  T2 = Box, t7 = cellProps, t8 = 1, t9 = 1, t10 = 2, t11 = 2, t12 = "border", T1 = Card, t5 = validationErrorCount ? "critical" : "inherit", t6 = 2, T0 = Flex, t1 = "center", t2 = 2, $[26] !== firstDocument._id || $[27] !== firstDocument._rev || $[28] !== firstDocument._type || $[29] !== release._id || $[30] !== release.state ? (t3 = /* @__PURE__ */ jsx(Box, { flex: 1, children: /* @__PURE__ */ jsx(ReleaseDocumentPreview, { documentId: firstDocument._id, documentTypeName: firstDocument._type, releaseId: release._id, releaseState: release.state, isCardinalityOneRelease: !0, documentRevision: firstDocument._rev, layout: "default" }) }), $[26] = firstDocument._id, $[27] = firstDocument._rev, $[28] = firstDocument._type, $[29] = release._id, $[30] = release.state, $[31] = t3) : t3 = $[31], t4 = validationErrorCount > 0 && /* @__PURE__ */ jsx(Box, { paddingRight: 3, children: /* @__PURE__ */ jsx(Tooltip, { portal: !0, placement: "bottom-end", content: /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, children: /* @__PURE__ */ jsxs(Flex, { align: "center", gap: 3, padding: 1, children: [
54252
54255
  /* @__PURE__ */ jsx(ToneIcon, { icon: ErrorOutlineIcon, tone: "critical" }),
54253
54256
  t("document-validation.error", {
@@ -54266,7 +54269,7 @@ const ScheduledDraftDocumentPreview = (t0) => {
54266
54269
  let t15;
54267
54270
  return $[43] !== T2 || $[44] !== t10 || $[45] !== t11 || $[46] !== t12 || $[47] !== t14 || $[48] !== t7 || $[49] !== t8 || $[50] !== t9 ? (t15 = /* @__PURE__ */ jsx(T2, { ...t7, flex: t8, padding: t9, paddingLeft: t10, paddingRight: t11, sizing: t12, children: t14 }), $[43] = T2, $[44] = t10, $[45] = t11, $[46] = t12, $[47] = t14, $[48] = t7, $[49] = t8, $[50] = t9, $[51] = t15) : t15 = $[51], t15;
54268
54271
  };
54269
- function _temp$1G(validation2) {
54272
+ function _temp$1H(validation2) {
54270
54273
  return validation2.level === "error";
54271
54274
  }
54272
54275
  function useReleaseCreator(releaseDocumentId, t0) {
@@ -54352,7 +54355,7 @@ function useScheduleActiveDrafts() {
54352
54355
  const $ = c(4), client = useClient(RELEASES_STUDIO_CLIENT_OPTIONS);
54353
54356
  let t0;
54354
54357
  $[0] !== client ? (t0 = async (releases2) => {
54355
- const scheduleActions = releases2.flatMap(_temp$1F);
54358
+ const scheduleActions = releases2.flatMap(_temp$1G);
54356
54359
  await client.action(scheduleActions);
54357
54360
  }, $[0] = client, $[1] = t0) : t0 = $[1];
54358
54361
  const scheduleActiveDrafts = t0;
@@ -54361,7 +54364,7 @@ function useScheduleActiveDrafts() {
54361
54364
  scheduleActiveDrafts
54362
54365
  }, $[2] = scheduleActiveDrafts, $[3] = t1) : t1 = $[3], t1;
54363
54366
  }
54364
- function _temp$1F(release) {
54367
+ function _temp$1G(release) {
54365
54368
  return release.metadata.intendedPublishAt ? [{
54366
54369
  actionType: "sanity.action.release.schedule",
54367
54370
  releaseId: getReleaseIdFromReleaseDocumentId(release._id),
@@ -54462,7 +54465,7 @@ function ConfirmActiveScheduledDraftsBanner(t0) {
54462
54465
  t
54463
54466
  } = useTranslation(releasesLocaleNamespace), [isDialogOpen, setIsDialogOpen] = useState(!1);
54464
54467
  let t1;
54465
- $[0] !== releases2 ? (t1 = releases2.filter(_temp$1E), $[0] = releases2, $[1] = t1) : t1 = $[1];
54468
+ $[0] !== releases2 ? (t1 = releases2.filter(_temp$1F), $[0] = releases2, $[1] = t1) : t1 = $[1];
54466
54469
  const activeScheduledDrafts = t1;
54467
54470
  let t2;
54468
54471
  $[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = () => {
@@ -54502,7 +54505,7 @@ function ConfirmActiveScheduledDraftsBanner(t0) {
54502
54505
  t10
54503
54506
  ] }), $[20] = t10, $[21] = t9, $[22] = t11) : t11 = $[22], t11;
54504
54507
  }
54505
- function _temp$1E(release) {
54508
+ function _temp$1F(release) {
54506
54509
  return release.state === "active" && isCardinalityOneRelease(release);
54507
54510
  }
54508
54511
  const DraftsDisabledBanner = (t0) => {
@@ -55656,7 +55659,7 @@ const ScheduledDraftMenuButtonWrapper = (t0) => {
55656
55659
  const displayedMenuItems = t5, canPerformActions = !!scheduledDraftDocument;
55657
55660
  let t6;
55658
55661
  $[17] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t6 = () => {
55659
- setOpenPopover(_temp$1D);
55662
+ setOpenPopover(_temp$1E);
55660
55663
  }, $[17] = t6) : t6 = $[17];
55661
55664
  const handleOnButtonClick = t6;
55662
55665
  let t7, t8;
@@ -55685,7 +55688,7 @@ const ScheduledDraftMenuButtonWrapper = (t0) => {
55685
55688
  dialogs
55686
55689
  ] }), $[38] = dialogs, $[39] = t17, $[40] = t18) : t18 = $[40], t18;
55687
55690
  };
55688
- function _temp$1D(prev) {
55691
+ function _temp$1E(prev) {
55689
55692
  return !prev;
55690
55693
  }
55691
55694
  const singleDocReleaseNamespace = "singleDocRelease", singleDocReleaseUsEnglishLocaleBundle = {
@@ -55971,7 +55974,7 @@ function ReleasesOverview() {
55971
55974
  $[11] !== allArchivedReleases || $[12] !== cardinalityView ? (t4 = allArchivedReleases.filter(shouldShowReleaseInView(cardinalityView)), $[11] = allArchivedReleases, $[12] = cardinalityView, $[13] = t4) : t4 = $[13];
55972
55975
  const archivedReleases = t4;
55973
55976
  let t5;
55974
- $[14] !== releases2 ? (t5 = releases2.map(_temp$1C), $[14] = releases2, $[15] = t5) : t5 = $[15];
55977
+ $[14] !== releases2 ? (t5 = releases2.map(_temp$1D), $[14] = releases2, $[15] = t5) : t5 = $[15];
55975
55978
  const releaseIds = t5, {
55976
55979
  data: releasesMetadata,
55977
55980
  loading: loadingReleasesMetadata
@@ -56302,7 +56305,7 @@ function _temp3$m(release_3) {
56302
56305
  function _temp2$F(release_0) {
56303
56306
  return release_0.state === "active" && isCardinalityOneRelease(release_0);
56304
56307
  }
56305
- function _temp$1C(release) {
56308
+ function _temp$1D(release) {
56306
56309
  return release._id;
56307
56310
  }
56308
56311
  function ReleasesTool() {
@@ -56568,9 +56571,9 @@ const SINGLE_DOC_RELEASE_NAME = "sanity/singleDocRelease", RELEASES_SCHEDULED_DR
56568
56571
  function useReleasesToolAvailable() {
56569
56572
  const $ = c(2), workspace = useWorkspace();
56570
56573
  let t0;
56571
- return $[0] !== workspace.tools ? (t0 = workspace.tools.some(_temp$1B), $[0] = workspace.tools, $[1] = t0) : t0 = $[1], t0;
56574
+ return $[0] !== workspace.tools ? (t0 = workspace.tools.some(_temp$1C), $[0] = workspace.tools, $[1] = t0) : t0 = $[1], t0;
56572
56575
  }
56573
- function _temp$1B(t0) {
56576
+ function _temp$1C(t0) {
56574
56577
  const {
56575
56578
  name
56576
56579
  } = t0;
@@ -56790,7 +56793,7 @@ const useHasCopyToDraftOption = (documentType, fromRelease) => {
56790
56793
  t
56791
56794
  } = useTranslation(), hasCopyToDraftOption = useHasCopyToDraftOption(documentType, fromRelease), isCopyToReleaseDisabled = disabled || !hasCreatePermission || isGoingToUnpublish2;
56792
56795
  let t1;
56793
- $[0] !== releases2 ? (t1 = releases2.filter(_temp$1A), $[0] = releases2, $[1] = t1) : t1 = $[1];
56796
+ $[0] !== releases2 ? (t1 = releases2.filter(_temp$1B), $[0] = releases2, $[1] = t1) : t1 = $[1];
56794
56797
  const copyToReleaseOptions = t1, showCopyToReleaseMenuItem = copyToReleaseOptions.length > 0 || hasCopyToDraftOption;
56795
56798
  let t2;
56796
56799
  $[2] !== disabled || $[3] !== fromRelease || $[4] !== isVersion || $[5] !== t ? (t2 = isVersion && /* @__PURE__ */ jsx(IntentLink, { intent: RELEASES_INTENT, params: {
@@ -56818,7 +56821,7 @@ const useHasCopyToDraftOption = (documentType, fromRelease) => {
56818
56821
  t6
56819
56822
  ] }), $[32] = t2, $[33] = t3, $[34] = t4, $[35] = t5, $[36] = t6, $[37] = t7) : t7 = $[37], t7;
56820
56823
  });
56821
- function _temp$1A(r) {
56824
+ function _temp$1B(r) {
56822
56825
  return !isReleaseScheduledOrScheduling(r);
56823
56826
  }
56824
56827
  const ScheduledDraftContextMenu = memo(function(props2) {
@@ -56839,7 +56842,7 @@ const ScheduledDraftContextMenu = memo(function(props2) {
56839
56842
  t
56840
56843
  } = useTranslation(), hasCopyToDraftOption = useHasCopyToDraftOption(documentType, fromRelease), isCopyToReleaseDisabled = disabled || !hasCreatePermission || isGoingToUnpublish2;
56841
56844
  let t1;
56842
- $[0] !== releases2 ? (t1 = releases2.filter(_temp$1z), $[0] = releases2, $[1] = t1) : t1 = $[1];
56845
+ $[0] !== releases2 ? (t1 = releases2.filter(_temp$1A), $[0] = releases2, $[1] = t1) : t1 = $[1];
56843
56846
  const copyToReleaseOptions = t1, showCopyToReleaseMenuItem = copyToReleaseOptions.length > 0 || hasCopyToDraftOption, {
56844
56847
  actions
56845
56848
  } = scheduledDraftMenuActions;
@@ -56878,7 +56881,7 @@ const ScheduledDraftContextMenu = memo(function(props2) {
56878
56881
  t10
56879
56882
  ] }), $[27] = t10, $[28] = t2, $[29] = t3, $[30] = t7, $[31] = t9, $[32] = t11) : t11 = $[32], t11;
56880
56883
  });
56881
- function _temp$1z(r) {
56884
+ function _temp$1A(r) {
56882
56885
  return !isReleaseScheduledOrScheduling(r);
56883
56886
  }
56884
56887
  const VersionContextMenu = memo(function(props2) {
@@ -57036,7 +57039,7 @@ function CopyToNewReleaseDialog(props2) {
57036
57039
  let t7;
57037
57040
  $[16] !== clearReleaseDataFromStorage || $[17] !== createRelease || $[18] !== createReleaseMetadata || $[19] !== handleAddVersion || $[20] !== onClose || $[21] !== release || $[22] !== releasePromise || $[23] !== setRerenderDialog || $[24] !== t || $[25] !== telemetry || $[26] !== toast ? (t7 = async () => {
57038
57041
  if (getIsScheduledDateInPast(release)) {
57039
- setRerenderDialog(_temp$1y);
57042
+ setRerenderDialog(_temp$1z);
57040
57043
  return;
57041
57044
  }
57042
57045
  if (setIsSubmitting(!0), !await releasePromise) {
@@ -57127,7 +57130,7 @@ function CopyToNewReleaseDialog(props2) {
57127
57130
  t25
57128
57131
  ] }), $[73] = handleOnClose, $[74] = onClose, $[75] = t16, $[76] = t25, $[77] = t9, $[78] = t26) : t26 = $[78], t26;
57129
57132
  }
57130
- function _temp$1y(cur) {
57133
+ function _temp$1z(cur) {
57131
57134
  return cur + 1;
57132
57135
  }
57133
57136
  const ChipButtonContainer = styled.span`
@@ -57338,7 +57341,7 @@ function DocumentPreviewPresence(props2) {
57338
57341
  data: releases2
57339
57342
  } = useActiveReleases();
57340
57343
  let t0;
57341
- $[0] !== presence ? (t0 = Array.from(new Set(presence.map(_temp$1x))), $[0] = presence, $[1] = t0) : t0 = $[1];
57344
+ $[0] !== presence ? (t0 = Array.from(new Set(presence.map(_temp$1y))), $[0] = presence, $[1] = t0) : t0 = $[1];
57342
57345
  let t1;
57343
57346
  $[2] !== presence || $[3] !== t0 ? (t1 = t0.map((id2) => presence.find((a_0) => a_0.user.id === id2)).filter(isNonNullable$3), $[2] = presence, $[3] = t0, $[4] = t1) : t1 = $[4];
57344
57347
  const uniquePresence = t1;
@@ -57378,7 +57381,7 @@ function DocumentPreviewPresence(props2) {
57378
57381
  function _temp2$E(item) {
57379
57382
  return /* @__PURE__ */ jsx(UserAvatar, { size: 0, user: item.user }, item.user.id);
57380
57383
  }
57381
- function _temp$1x(a) {
57384
+ function _temp$1y(a) {
57382
57385
  return a.user.id;
57383
57386
  }
57384
57387
  const EMPTY_ARRAY$h = [];
@@ -57608,7 +57611,7 @@ function useFormState(t0) {
57608
57611
  perspective,
57609
57612
  hasUpstreamVersion,
57610
57613
  displayInlineChanges
57611
- } = t0, currentUser = useCurrentUser(), [prepareHiddenState] = useState(_temp$1w), [prepareReadOnlyState] = useState(_temp2$D), [prepareFormState] = useState(_temp3$l), [reconcileFieldGroupState] = useState(_temp4$9);
57614
+ } = t0, currentUser = useCurrentUser(), [prepareHiddenState] = useState(_temp$1x), [prepareReadOnlyState] = useState(_temp2$D), [prepareFormState] = useState(_temp3$l), [reconcileFieldGroupState] = useState(_temp4$9);
57612
57615
  let t1;
57613
57616
  $[0] !== fieldGroupState || $[1] !== reconcileFieldGroupState ? (t1 = reconcileFieldGroupState(fieldGroupState), $[0] = fieldGroupState, $[1] = reconcileFieldGroupState, $[2] = t1) : t1 = $[2];
57614
57617
  const reconciledFieldGroupState = t1, [reconcileCollapsedPaths] = useState(_temp5$6);
@@ -57690,7 +57693,7 @@ function _temp2$D() {
57690
57693
  property: "readOnly"
57691
57694
  });
57692
57695
  }
57693
- function _temp$1w() {
57696
+ function _temp$1x() {
57694
57697
  return createCallbackResolver({
57695
57698
  property: "hidden"
57696
57699
  });
@@ -57786,7 +57789,7 @@ const INITIAL$1 = "connecting";
57786
57789
  function useConnectionState(publishedDocId, docTypeName, version2) {
57787
57790
  const $ = c(5), documentStore = useDocumentStore();
57788
57791
  let t0;
57789
- return $[0] !== docTypeName || $[1] !== documentStore.pair || $[2] !== publishedDocId || $[3] !== version2 ? (t0 = documentStore.pair.documentEvents(publishedDocId, docTypeName, version2).pipe(map(_temp$1v), map(_temp2$C), switchMap(_temp3$k), startWith(INITIAL$1), distinctUntilChanged()), $[0] = docTypeName, $[1] = documentStore.pair, $[2] = publishedDocId, $[3] = version2, $[4] = t0) : t0 = $[4], useObservable(t0, INITIAL$1);
57792
+ return $[0] !== docTypeName || $[1] !== documentStore.pair || $[2] !== publishedDocId || $[3] !== version2 ? (t0 = documentStore.pair.documentEvents(publishedDocId, docTypeName, version2).pipe(map(_temp$1w), map(_temp2$C), switchMap(_temp3$k), startWith(INITIAL$1), distinctUntilChanged()), $[0] = docTypeName, $[1] = documentStore.pair, $[2] = publishedDocId, $[3] = version2, $[4] = t0) : t0 = $[4], useObservable(t0, INITIAL$1);
57790
57793
  }
57791
57794
  function _temp3$k(isConnected) {
57792
57795
  return isConnected ? of("connected") : timer(200).pipe(mapTo("reconnecting"));
@@ -57794,7 +57797,7 @@ function _temp3$k(isConnected) {
57794
57797
  function _temp2$C(eventType) {
57795
57798
  return eventType !== "reconnect";
57796
57799
  }
57797
- function _temp$1v(ev) {
57800
+ function _temp$1w(ev) {
57798
57801
  return ev.type;
57799
57802
  }
57800
57803
  function useFilteredReleases(t0) {
@@ -57830,7 +57833,7 @@ function useFilteredReleases(t0) {
57830
57833
  break bb0;
57831
57834
  }
57832
57835
  if ($[13] !== archivedReleases || $[14] !== displayed || $[15] !== documentVersions || $[16] !== historyVersion || $[17] !== isCreatingDocument || $[18] !== releases2 || $[19] !== selectedReleaseId || $[20] !== strict) {
57833
- const releasesIds = documentVersions.map(_temp$1u);
57836
+ const releasesIds = documentVersions.map(_temp$1v);
57834
57837
  if (activeReleases = releases2.reduce((acc, release) => {
57835
57838
  const versionDocExists = releasesIds.includes(getReleaseIdFromReleaseDocumentId(release._id)), releaseId = getReleaseIdFromReleaseDocumentId(release._id);
57836
57839
  return isCreatingDocument && releaseId === getVersionFromId(displayed._id || "") && releaseId === selectedReleaseId ? acc.inCreation = release : versionDocExists ? strict ? (getDocumentIsInPerspective(displayed?._id ?? "", getReleaseIdFromReleaseDocumentId(release._id)) || release.metadata.releaseType === "scheduled") && acc.currentReleases.push(release) : acc.currentReleases.push(release) : acc.notCurrentReleases.push(release), acc;
@@ -57852,7 +57855,7 @@ function useFilteredReleases(t0) {
57852
57855
  activeReleases = $[11], t3 = $[12];
57853
57856
  return t3 !== /* @__PURE__ */ Symbol.for("react.early_return_sentinel") ? t3 : activeReleases;
57854
57857
  }
57855
- function _temp$1u(id2) {
57858
+ function _temp$1v(id2) {
57856
57859
  return getVersionFromId(id2);
57857
57860
  }
57858
57861
  function useDocumentIdStack(t0) {
@@ -57884,7 +57887,7 @@ function useDocumentIdStack(t0) {
57884
57887
  let t72;
57885
57888
  $[13] !== editState2 ? (t72 = (release) => editState2?.id && getVersionId(editState2.id, getReleaseIdFromReleaseDocumentId(release._id)), $[13] = editState2, $[14] = t72) : t72 = $[14];
57886
57889
  const releaseStack = filteredReleases.currentReleases.map(t72);
57887
- t6 = systemStack.concat(releaseStack).filter(_temp$1t), $[8] = editState2, $[9] = filteredReleases.currentReleases, $[10] = shouldIncludeDraft, $[11] = t5, $[12] = t6;
57890
+ t6 = systemStack.concat(releaseStack).filter(_temp$1u), $[8] = editState2, $[9] = filteredReleases.currentReleases, $[10] = shouldIncludeDraft, $[11] = t5, $[12] = t6;
57888
57891
  } else
57889
57892
  t6 = $[12];
57890
57893
  const stack = t6;
@@ -57899,7 +57902,7 @@ function useDocumentIdStack(t0) {
57899
57902
  stack
57900
57903
  }, $[17] = nextId, $[18] = position, $[19] = previousId, $[20] = stack, $[21] = t8) : t8 = $[21], t8;
57901
57904
  }
57902
- function _temp$1t(id2) {
57905
+ function _temp$1u(id2) {
57903
57906
  return typeof id2 == "string";
57904
57907
  }
57905
57908
  function useActiveWorkspace() {
@@ -58056,7 +58059,7 @@ function useEditState(publishedDocId, docTypeName, t0, version2) {
58056
58059
  let t22;
58057
58060
  if ($[0] !== docTypeName || $[1] !== documentStore.pair || $[2] !== publishedDocId || $[3] !== version2) {
58058
58061
  const base = documentStore.pair.editState(publishedDocId, docTypeName, version2).pipe(share$1());
58059
- t22 = merge(base.pipe(take(1)), base.pipe(skip$1(1), debounce$2(_temp$1s))), $[0] = docTypeName, $[1] = documentStore.pair, $[2] = publishedDocId, $[3] = version2, $[4] = t22;
58062
+ t22 = merge(base.pipe(take(1)), base.pipe(skip$1(1), debounce$2(_temp$1t))), $[0] = docTypeName, $[1] = documentStore.pair, $[2] = publishedDocId, $[3] = version2, $[4] = t22;
58060
58063
  } else
58061
58064
  t22 = $[4];
58062
58065
  t1 = t22;
@@ -58067,7 +58070,7 @@ function useEditState(publishedDocId, docTypeName, t0, version2) {
58067
58070
  }
58068
58071
  return useObservable(t1);
58069
58072
  }
58070
- function _temp$1s() {
58073
+ function _temp$1t() {
58071
58074
  return timer(1e3);
58072
58075
  }
58073
58076
  const INITIAL = {
@@ -58112,7 +58115,7 @@ function useComlinkViewHistory(t0) {
58112
58115
  $[13] !== displayed || $[14] !== editState2.ready || $[15] !== recordEvent || $[16] !== t7 ? (t8 = [t7, displayed, editState2.ready, recordEvent], $[13] = displayed, $[14] = editState2.ready, $[15] = recordEvent, $[16] = t7, $[17] = t8) : t8 = $[17], useEffect(t6, t8);
58113
58116
  }
58114
58117
  function useDocumentForm(options) {
58115
- const $ = c(165), {
58118
+ const $ = c(164), {
58116
58119
  documentType,
58117
58120
  getFormDocumentValue,
58118
58121
  documentId,
@@ -58158,19 +58161,23 @@ function useDocumentForm(options) {
58158
58161
  const firstVersion = t5;
58159
58162
  let t6;
58160
58163
  bb0: {
58161
- if (documentVersions.some((id_0) => getVersionFromId(id_0) === releaseId)) {
58162
- t6 = releaseId;
58164
+ if (isSystemBundle(selectedPerspectiveName)) {
58165
+ t6 = void 0;
58166
+ break bb0;
58167
+ }
58168
+ if (documentVersions.some((id_0) => getVersionFromId(id_0) === selectedPerspectiveName)) {
58169
+ t6 = selectedPerspectiveName;
58163
58170
  break bb0;
58164
58171
  }
58165
- if (releaseId && (!documentVersions || !onlyHasVersions)) {
58166
- t6 = releaseId;
58172
+ if (selectedPerspectiveName && (!documentVersions.length || !onlyHasVersions)) {
58173
+ t6 = selectedPerspectiveName;
58167
58174
  break bb0;
58168
58175
  }
58169
58176
  const t72 = firstVersion ?? "";
58170
58177
  let t82;
58171
58178
  $[13] !== t72 ? (t82 = getVersionFromId(t72), $[13] = t72, $[14] = t82) : t82 = $[14], t6 = t82;
58172
58179
  }
58173
- const editState2 = useEditState(documentId, documentType, "default", t6), connectionState = useConnectionState(documentId, documentType, releaseId);
58180
+ const activeDocumentReleaseId = t6, editState2 = useEditState(documentId, documentType, "default", activeDocumentReleaseId), connectionState = useConnectionState(documentId, documentType, activeDocumentReleaseId);
58174
58181
  useReconnectingToast(connectionState === "reconnecting");
58175
58182
  const [focusPath, setFocusPath] = useState(initialFocusPath || EMPTY_ARRAY$B);
58176
58183
  let t7;
@@ -58181,7 +58188,7 @@ function useDocumentForm(options) {
58181
58188
  _type: documentType
58182
58189
  }, $[15] = documentId, $[16] = documentType, $[17] = initialValue?.value, $[18] = t82) : t82 = $[18];
58183
58190
  const baseValue = t82;
58184
- if (releaseId) {
58191
+ if (selectedPerspectiveName) {
58185
58192
  if (editState2.version && isGoingToUnpublish(editState2.version)) {
58186
58193
  t7 = editState2.published || baseValue;
58187
58194
  break bb1;
@@ -58256,7 +58263,7 @@ function useDocumentForm(options) {
58256
58263
  const handleOnSetCollapsedFieldSet = t16;
58257
58264
  let t17;
58258
58265
  $[43] !== onSetFieldGroupState ? (t17 = (path_1, groupName) => onSetFieldGroupState((prevState_1) => setAtPath(prevState_1, path_1, groupName)), $[43] = onSetFieldGroupState, $[44] = t17) : t17 = $[44];
58259
- const handleSetActiveFieldGroup = t17, requiredPermission = value._createdAt ? "update" : "create", targetDocumentId = releaseId ? getVersionId(publishedId, releaseId) : liveEdit ? editState2?.draft?._id || publishedId : getDraftId(documentId);
58266
+ const handleSetActiveFieldGroup = t17, requiredPermission = value._createdAt ? "update" : "create", targetDocumentId = activeDocumentReleaseId ? getVersionId(publishedId, activeDocumentReleaseId) : liveEdit ? editState2?.draft?._id || publishedId : getDraftId(documentId);
58260
58267
  let t18;
58261
58268
  $[45] !== targetDocumentId || $[46] !== value ? (t18 = {
58262
58269
  ...value,
@@ -58281,41 +58288,41 @@ function useDocumentForm(options) {
58281
58288
  isLockedByCanvas
58282
58289
  } = useCanvasCompanionDoc(value._id);
58283
58290
  let t23;
58284
- $[58] !== connectionState || $[59] !== editState2 || $[60] !== isCreateLinked || $[61] !== isLockedByCanvas || $[62] !== isNonExistent || $[63] !== isPermissionsLoading || $[64] !== isReleaseLocked || $[65] !== liveEdit || $[66] !== onlyHasVersions || $[67] !== permissions?.granted || $[68] !== readOnlyProp || $[69] !== ready || $[70] !== releaseId || $[71] !== schemaType || $[72] !== selectedPerspectiveName || $[73] !== value ? (t23 = () => {
58291
+ $[58] !== connectionState || $[59] !== editState2 || $[60] !== isCreateLinked || $[61] !== isLockedByCanvas || $[62] !== isNonExistent || $[63] !== isPermissionsLoading || $[64] !== isReleaseLocked || $[65] !== liveEdit || $[66] !== onlyHasVersions || $[67] !== permissions?.granted || $[68] !== readOnlyProp || $[69] !== ready || $[70] !== schemaType || $[71] !== selectedPerspectiveName || $[72] !== value ? (t23 = () => {
58285
58292
  const hasNoPermission = !isPermissionsLoading && !permissions?.granted, updateActionDisabled = !isActionEnabled(schemaType, "update"), createActionDisabled = isNonExistent && !isActionEnabled(schemaType, "create"), reconnecting = connectionState === "reconnecting", isLocked = editState2.transactionSyncLock?.enabled, willBeUnpublished = value ? isGoingToUnpublish(value) : !1;
58286
- return editState2.version && !editState2.draft && !editState2.published && onlyHasVersions && selectedPerspectiveName !== getVersionFromId(editState2.version._id) && isNewDocument(editState2) === !1 || liveEdit && editState2.draft?._id || !liveEdit && selectedPerspectiveName === "published" || releaseId && getVersionFromId(value._id) !== releaseId && isNewDocument(editState2) === !1 || !ready || isLockedByCanvas || hasNoPermission || updateActionDisabled || createActionDisabled || reconnecting || isLocked || isCreateLinked || willBeUnpublished || isReleaseLocked ? !0 : typeof readOnlyProp == "function" ? readOnlyProp(editState2) : !!readOnlyProp;
58287
- }, $[58] = connectionState, $[59] = editState2, $[60] = isCreateLinked, $[61] = isLockedByCanvas, $[62] = isNonExistent, $[63] = isPermissionsLoading, $[64] = isReleaseLocked, $[65] = liveEdit, $[66] = onlyHasVersions, $[67] = permissions?.granted, $[68] = readOnlyProp, $[69] = ready, $[70] = releaseId, $[71] = schemaType, $[72] = selectedPerspectiveName, $[73] = value, $[74] = t23) : t23 = $[74];
58293
+ return editState2.version && !editState2.draft && !editState2.published && onlyHasVersions && selectedPerspectiveName !== getVersionFromId(editState2.version._id) && isNewDocument(editState2) === !1 || liveEdit && editState2.draft?._id || !liveEdit && selectedPerspectiveName === "published" || selectedPerspectiveName && getVersionFromId(value._id) !== selectedPerspectiveName && isNewDocument(editState2) === !1 || !ready || isLockedByCanvas || hasNoPermission || updateActionDisabled || createActionDisabled || reconnecting || isLocked || isCreateLinked || willBeUnpublished || isReleaseLocked ? !0 : typeof readOnlyProp == "function" ? readOnlyProp(editState2) : !!readOnlyProp;
58294
+ }, $[58] = connectionState, $[59] = editState2, $[60] = isCreateLinked, $[61] = isLockedByCanvas, $[62] = isNonExistent, $[63] = isPermissionsLoading, $[64] = isReleaseLocked, $[65] = liveEdit, $[66] = onlyHasVersions, $[67] = permissions?.granted, $[68] = readOnlyProp, $[69] = ready, $[70] = schemaType, $[71] = selectedPerspectiveName, $[72] = value, $[73] = t23) : t23 = $[73];
58288
58295
  let t24;
58289
- $[75] !== t23 ? (t24 = t23(), $[75] = t23, $[76] = t24) : t24 = $[76];
58296
+ $[74] !== t23 ? (t24 = t23(), $[74] = t23, $[75] = t24) : t24 = $[75];
58290
58297
  const readOnly = t24, {
58291
58298
  patch: patch2
58292
- } = useDocumentOperation(documentId, documentType, releaseId), patchRef = useRef(_temp$1r);
58299
+ } = useDocumentOperation(documentId, documentType, activeDocumentReleaseId), patchRef = useRef(_temp$1s);
58293
58300
  let t25;
58294
- $[77] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t25 = (event) => patchRef.current(event), $[77] = t25) : t25 = $[77];
58301
+ $[76] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t25 = (event) => patchRef.current(event), $[76] = t25) : t25 = $[76];
58295
58302
  const handleChange = t25;
58296
58303
  let t26;
58297
- $[78] !== editState2.draft || $[79] !== editState2.published || $[80] !== initialValue?.value || $[81] !== isCreateLinked || $[82] !== patch2 || $[83] !== readOnly || $[84] !== telemetry ? (t26 = () => {
58304
+ $[77] !== editState2.draft || $[78] !== editState2.published || $[79] !== initialValue?.value || $[80] !== isCreateLinked || $[81] !== patch2 || $[82] !== readOnly || $[83] !== telemetry ? (t26 = () => {
58298
58305
  readOnly && !isCreateLinked ? patchRef.current = _temp2$B : patchRef.current = (event_0) => {
58299
58306
  !editState2.draft && !editState2.published && telemetry.log(CreatedDraft), patch2.execute(toMutationPatches(event_0.patches), initialValue?.value);
58300
58307
  };
58301
- }, $[78] = editState2.draft, $[79] = editState2.published, $[80] = initialValue?.value, $[81] = isCreateLinked, $[82] = patch2, $[83] = readOnly, $[84] = telemetry, $[85] = t26) : t26 = $[85];
58308
+ }, $[77] = editState2.draft, $[78] = editState2.published, $[79] = initialValue?.value, $[80] = isCreateLinked, $[81] = patch2, $[82] = readOnly, $[83] = telemetry, $[84] = t26) : t26 = $[84];
58302
58309
  let t27;
58303
- $[86] !== editState2.draft || $[87] !== editState2.published || $[88] !== initialValue || $[89] !== isCreateLinked || $[90] !== patch2 || $[91] !== readOnly || $[92] !== telemetry ? (t27 = [editState2.draft, editState2.published, initialValue, patch2, telemetry, readOnly, isCreateLinked], $[86] = editState2.draft, $[87] = editState2.published, $[88] = initialValue, $[89] = isCreateLinked, $[90] = patch2, $[91] = readOnly, $[92] = telemetry, $[93] = t27) : t27 = $[93], useInsertionEffect(t26, t27);
58310
+ $[85] !== editState2.draft || $[86] !== editState2.published || $[87] !== initialValue || $[88] !== isCreateLinked || $[89] !== patch2 || $[90] !== readOnly || $[91] !== telemetry ? (t27 = [editState2.draft, editState2.published, initialValue, patch2, telemetry, readOnly, isCreateLinked], $[85] = editState2.draft, $[86] = editState2.published, $[87] = initialValue, $[88] = isCreateLinked, $[89] = patch2, $[90] = readOnly, $[91] = telemetry, $[92] = t27) : t27 = $[92], useInsertionEffect(t26, t27);
58304
58311
  let t28;
58305
58312
  bb3: {
58306
58313
  if (getFormDocumentValue) {
58307
58314
  let t292;
58308
- $[94] !== getFormDocumentValue || $[95] !== value ? (t292 = getFormDocumentValue(value), $[94] = getFormDocumentValue, $[95] = value, $[96] = t292) : t292 = $[96], t28 = t292;
58315
+ $[93] !== getFormDocumentValue || $[94] !== value ? (t292 = getFormDocumentValue(value), $[93] = getFormDocumentValue, $[94] = value, $[95] = t292) : t292 = $[95], t28 = t292;
58309
58316
  break bb3;
58310
58317
  }
58311
58318
  t28 = value;
58312
58319
  }
58313
58320
  const formDocumentValue = t28;
58314
58321
  let t29;
58315
- $[97] !== upstreamEditState ? (t29 = selectUpstreamVersion(upstreamEditState), $[97] = upstreamEditState, $[98] = t29) : t29 = $[98];
58322
+ $[96] !== upstreamEditState ? (t29 = selectUpstreamVersion(upstreamEditState), $[96] = upstreamEditState, $[97] = t29) : t29 = $[97];
58316
58323
  const hasUpstreamVersion = t29 !== null, t30 = comparisonValue || value;
58317
58324
  let t31;
58318
- $[99] !== changesOpen || $[100] !== collapsedFieldSets || $[101] !== collapsedPaths || $[102] !== displayInlineChanges || $[103] !== fieldGroupState || $[104] !== focusPath || $[105] !== formDocumentValue || $[106] !== hasUpstreamVersion || $[107] !== openPath || $[108] !== presence || $[109] !== readOnly || $[110] !== schemaType || $[111] !== selectedPerspective || $[112] !== t30 || $[113] !== validation2 ? (t31 = {
58325
+ $[98] !== changesOpen || $[99] !== collapsedFieldSets || $[100] !== collapsedPaths || $[101] !== displayInlineChanges || $[102] !== fieldGroupState || $[103] !== focusPath || $[104] !== formDocumentValue || $[105] !== hasUpstreamVersion || $[106] !== openPath || $[107] !== presence || $[108] !== readOnly || $[109] !== schemaType || $[110] !== selectedPerspective || $[111] !== t30 || $[112] !== validation2 ? (t31 = {
58319
58326
  schemaType,
58320
58327
  documentValue: formDocumentValue,
58321
58328
  readOnly,
@@ -58331,25 +58338,25 @@ function useDocumentForm(options) {
58331
58338
  changesOpen,
58332
58339
  hasUpstreamVersion,
58333
58340
  displayInlineChanges
58334
- }, $[99] = changesOpen, $[100] = collapsedFieldSets, $[101] = collapsedPaths, $[102] = displayInlineChanges, $[103] = fieldGroupState, $[104] = focusPath, $[105] = formDocumentValue, $[106] = hasUpstreamVersion, $[107] = openPath, $[108] = presence, $[109] = readOnly, $[110] = schemaType, $[111] = selectedPerspective, $[112] = t30, $[113] = validation2, $[114] = t31) : t31 = $[114];
58341
+ }, $[98] = changesOpen, $[99] = collapsedFieldSets, $[100] = collapsedPaths, $[101] = displayInlineChanges, $[102] = fieldGroupState, $[103] = focusPath, $[104] = formDocumentValue, $[105] = hasUpstreamVersion, $[106] = openPath, $[107] = presence, $[108] = readOnly, $[109] = schemaType, $[110] = selectedPerspective, $[111] = t30, $[112] = validation2, $[113] = t31) : t31 = $[113];
58335
58342
  const formState = useFormState(t31), formStateRef = useRef(formState);
58336
58343
  let t32, t33;
58337
- $[115] !== formState ? (t32 = () => {
58344
+ $[114] !== formState ? (t32 = () => {
58338
58345
  formStateRef.current = formState;
58339
- }, t33 = [formState], $[115] = formState, $[116] = t32, $[117] = t33) : (t32 = $[116], t33 = $[117]), useEffect(t32, t33);
58346
+ }, t33 = [formState], $[114] = formState, $[115] = t32, $[116] = t33) : (t32 = $[115], t33 = $[116]), useEffect(t32, t33);
58340
58347
  let t34;
58341
- $[118] !== editState2 ? (t34 = {
58348
+ $[117] !== editState2 ? (t34 = {
58342
58349
  editState: editState2
58343
- }, $[118] = editState2, $[119] = t34) : t34 = $[119], useComlinkViewHistory(t34);
58350
+ }, $[117] = editState2, $[118] = t34) : t34 = $[118], useComlinkViewHistory(t34);
58344
58351
  let t35;
58345
- $[120] !== onSetCollapsedFieldSets || $[121] !== onSetCollapsedPath || $[122] !== onSetFieldGroupState || $[123] !== onSetOpenPath ? (t35 = (path_2) => {
58352
+ $[119] !== onSetCollapsedFieldSets || $[120] !== onSetCollapsedPath || $[121] !== onSetFieldGroupState || $[122] !== onSetOpenPath ? (t35 = (path_2) => {
58346
58353
  getExpandOperations(formStateRef.current, path_2).forEach((op) => {
58347
58354
  op.type === "expandPath" && onSetCollapsedPath((prevState_2) => setAtPath(prevState_2, op.path, !1)), op.type === "expandFieldSet" && onSetCollapsedFieldSets((prevState_3) => setAtPath(prevState_3, op.path, !1)), op.type === "setSelectedGroup" && onSetFieldGroupState((prevState_4) => setAtPath(prevState_4, op.path, op.groupName));
58348
58355
  }), onSetOpenPath(path_2);
58349
- }, $[120] = onSetCollapsedFieldSets, $[121] = onSetCollapsedPath, $[122] = onSetFieldGroupState, $[123] = onSetOpenPath, $[124] = t35) : t35 = $[124];
58356
+ }, $[119] = onSetCollapsedFieldSets, $[120] = onSetCollapsedPath, $[121] = onSetFieldGroupState, $[122] = onSetOpenPath, $[123] = t35) : t35 = $[123];
58350
58357
  const handleSetOpenPath = t35;
58351
58358
  let t36;
58352
- $[125] !== presenceStore || $[126] !== value._id ? (t36 = throttle((nextFocusPath, payload) => {
58359
+ $[124] !== presenceStore || $[125] !== value._id ? (t36 = throttle((nextFocusPath, payload) => {
58353
58360
  presenceStore.setLocation([{
58354
58361
  type: "document",
58355
58362
  documentId: value._id,
@@ -58360,13 +58367,13 @@ function useDocumentForm(options) {
58360
58367
  }, 1e3, {
58361
58368
  leading: !0,
58362
58369
  trailing: !0
58363
- }), $[125] = presenceStore, $[126] = value._id, $[127] = t36) : t36 = $[127];
58370
+ }), $[124] = presenceStore, $[125] = value._id, $[126] = t36) : t36 = $[126];
58364
58371
  const updatePresenceThrottled = t36;
58365
58372
  let t37;
58366
- $[128] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t37 = [], $[128] = t37) : t37 = $[128];
58373
+ $[127] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t37 = [], $[127] = t37) : t37 = $[127];
58367
58374
  const focusPathRef = useRef(t37);
58368
58375
  let t38;
58369
- $[129] !== enhancedObjectDialogEnabled || $[130] !== handleSetOpenPath || $[131] !== onFocusPath || $[132] !== setFocusPath || $[133] !== updatePresenceThrottled ? (t38 = (_nextFocusPath, payload_0) => {
58376
+ $[128] !== enhancedObjectDialogEnabled || $[129] !== handleSetOpenPath || $[130] !== onFocusPath || $[131] !== setFocusPath || $[132] !== updatePresenceThrottled ? (t38 = (_nextFocusPath, payload_0) => {
58370
58377
  const nextFocusPath_0 = pathFor(_nextFocusPath);
58371
58378
  if (nextFocusPath_0 !== focusPathRef.current) {
58372
58379
  if (setFocusPath(pathFor(nextFocusPath_0)), enhancedObjectDialogEnabled) {
@@ -58380,20 +58387,20 @@ function useDocumentForm(options) {
58380
58387
  focusPathRef.current = nextFocusPath_0, onFocusPath?.(nextFocusPath_0);
58381
58388
  }
58382
58389
  updatePresenceThrottled(nextFocusPath_0, payload_0);
58383
- }, $[129] = enhancedObjectDialogEnabled, $[130] = handleSetOpenPath, $[131] = onFocusPath, $[132] = setFocusPath, $[133] = updatePresenceThrottled, $[134] = t38) : t38 = $[134];
58390
+ }, $[128] = enhancedObjectDialogEnabled, $[129] = handleSetOpenPath, $[130] = onFocusPath, $[131] = setFocusPath, $[132] = updatePresenceThrottled, $[133] = t38) : t38 = $[133];
58384
58391
  const handleFocus = t38;
58385
58392
  let t39;
58386
- $[135] !== onFocusPath || $[136] !== setFocusPath ? (t39 = (_blurredPath) => {
58393
+ $[134] !== onFocusPath || $[135] !== setFocusPath ? (t39 = (_blurredPath) => {
58387
58394
  setFocusPath(EMPTY_ARRAY$B), focusPathRef.current !== EMPTY_ARRAY$B && (focusPathRef.current = EMPTY_ARRAY$B, onFocusPath?.(EMPTY_ARRAY$B));
58388
- }, $[135] = onFocusPath, $[136] = setFocusPath, $[137] = t39) : t39 = $[137];
58395
+ }, $[134] = onFocusPath, $[135] = setFocusPath, $[136] = t39) : t39 = $[136];
58389
58396
  const handleBlur = t39;
58390
58397
  let t40;
58391
- $[138] !== handleSetOpenPath || $[139] !== onFocusPath || $[140] !== setFocusPath ? (t40 = (nextPath) => {
58398
+ $[137] !== handleSetOpenPath || $[138] !== onFocusPath || $[139] !== setFocusPath ? (t40 = (nextPath) => {
58392
58399
  deepEquals(focusPathRef.current, nextPath) || (setFocusPath(nextPath), handleSetOpenPath(nextPath), onFocusPath?.(nextPath), focusPathRef.current = nextPath);
58393
- }, $[138] = handleSetOpenPath, $[139] = onFocusPath, $[140] = setFocusPath, $[141] = t40) : t40 = $[141];
58400
+ }, $[137] = handleSetOpenPath, $[138] = onFocusPath, $[139] = setFocusPath, $[140] = t40) : t40 = $[140];
58394
58401
  const handleProgrammaticFocus = t40;
58395
58402
  let t41;
58396
- return $[142] !== collapsedFieldSets || $[143] !== collapsedPaths || $[144] !== connectionState || $[145] !== editState2 || $[146] !== focusPath || $[147] !== formState || $[148] !== handleBlur || $[149] !== handleFocus || $[150] !== handleOnSetCollapsedFieldSet || $[151] !== handleOnSetCollapsedPath || $[152] !== handleProgrammaticFocus || $[153] !== handleSetActiveFieldGroup || $[154] !== handleSetOpenPath || $[155] !== hasUpstreamVersion || $[156] !== isPermissionsLoading || $[157] !== openPath || $[158] !== permissions || $[159] !== ready || $[160] !== schemaType || $[161] !== upstreamEditState || $[162] !== validation2 || $[163] !== value ? (t41 = {
58403
+ return $[141] !== collapsedFieldSets || $[142] !== collapsedPaths || $[143] !== connectionState || $[144] !== editState2 || $[145] !== focusPath || $[146] !== formState || $[147] !== handleBlur || $[148] !== handleFocus || $[149] !== handleOnSetCollapsedFieldSet || $[150] !== handleOnSetCollapsedPath || $[151] !== handleProgrammaticFocus || $[152] !== handleSetActiveFieldGroup || $[153] !== handleSetOpenPath || $[154] !== hasUpstreamVersion || $[155] !== isPermissionsLoading || $[156] !== openPath || $[157] !== permissions || $[158] !== ready || $[159] !== schemaType || $[160] !== upstreamEditState || $[161] !== validation2 || $[162] !== value ? (t41 = {
58397
58404
  editState: editState2,
58398
58405
  upstreamEditState,
58399
58406
  connectionState,
@@ -58418,7 +58425,7 @@ function useDocumentForm(options) {
58418
58425
  onSetActiveFieldGroup: handleSetActiveFieldGroup,
58419
58426
  onSetCollapsedPath: handleOnSetCollapsedPath,
58420
58427
  onSetCollapsedFieldSet: handleOnSetCollapsedFieldSet
58421
- }, $[142] = collapsedFieldSets, $[143] = collapsedPaths, $[144] = connectionState, $[145] = editState2, $[146] = focusPath, $[147] = formState, $[148] = handleBlur, $[149] = handleFocus, $[150] = handleOnSetCollapsedFieldSet, $[151] = handleOnSetCollapsedPath, $[152] = handleProgrammaticFocus, $[153] = handleSetActiveFieldGroup, $[154] = handleSetOpenPath, $[155] = hasUpstreamVersion, $[156] = isPermissionsLoading, $[157] = openPath, $[158] = permissions, $[159] = ready, $[160] = schemaType, $[161] = upstreamEditState, $[162] = validation2, $[163] = value, $[164] = t41) : t41 = $[164], t41;
58428
+ }, $[141] = collapsedFieldSets, $[142] = collapsedPaths, $[143] = connectionState, $[144] = editState2, $[145] = focusPath, $[146] = formState, $[147] = handleBlur, $[148] = handleFocus, $[149] = handleOnSetCollapsedFieldSet, $[150] = handleOnSetCollapsedPath, $[151] = handleProgrammaticFocus, $[152] = handleSetActiveFieldGroup, $[153] = handleSetOpenPath, $[154] = hasUpstreamVersion, $[155] = isPermissionsLoading, $[156] = openPath, $[157] = permissions, $[158] = ready, $[159] = schemaType, $[160] = upstreamEditState, $[161] = validation2, $[162] = value, $[163] = t41) : t41 = $[163], t41;
58422
58429
  }
58423
58430
  function _temp3$j(seg) {
58424
58431
  return isKeySegment(seg);
@@ -58426,7 +58433,7 @@ function _temp3$j(seg) {
58426
58433
  function _temp2$B() {
58427
58434
  throw new Error("Attempted to patch a read-only document");
58428
58435
  }
58429
- function _temp$1r() {
58436
+ function _temp$1s() {
58430
58437
  throw new Error("Attempted to patch the Sanity document during initial render or in an `useInsertionEffect`. Input components should only call `onChange()` in a useEffect or an event handler.");
58431
58438
  }
58432
58439
  const IS_NUMERIC = /^\d+$/;
@@ -58771,7 +58778,7 @@ function SelectAssetsDialog(props2) {
58771
58778
  i18n: workspace.i18n,
58772
58779
  environment: "studio",
58773
58780
  document: document2,
58774
- getDocumentExists: _temp$1q
58781
+ getDocumentExists: _temp$1r
58775
58782
  });
58776
58783
  return filterMediaValidationMarkers(result);
58777
58784
  }, $[4] = client, $[5] = document2, $[6] = mediaLibraryIds?.libraryId, $[7] = schema2, $[8] = schemaType, $[9] = workspace.i18n, $[10] = t4) : t4 = $[10];
@@ -58892,7 +58899,7 @@ function _temp2$A(filter2) {
58892
58899
  active: !0
58893
58900
  };
58894
58901
  }
58895
- async function _temp$1q() {
58902
+ async function _temp$1r() {
58896
58903
  return !0;
58897
58904
  }
58898
58905
  function UploadAssetsDialog(props2) {
@@ -58952,7 +58959,7 @@ function UploadAssetsDialog(props2) {
58952
58959
  let t3, t4;
58953
58960
  if ($[12] !== open || $[13] !== pageReadyForUploads || $[14] !== postMessage || $[15] !== t || $[16] !== toast || $[17] !== uploader ? (t3 = () => {
58954
58961
  if (open && uploader) {
58955
- pageReadyForUploads && uploader.getFiles().length > 0 && uploader.getFiles().every(_temp$1p) && (postMessage({
58962
+ pageReadyForUploads && uploader.getFiles().length > 0 && uploader.getFiles().every(_temp$1q) && (postMessage({
58956
58963
  type: "uploadRequest",
58957
58964
  files: uploader.getFiles()
58958
58965
  }), setPageReadyForUploads(!1));
@@ -58988,7 +58995,7 @@ function UploadAssetsDialog(props2) {
58988
58995
  function _temp2$z(file_0) {
58989
58996
  return file_0.status === "alreadyExists";
58990
58997
  }
58991
- function _temp$1p(file) {
58998
+ function _temp$1q(file) {
58992
58999
  return file.status === "pending";
58993
59000
  }
58994
59001
  const MediaLibraryAssetSourceComponent = function(props2, ref) {
@@ -59035,13 +59042,13 @@ const MediaLibraryAssetSourceComponent = function(props2, ref) {
59035
59042
  t10
59036
59043
  ] }), $[26] = libraryIdProp, $[27] = projectId, $[28] = t10, $[29] = t5, $[30] = t11) : t11 = $[30], t11;
59037
59044
  }, MediaLibraryAssetSource = memo(forwardRef(MediaLibraryAssetSourceComponent)), useRootPortalElement = () => {
59038
- const $ = c(3), [container] = useState(_temp$1o);
59045
+ const $ = c(3), [container] = useState(_temp$1p);
59039
59046
  let t0, t1;
59040
59047
  return $[0] !== container ? (t0 = () => (container.classList.add("media-library-portal"), document.body.appendChild(container), () => {
59041
59048
  document.body.removeChild(container);
59042
59049
  }), t1 = [container], $[0] = container, $[1] = t0, $[2] = t1) : (t0 = $[1], t1 = $[2]), useEffect(t0, t1), container;
59043
59050
  };
59044
- function _temp$1o() {
59051
+ function _temp$1p() {
59045
59052
  return document.createElement("div");
59046
59053
  }
59047
59054
  class MediaLibraryUploader {
@@ -59177,7 +59184,7 @@ function DefaultIcon(t0) {
59177
59184
  } = t0, theme = useTheme$1(), fontFamily = theme.sanity.fonts.text.family, fontWeight = theme.sanity.fonts.text.weights.medium, fontSize = `${theme.sanity.fonts.text.sizes[1].fontSize}px`;
59178
59185
  let t1;
59179
59186
  $[0] !== subtitle || $[1] !== title ? (t1 = () => pseudoRandomNumber(`${title} ${subtitle}`), $[0] = subtitle, $[1] = title, $[2] = t1) : t1 = $[2];
59180
- const [rng1] = useState(t1), huesWithoutGray = COLOR_HUES.filter(_temp$1n), colorHue = huesWithoutGray[Math.floor(rng1 * huesWithoutGray.length)];
59187
+ const [rng1] = useState(t1), huesWithoutGray = COLOR_HUES.filter(_temp$1o), colorHue = huesWithoutGray[Math.floor(rng1 * huesWithoutGray.length)];
59181
59188
  let t2;
59182
59189
  $[3] !== rng1 ? (t2 = () => pseudoRandomNumber(rng1.toString()), $[3] = rng1, $[4] = t2) : t2 = $[4];
59183
59190
  const [rng2] = useState(t2), tint = possibleTints[Math.floor(rng2 * possibleTints.length)], color = hues[colorHue][tint].hex;
@@ -59214,7 +59221,7 @@ function _temp3$h(i) {
59214
59221
  function _temp2$y(word) {
59215
59222
  return word.replace(/\\W/g, "");
59216
59223
  }
59217
- function _temp$1n(hue) {
59224
+ function _temp$1o(hue) {
59218
59225
  return hue !== "gray";
59219
59226
  }
59220
59227
  function createDefaultIcon(title, subtitle) {
@@ -60757,7 +60764,7 @@ const NO_FILTER = () => !0, StyledText$2 = styled(Text$1)`
60757
60764
  }, $[4] = types, $[5] = t6) : t6 = $[5];
60758
60765
  let t7;
60759
60766
  $[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = (result) => {
60760
- setHits(result.hits.map(_temp$1m));
60767
+ setHits(result.hits.map(_temp$1n));
60761
60768
  }, $[6] = t7) : t7 = $[6];
60762
60769
  let t8;
60763
60770
  $[7] !== schema2 || $[8] !== t6 ? (t8 = {
@@ -60866,7 +60873,7 @@ const NO_FILTER = () => !0, StyledText$2 = styled(Text$1)`
60866
60873
  let t17;
60867
60874
  return $[31] !== autocompleteId || $[32] !== handleQueryChange || $[33] !== handleSelect || $[34] !== hits || $[35] !== placeholderText || $[36] !== ref || $[37] !== renderPopover || $[38] !== searchState.loading || $[39] !== t14 || $[40] !== t15 || $[41] !== t16 ? (t17 = /* @__PURE__ */ jsx("div", { ref: autocompletePopoverReferenceElementRef, children: /* @__PURE__ */ jsx(Autocomplete, { "aria-label": placeholderText, filterOption: NO_FILTER, fontSize: t14, id: autocompleteId, loading: searchState.loading, openButton: t15, options: hits, onQueryChange: handleQueryChange, onSelect: handleSelect, placeholder: placeholderText, radius: 2, ref, renderOption, renderPopover, value: t16 }) }), $[31] = autocompleteId, $[32] = handleQueryChange, $[33] = handleSelect, $[34] = hits, $[35] = placeholderText, $[36] = ref, $[37] = renderPopover, $[38] = searchState.loading, $[39] = t14, $[40] = t15, $[41] = t16, $[42] = t17) : t17 = $[42], t17;
60868
60875
  });
60869
- function _temp$1m(t0) {
60876
+ function _temp$1n(t0) {
60870
60877
  const {
60871
60878
  hit
60872
60879
  } = t0;
@@ -60911,7 +60918,7 @@ function SearchFilterReferenceInput(t0) {
60911
60918
  if (schemaType) {
60912
60919
  const field = getSchemaField$2(schemaType, fieldDefinition.fieldPath);
60913
60920
  if (isArraySchemaType(field?.type))
60914
- return field?.type.of.filter(isReferenceSchemaType).flatMap(_temp$1l);
60921
+ return field?.type.of.filter(isReferenceSchemaType).flatMap(_temp$1m);
60915
60922
  if (isReferenceSchemaType(field?.type))
60916
60923
  return field?.type.to;
60917
60924
  }
@@ -60943,7 +60950,7 @@ function SearchFilterReferenceInput(t0) {
60943
60950
  function _temp2$w(acc, val) {
60944
60951
  return acc.findIndex((v) => v.name === val?.name) < 0 && acc.push(val), acc;
60945
60952
  }
60946
- function _temp$1l(i) {
60953
+ function _temp$1m(i) {
60947
60954
  return i.to;
60948
60955
  }
60949
60956
  function CustomMenuItem(t0) {
@@ -60988,7 +60995,7 @@ function SearchFilterStringListInput(t0) {
60988
60995
  $[8] !== fieldDefinition.fieldPath || $[9] !== schema2 ? (t52 = (type) => {
60989
60996
  const schemaType = schema2.get(type);
60990
60997
  return schemaType ? getSchemaField$2(schemaType, fieldDefinition.fieldPath)?.type.options : null;
60991
- }, $[8] = fieldDefinition.fieldPath, $[9] = schema2, $[10] = t52) : t52 = $[10], t32 = fieldDefinition.documentTypes.filter(t42).map(t52).filter(isNonNullable$3).map(_temp$1k).flatMap(_temp3$g).filter(isNonNullable$3).reduce(_temp5$5, []), $[1] = documentTypesNarrowed, $[2] = fieldDefinition.documentTypes, $[3] = fieldDefinition.fieldPath, $[4] = schema2, $[5] = t32;
60998
+ }, $[8] = fieldDefinition.fieldPath, $[9] = schema2, $[10] = t52) : t52 = $[10], t32 = fieldDefinition.documentTypes.filter(t42).map(t52).filter(isNonNullable$3).map(_temp$1l).flatMap(_temp3$g).filter(isNonNullable$3).reduce(_temp5$5, []), $[1] = documentTypesNarrowed, $[2] = fieldDefinition.documentTypes, $[3] = fieldDefinition.fieldPath, $[4] = schema2, $[5] = t32;
60992
60999
  } else
60993
61000
  t32 = $[5];
60994
61001
  t2 = t32;
@@ -61046,7 +61053,7 @@ function _temp3$g(list) {
61046
61053
  function _temp2$v(l) {
61047
61054
  return toSelectItem(l);
61048
61055
  }
61049
- function _temp$1k(o) {
61056
+ function _temp$1l(o) {
61050
61057
  return o.list;
61051
61058
  }
61052
61059
  function toSelectItem(option) {
@@ -61247,9 +61254,9 @@ function FileReferencePreview(t0) {
61247
61254
  let t2;
61248
61255
  $[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = /* @__PURE__ */ jsx(FileSkeleton, {}), $[2] = t2) : t2 = $[2];
61249
61256
  let t3;
61250
- return $[3] !== observeAsset || $[4] !== reference ? (t3 = /* @__PURE__ */ jsx(WithReferencedAsset, { observeAsset, reference, waitPlaceholder: t2, children: _temp$1j }), $[3] = observeAsset, $[4] = reference, $[5] = t3) : t3 = $[5], t3;
61257
+ return $[3] !== observeAsset || $[4] !== reference ? (t3 = /* @__PURE__ */ jsx(WithReferencedAsset, { observeAsset, reference, waitPlaceholder: t2, children: _temp$1k }), $[3] = observeAsset, $[4] = reference, $[5] = t3) : t3 = $[5], t3;
61251
61258
  }
61252
- function _temp$1j(asset) {
61259
+ function _temp$1k(asset) {
61253
61260
  return /* @__PURE__ */ jsx(FilePreview, { asset });
61254
61261
  }
61255
61262
  function FilePreview(t0) {
@@ -61313,9 +61320,9 @@ function ImageReferencePreview(t0) {
61313
61320
  $[0] !== documentPreviewStore ? (t1 = (id2) => observeImageAsset(documentPreviewStore, id2), $[0] = documentPreviewStore, $[1] = t1) : t1 = $[1];
61314
61321
  const observeAsset = t1;
61315
61322
  let t2;
61316
- return $[2] !== observeAsset || $[3] !== reference ? (t2 = /* @__PURE__ */ jsx(WithReferencedAsset, { observeAsset, reference, children: _temp$1i }), $[2] = observeAsset, $[3] = reference, $[4] = t2) : t2 = $[4], t2;
61323
+ return $[2] !== observeAsset || $[3] !== reference ? (t2 = /* @__PURE__ */ jsx(WithReferencedAsset, { observeAsset, reference, children: _temp$1j }), $[2] = observeAsset, $[3] = reference, $[4] = t2) : t2 = $[4], t2;
61317
61324
  }
61318
- function _temp$1i(asset) {
61325
+ function _temp$1j(asset) {
61319
61326
  return /* @__PURE__ */ jsx(ImagePreview, { asset });
61320
61327
  }
61321
61328
  function ImagePreview(t0) {
@@ -61689,9 +61696,9 @@ const ARROW_KEYS$1 = ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight"], TAIL_W
61689
61696
  weekInfo
61690
61697
  } = useCurrentLocale();
61691
61698
  let t0;
61692
- return $[0] !== date || $[1] !== weekInfo.firstDay ? (t0 = getWeekDaysFromWeekStarts$1(getWeekStartsOfMonth$1(date, weekInfo.firstDay)).map(_temp$1h), $[0] = date, $[1] = weekInfo.firstDay, $[2] = t0) : t0 = $[2], t0;
61699
+ return $[0] !== date || $[1] !== weekInfo.firstDay ? (t0 = getWeekDaysFromWeekStarts$1(getWeekStartsOfMonth$1(date, weekInfo.firstDay)).map(_temp$1i), $[0] = date, $[1] = weekInfo.firstDay, $[2] = t0) : t0 = $[2], t0;
61693
61700
  };
61694
- function _temp$1h(days) {
61701
+ function _temp$1i(days) {
61695
61702
  return {
61696
61703
  number: getWeek(days[0]),
61697
61704
  days
@@ -62235,7 +62242,7 @@ function CommonDateRangeInput(t0) {
62235
62242
  state: t1
62236
62243
  } = useSearchState(), {
62237
62244
  fullscreen
62238
- } = t1, [placeholderStartDate] = useState(_temp$1g), [placeholderEndDate] = useState(_temp2$u);
62245
+ } = t1, [placeholderStartDate] = useState(_temp$1h), [placeholderEndDate] = useState(_temp2$u);
62239
62246
  let t2;
62240
62247
  $[0] !== isDateTime || $[1] !== onChange || $[2] !== value?.includeTime ? (t2 = (t32) => {
62241
62248
  const {
@@ -62312,7 +62319,7 @@ function CommonDateRangeInput(t0) {
62312
62319
  function _temp2$u() {
62313
62320
  return /* @__PURE__ */ new Date();
62314
62321
  }
62315
- function _temp$1g() {
62322
+ function _temp$1h() {
62316
62323
  return addDays(/* @__PURE__ */ new Date(), PLACEHOLDER_START_DATE_OFFSET);
62317
62324
  }
62318
62325
  function getStartAndEndDate({
@@ -63091,7 +63098,7 @@ function useVideoPlaybackInfo(params) {
63091
63098
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
63092
63099
  apiVersion: DEFAULT_API_VERSION
63093
63100
  }, $[0] = t0) : t0 = $[0];
63094
- const client = useClient(t0), [retrySubject] = useState(_temp$1f);
63101
+ const client = useClient(t0), [retrySubject] = useState(_temp$1g);
63095
63102
  let t1;
63096
63103
  $[1] !== retrySubject ? (t1 = () => {
63097
63104
  retrySubject.next();
@@ -63151,7 +63158,7 @@ function useVideoPlaybackInfo(params) {
63151
63158
  const [initialState2, playbackInfoObservable] = t2;
63152
63159
  return useObservable(playbackInfoObservable, initialState2);
63153
63160
  }
63154
- function _temp$1f() {
63161
+ function _temp$1g() {
63155
63162
  return new Subject();
63156
63163
  }
63157
63164
  function VideoSkeleton(t0) {
@@ -63326,7 +63333,7 @@ function VideoPreview(props2) {
63326
63333
  } : baseProps, $[16] = baseProps, $[17] = tokens, $[18] = t7) : t7 = $[18];
63327
63334
  const videoActionsMenuProps = t7;
63328
63335
  let t8;
63329
- $[19] !== assetSources ? (t8 = assetSources.filter(_temp$1e), $[19] = assetSources, $[20] = t8) : t8 = $[20];
63336
+ $[19] !== assetSources ? (t8 = assetSources.filter(_temp$1f), $[19] = assetSources, $[20] = t8) : t8 = $[20];
63330
63337
  const assetSourcesWithUpload = t8;
63331
63338
  let t9;
63332
63339
  $[21] !== assetSources || $[22] !== setSelectedAssetSource ? (t9 = (event) => {
@@ -63390,7 +63397,7 @@ function VideoPreview(props2) {
63390
63397
  let t16;
63391
63398
  return $[61] !== t15 || $[62] !== videoActionsMenuProps ? (t16 = /* @__PURE__ */ jsx(VideoActionsMenu, { ...videoActionsMenuProps, children: t15 }), $[61] = t15, $[62] = videoActionsMenuProps, $[63] = t16) : t16 = $[63], t16;
63392
63399
  }
63393
- function _temp$1e(s) {
63400
+ function _temp$1f(s) {
63394
63401
  return !!s.Uploader;
63395
63402
  }
63396
63403
  const ASSET_FIELD_PATH = ["asset"];
@@ -63428,7 +63435,7 @@ function VideoAsset(props2) {
63428
63435
  $[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = [], $[2] = t1) : t1 = $[2];
63429
63436
  const [filesToUploadFromPaste, setFilesToUploadFromPaste] = useState(t1);
63430
63437
  let t2;
63431
- $[3] !== assetSources ? (t2 = assetSources.filter(_temp$1d), $[3] = assetSources, $[4] = t2) : t2 = $[4];
63438
+ $[3] !== assetSources ? (t2 = assetSources.filter(_temp$1e), $[3] = assetSources, $[4] = t2) : t2 = $[4];
63432
63439
  const hasMultipleUploadSources = t2.length > 1;
63433
63440
  let t3;
63434
63441
  $[5] !== elementProps ? (t3 = (event) => {
@@ -63519,7 +63526,7 @@ function _temp3$f(s_0) {
63519
63526
  function _temp2$t(file) {
63520
63527
  return file.kind !== "string";
63521
63528
  }
63522
- function _temp$1d(s) {
63529
+ function _temp$1e(s) {
63523
63530
  return !!s.Uploader;
63524
63531
  }
63525
63532
  function FileUploadPlaceHolder(props2) {
@@ -63711,7 +63718,7 @@ function BaseVideoInput(props2) {
63711
63718
  break bb65;
63712
63719
  }
63713
63720
  case "error": {
63714
- event.files.forEach(_temp$1c), push({
63721
+ event.files.forEach(_temp$1d), push({
63715
63722
  status: "error",
63716
63723
  description: t("asset-sources.common.uploader.upload-failed.description"),
63717
63724
  title: t("asset-sources.common.uploader.upload-failed.title")
@@ -63769,7 +63776,7 @@ function BaseVideoInput(props2) {
63769
63776
  t14
63770
63777
  ] }), $[78] = t13, $[79] = t14, $[80] = t15) : t15 = $[80], t15;
63771
63778
  }
63772
- function _temp$1c(video_0) {
63779
+ function _temp$1d(video_0) {
63773
63780
  console.error(video_0.error);
63774
63781
  }
63775
63782
  function StudioVideoInput(props2) {
@@ -63780,7 +63787,7 @@ function StudioVideoInput(props2) {
63780
63787
  $[0] !== fileConfig.directUploads ? (t0 = (type, file) => fileConfig.directUploads ? resolveUploader(type, file) : null, $[0] = fileConfig.directUploads, $[1] = t0) : t0 = $[1];
63781
63788
  const resolveUploader$1 = t0, assetSources = sourcesFromSchema || fileConfig.assetSources;
63782
63789
  let t1;
63783
- $[2] !== assetSources ? (t1 = assetSources.filter(_temp$1b), $[2] = assetSources, $[3] = t1) : t1 = $[3];
63790
+ $[2] !== assetSources ? (t1 = assetSources.filter(_temp$1c), $[2] = assetSources, $[3] = t1) : t1 = $[3];
63784
63791
  const filteredAssetSources = t1;
63785
63792
  let t2;
63786
63793
  $[4] !== documentPreviewStore ? (t2 = (id2) => observeVideoAsset(documentPreviewStore, id2), $[4] = documentPreviewStore, $[5] = t2) : t2 = $[5];
@@ -63788,7 +63795,7 @@ function StudioVideoInput(props2) {
63788
63795
  let t3;
63789
63796
  return $[6] !== client || $[7] !== fileConfig.directUploads || $[8] !== filteredAssetSources || $[9] !== observeAsset || $[10] !== props2 || $[11] !== resolveUploader$1 ? (t3 = /* @__PURE__ */ jsx(BaseVideoInput, { ...props2, client, assetSources: filteredAssetSources, directUploads: fileConfig.directUploads, observeAsset, resolveUploader: resolveUploader$1 }), $[6] = client, $[7] = fileConfig.directUploads, $[8] = filteredAssetSources, $[9] = observeAsset, $[10] = props2, $[11] = resolveUploader$1, $[12] = t3) : t3 = $[12], t3;
63790
63797
  }
63791
- function _temp$1b(source) {
63798
+ function _temp$1c(source) {
63792
63799
  return source.name === sourceName;
63793
63800
  }
63794
63801
  const VideoField = (props2) => props2.renderDefault({
@@ -64032,12 +64039,12 @@ const VideoField = (props2) => props2.renderDefault({
64032
64039
  function useProjectOrganizationId() {
64033
64040
  const $ = c(2), projectStore = useProjectStore();
64034
64041
  let t0;
64035
- return $[0] !== projectStore ? (t0 = projectStore.getOrganizationId().pipe(map$1(_temp$1a), startWith$1({
64042
+ return $[0] !== projectStore ? (t0 = projectStore.getOrganizationId().pipe(map$1(_temp$1b), startWith$1({
64036
64043
  value: null,
64037
64044
  loading: !0
64038
64045
  })), $[0] = projectStore, $[1] = t0) : t0 = $[1], useObservable(t0, INITIAL_STATE$5);
64039
64046
  }
64040
- function _temp$1a(res) {
64047
+ function _temp$1b(res) {
64041
64048
  return {
64042
64049
  value: res,
64043
64050
  loading: !1
@@ -64194,7 +64201,7 @@ function DocumentDiff(t0) {
64194
64201
  schemaType,
64195
64202
  rootDiff,
64196
64203
  isComparingCurrent: !1,
64197
- FieldWrapper: _temp$19,
64204
+ FieldWrapper: _temp$1a,
64198
64205
  value: document2,
64199
64206
  showFromValue: !0
64200
64207
  }, $[9] = document2, $[10] = rootDiff, $[11] = schemaType, $[12] = t3, $[13] = t4) : t4 = $[13];
@@ -64203,7 +64210,7 @@ function DocumentDiff(t0) {
64203
64210
  let t6;
64204
64211
  return $[17] !== t4 || $[18] !== t5 ? (t6 = /* @__PURE__ */ jsx(DocumentChangeContext.Provider, { value: t4, children: t5 }), $[17] = t4, $[18] = t5, $[19] = t6) : t6 = $[19], t6;
64205
64212
  }
64206
- function _temp$19(props2) {
64213
+ function _temp$1a(props2) {
64207
64214
  return props2.children;
64208
64215
  }
64209
64216
  const ChipCard = styled(Card)((props2) => {
@@ -64523,7 +64530,7 @@ function useLinkToCanvas(t0) {
64523
64530
  }
64524
64531
  return projectStore.getOrganizationId().pipe(map$1((organizationId) => {
64525
64532
  if (!organizationId)
64526
- return _temp$18;
64533
+ return _temp$19;
64527
64534
  const canvasLinkUrl = `https://www.sanity.${client.config().apiHost === "https://api.sanity.work" ? "work" : "io"}/@${organizationId}/canvas/${path}`;
64528
64535
  return () => window.open(canvasLinkUrl, "_blank");
64529
64536
  }));
@@ -64578,7 +64585,7 @@ function _temp2$s(error) {
64578
64585
  error: error.message
64579
64586
  });
64580
64587
  }
64581
- function _temp$18() {
64588
+ function _temp$19() {
64582
64589
  }
64583
64590
  const LinkToCanvasDialog = (t0) => {
64584
64591
  const $ = c(35), {
@@ -65550,7 +65557,7 @@ const EMPTY_ARRAY$f = [], Root$d = styled(Stack)({
65550
65557
  let t72;
65551
65558
  if ($[8] !== options || $[9] !== searchTerm) {
65552
65559
  const deburredSearchTerm = deburr(searchTerm).toLocaleLowerCase();
65553
- t72 = options?.map(_temp$17)?.filter((option_0) => option_0?.displayName?.includes(deburredSearchTerm))?.sort((a, b) => {
65560
+ t72 = options?.map(_temp$18)?.filter((option_0) => option_0?.displayName?.includes(deburredSearchTerm))?.sort((a, b) => {
65554
65561
  const matchA = a.displayName?.startsWith(deburredSearchTerm), matchB = b.displayName?.startsWith(deburredSearchTerm);
65555
65562
  return matchA && !matchB ? -1 : !matchA && matchB ? 1 : 0;
65556
65563
  }), $[8] = options, $[9] = searchTerm, $[10] = t72;
@@ -65574,7 +65581,7 @@ const EMPTY_ARRAY$f = [], Root$d = styled(Stack)({
65574
65581
  t8
65575
65582
  ] }), $[21] = t7, $[22] = t8, $[23] = t9) : t9 = $[23], t9;
65576
65583
  });
65577
- function _temp$17(option) {
65584
+ function _temp$18(option) {
65578
65585
  return {
65579
65586
  ...option,
65580
65587
  displayName: deburr(option.displayName || "").toLocaleLowerCase()
@@ -65982,7 +65989,7 @@ function CommentInputProvider(props2) {
65982
65989
  $[16] !== mentionsMenuOpen || $[17] !== onMentionMenuOpenChange ? (t8 = () => onMentionMenuOpenChange?.(mentionsMenuOpen), $[16] = mentionsMenuOpen, $[17] = onMentionMenuOpenChange, $[18] = t8) : t8 = $[18], useDidUpdate(mentionsMenuOpen, t8);
65983
65990
  let t9;
65984
65991
  $[19] !== editor2 || $[20] !== selectionAtMentionInsert ? (t9 = (userId) => {
65985
- const mentionSchemaType = editor2.schemaTypes.inlineObjects.find(_temp$16), [span, spanPath] = selectionAtMentionInsert && PortableTextEditor.findByPath(editor2, selectionAtMentionInsert.focus.path) || [];
65992
+ const mentionSchemaType = editor2.schemaTypes.inlineObjects.find(_temp$17), [span, spanPath] = selectionAtMentionInsert && PortableTextEditor.findByPath(editor2, selectionAtMentionInsert.focus.path) || [];
65986
65993
  if (span && isPortableTextSpan(span) && spanPath && mentionSchemaType) {
65987
65994
  PortableTextEditor.focus(editor2);
65988
65995
  const offset = PortableTextEditor.getSelection(editor2)?.focus.offset;
@@ -66029,7 +66036,7 @@ function CommentInputProvider(props2) {
66029
66036
  let t12;
66030
66037
  return $[39] !== children || $[40] !== ctxValue ? (t12 = /* @__PURE__ */ jsx(CommentInputContext.Provider, { value: ctxValue, children }), $[39] = children, $[40] = ctxValue, $[41] = t12) : t12 = $[41], t12;
66031
66038
  }
66032
- function _temp$16(t) {
66039
+ function _temp$17(t) {
66033
66040
  return t.name === "mention";
66034
66041
  }
66035
66042
  const EMPTY_ARRAY$d = [], SCROLL_INTO_VIEW_OPTIONS = {
@@ -66517,7 +66524,7 @@ function CommentReactionsUsersTooltipContent(props2) {
66517
66524
  $[9] !== UserList || $[10] !== t4 ? (t5 = {
66518
66525
  UserList,
66519
66526
  ReactionName: t4,
66520
- Text: _temp$15
66527
+ Text: _temp$16
66521
66528
  }, $[9] = UserList, $[10] = t4, $[11] = t5) : t5 = $[11];
66522
66529
  let t6;
66523
66530
  $[12] !== t || $[13] !== t3 || $[14] !== t5 ? (t6 = /* @__PURE__ */ jsx(TextBox, { children: /* @__PURE__ */ jsx(Translate, { t, i18nKey: "reactions.users-reacted-with-reaction", values: t3, components: t5 }) }), $[12] = t, $[13] = t3, $[14] = t5, $[15] = t6) : t6 = $[15];
@@ -66527,7 +66534,7 @@ function CommentReactionsUsersTooltipContent(props2) {
66527
66534
  t6
66528
66535
  ] }), $[16] = t2, $[17] = t6, $[18] = t7) : t7 = $[18], t7;
66529
66536
  }
66530
- function _temp$15(t0) {
66537
+ function _temp$16(t0) {
66531
66538
  const {
66532
66539
  children
66533
66540
  } = t0;
@@ -66573,7 +66580,7 @@ const renderMenuButton$1 = ({
66573
66580
  let t1;
66574
66581
  if ($[2] !== currentUser?.id || $[3] !== reactions) {
66575
66582
  let t22;
66576
- $[5] !== currentUser?.id ? (t22 = (r) => r.userId === currentUser?.id, $[5] = currentUser?.id, $[6] = t22) : t22 = $[6], t1 = reactions.filter(t22).map(_temp$14), $[2] = currentUser?.id, $[3] = reactions, $[4] = t1;
66583
+ $[5] !== currentUser?.id ? (t22 = (r) => r.userId === currentUser?.id, $[5] = currentUser?.id, $[6] = t22) : t22 = $[6], t1 = reactions.filter(t22).map(_temp$15), $[2] = currentUser?.id, $[3] = reactions, $[4] = t1;
66577
66584
  } else
66578
66585
  t1 = $[4];
66579
66586
  const currentUserReactionNames = t1;
@@ -66632,7 +66639,7 @@ const renderMenuButton$1 = ({
66632
66639
  ] }) }), $[38] = t4, $[39] = t6, $[40] = t7) : t7 = $[40], t7;
66633
66640
  });
66634
66641
  CommentReactionsBar.displayName = "Memo(CommentReactionsBar)";
66635
- function _temp$14(r_0) {
66642
+ function _temp$15(r_0) {
66636
66643
  return r_0.shortName;
66637
66644
  }
66638
66645
  function _temp2$r(t0) {
@@ -66876,7 +66883,7 @@ function CommentsListItemLayout(props2) {
66876
66883
  $[0] !== value ? (t2 = hasCommentMessageValue(value), $[0] = value, $[1] = t2) : t2 = $[1];
66877
66884
  const hasValue2 = t2;
66878
66885
  let t3;
66879
- $[2] !== comment.reactions ? (t3 = (comment?.reactions?.filter(_temp$13) || EMPTY_ARRAY$b).filter(_temp2$q), $[2] = comment.reactions, $[3] = t3) : t3 = $[3];
66886
+ $[2] !== comment.reactions ? (t3 = (comment?.reactions?.filter(_temp$14) || EMPTY_ARRAY$b).filter(_temp2$q), $[2] = comment.reactions, $[3] = t3) : t3 = $[3];
66880
66887
  const reactions = t3, hasReactions = !!reactions?.length;
66881
66888
  let t4;
66882
66889
  $[4] !== _createdAt ? (t4 = _createdAt ? new Date(_createdAt) : /* @__PURE__ */ new Date(), $[4] = _createdAt, $[5] = t4) : t4 = $[5];
@@ -67072,7 +67079,7 @@ function _temp3$d(v) {
67072
67079
  function _temp2$q(r_0) {
67073
67080
  return "userId" in r_0 && "shortName" in r_0;
67074
67081
  }
67075
- function _temp$13(r) {
67082
+ function _temp$14(r) {
67076
67083
  return r?._optimisticState !== "removed";
67077
67084
  }
67078
67085
  const ThreadCard = styled(Card).attrs({
@@ -67449,7 +67456,7 @@ function CommentThreadLayout(props2) {
67449
67456
  }, $[6] = fieldPath, $[7] = onPathSelect, $[8] = t2) : t2 = $[8];
67450
67457
  const handleNewThreadClick = t2;
67451
67458
  let t3;
67452
- $[9] !== breadcrumbs ? (t3 = breadcrumbs?.map(_temp$12) || [], $[9] = breadcrumbs, $[10] = t3) : t3 = $[10];
67459
+ $[9] !== breadcrumbs ? (t3 = breadcrumbs?.map(_temp$13) || [], $[9] = breadcrumbs, $[10] = t3) : t3 = $[10];
67453
67460
  const crumbsTitlePath = t3, lastCrumb = crumbsTitlePath[crumbsTitlePath.length - 1];
67454
67461
  let t4;
67455
67462
  $[11] !== lastCrumb || $[12] !== t ? (t4 = t("list-item.breadcrumb-button-go-to-field-aria-label", {
@@ -67470,7 +67477,7 @@ function CommentThreadLayout(props2) {
67470
67477
  t8
67471
67478
  ] }), $[32] = t6, $[33] = t7, $[34] = t8, $[35] = t9) : t9 = $[35], t9;
67472
67479
  }
67473
- function _temp$12(p) {
67480
+ function _temp$13(p) {
67474
67481
  return p.title;
67475
67482
  }
67476
67483
  function groupThreads(comments2) {
@@ -68066,7 +68073,7 @@ function useCommentOperations(opts) {
68066
68073
  createAddonDataset,
68067
68074
  workspace,
68068
68075
  getCommentLink
68069
- } = opts, getIntent = useCommentsIntent(), activeToolName = useRouterState(_temp$11), tools = useTools();
68076
+ } = opts, getIntent = useCommentsIntent(), activeToolName = useRouterState(_temp$12), tools = useTools();
68070
68077
  let t0;
68071
68078
  if ($[0] !== activeToolName || $[1] !== tools) {
68072
68079
  let t12;
@@ -68158,7 +68165,7 @@ function useCommentOperations(opts) {
68158
68165
  operation: t7
68159
68166
  }, $[44] = t7, $[45] = t8) : t8 = $[45], t8;
68160
68167
  }
68161
- function _temp$11(routerState) {
68168
+ function _temp$12(routerState) {
68162
68169
  return typeof routerState.tool == "string" ? routerState.tool : void 0;
68163
68170
  }
68164
68171
  function useComments() {
@@ -68347,7 +68354,7 @@ function useCommentsUpsell() {
68347
68354
  let t0;
68348
68355
  return $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
68349
68356
  upsellData: null,
68350
- handleOpenDialog: _temp$10,
68357
+ handleOpenDialog: _temp$11,
68351
68358
  handleClose: _temp2$p,
68352
68359
  upsellDialogOpen: !1,
68353
68360
  telemetryLogs: {
@@ -68383,7 +68390,7 @@ function _temp3$c() {
68383
68390
  function _temp2$p() {
68384
68391
  return null;
68385
68392
  }
68386
- function _temp$10() {
68393
+ function _temp$11() {
68387
68394
  return null;
68388
68395
  }
68389
68396
  function useResolveCommentsEnabled(documentId, documentType) {
@@ -68658,7 +68665,7 @@ const EMPTY_ARRAY$8 = [], EMPTY_COMMENTS_DATA = {
68658
68665
  }
68659
68666
  t3 = editState2.draft || editState2.published;
68660
68667
  }
68661
- const documentValue = t3, documentRevisionId = documentValue?._rev, [transactionsIdMap] = useState(_temp$$);
68668
+ const documentValue = t3, documentRevisionId = documentValue?._rev, [transactionsIdMap] = useState(_temp$10);
68662
68669
  let t4;
68663
68670
  $[5] !== transactionsIdMap ? (t4 = (commentDocumentId) => {
68664
68671
  transactionsIdMap.delete(commentDocumentId);
@@ -68840,7 +68847,7 @@ const EMPTY_ARRAY$8 = [], EMPTY_COMMENTS_DATA = {
68840
68847
  let t22;
68841
68848
  return $[85] !== children || $[86] !== ctxValue ? (t22 = /* @__PURE__ */ jsx(CommentsContext.Provider, { value: ctxValue, children }), $[85] = children, $[86] = ctxValue, $[87] = t22) : t22 = $[87], t22;
68842
68849
  });
68843
- function _temp$$() {
68850
+ function _temp$10() {
68844
68851
  return /* @__PURE__ */ new Map();
68845
68852
  }
68846
68853
  function _temp2$o(item) {
@@ -69172,7 +69179,7 @@ function CommentFieldInner(props2) {
69172
69179
  let t5;
69173
69180
  if ($[13] !== comments2.data.open || $[14] !== selectedPath?.threadId) {
69174
69181
  let t62;
69175
- $[16] !== selectedPath?.threadId ? (t62 = (c2) => c2.threadId === selectedPath?.threadId, $[16] = selectedPath?.threadId, $[17] = t62) : t62 = $[17], t5 = comments2.data.open.filter(t62).some(_temp$_), $[13] = comments2.data.open, $[14] = selectedPath?.threadId, $[15] = t5;
69182
+ $[16] !== selectedPath?.threadId ? (t62 = (c2) => c2.threadId === selectedPath?.threadId, $[16] = selectedPath?.threadId, $[17] = t62) : t62 = $[17], t5 = comments2.data.open.filter(t62).some(_temp$$), $[13] = comments2.data.open, $[14] = selectedPath?.threadId, $[15] = t5;
69176
69183
  } else
69177
69184
  t5 = $[15];
69178
69185
  const isInlineCommentThread = t5;
@@ -69264,7 +69271,7 @@ function CommentFieldInner(props2) {
69264
69271
  function _temp2$n(acc, val) {
69265
69272
  return acc + val;
69266
69273
  }
69267
- function _temp$_(x) {
69274
+ function _temp$$(x) {
69268
69275
  return isTextSelectionComment(x.parentComment);
69269
69276
  }
69270
69277
  function createDomRectFromElements(elements) {
@@ -69483,7 +69490,7 @@ const CommentsPortableTextInputInner = memo(function(props2) {
69483
69490
  let t5;
69484
69491
  if ($[9] !== comments2.data.open || $[10] !== stringFieldPath) {
69485
69492
  let t62;
69486
- $[12] !== stringFieldPath ? (t62 = (comment) => comment.fieldPath === stringFieldPath, $[12] = stringFieldPath, $[13] = t62) : t62 = $[13], t5 = comments2.data.open.filter(t62).filter(_temp$Z).map(_temp2$m), $[9] = comments2.data.open, $[10] = stringFieldPath, $[11] = t5;
69493
+ $[12] !== stringFieldPath ? (t62 = (comment) => comment.fieldPath === stringFieldPath, $[12] = stringFieldPath, $[13] = t62) : t62 = $[13], t5 = comments2.data.open.filter(t62).filter(_temp$_).map(_temp2$m), $[9] = comments2.data.open, $[10] = stringFieldPath, $[11] = t5;
69487
69494
  } else
69488
69495
  t5 = $[11];
69489
69496
  const textComments = t5;
@@ -69725,7 +69732,7 @@ function useDebounceSelectionChange(handleSelectionChange) {
69725
69732
  function RenderDefaultCommentsPortableTextInputInner(props2) {
69726
69733
  return props2.renderDefault(props2);
69727
69734
  }
69728
- function _temp$Z(c2) {
69735
+ function _temp$_(c2) {
69729
69736
  return isTextSelectionComment(c2.parentComment);
69730
69737
  }
69731
69738
  function _temp2$m(c_0) {
@@ -70069,7 +70076,7 @@ function CommentsInspectorInner(props2) {
70069
70076
  $[17] !== comments2.data.open || $[18] !== onPathOpen || $[19] !== scrollToField || $[20] !== scrollToInlineComment || $[21] !== setSelectedPath ? (t5 = (nextPath) => {
70070
70077
  if (setSelectedPath(nextPath), nextPath?.fieldPath) {
70071
70078
  const path = PathUtils.fromString(nextPath.fieldPath);
70072
- onPathOpen?.(path), scrollToField(nextPath.fieldPath), comments2.data.open.filter((c2) => c2.threadId === nextPath?.threadId).some(_temp$Y) && nextPath.threadId && scrollToInlineComment(nextPath.threadId);
70079
+ onPathOpen?.(path), scrollToField(nextPath.fieldPath), comments2.data.open.filter((c2) => c2.threadId === nextPath?.threadId).some(_temp$Z) && nextPath.threadId && scrollToInlineComment(nextPath.threadId);
70073
70080
  }
70074
70081
  }, $[17] = comments2.data.open, $[18] = onPathOpen, $[19] = scrollToField, $[20] = scrollToInlineComment, $[21] = setSelectedPath, $[22] = t5) : t5 = $[22];
70075
70082
  const handlePathSelect = t5;
@@ -70213,7 +70220,7 @@ function CommentsInspectorInner(props2) {
70213
70220
  t29
70214
70221
  ] }), $[119] = t22, $[120] = t29, $[121] = t30) : t30 = $[121], t30;
70215
70222
  }
70216
- function _temp$Y(x) {
70223
+ function _temp$Z(x) {
70217
70224
  return isTextSelectionComment(x.parentComment);
70218
70225
  }
70219
70226
  function useMenuItem() {
@@ -70534,7 +70541,7 @@ function CreateLinkedDocumentBannerContent(props2) {
70534
70541
  t
70535
70542
  } = useTranslation(createLocaleNamespace);
70536
70543
  let t0;
70537
- $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setInfoOpen(_temp$X), $[0] = t0) : t0 = $[0];
70544
+ $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setInfoOpen(_temp$Y), $[0] = t0) : t0 = $[0];
70538
70545
  const toggleOpen = t0;
70539
70546
  let t1, t2;
70540
70547
  $[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => setInfoOpen(!1), t2 = () => [popoverRef.current, infoButtonRef.current], $[1] = t1, $[2] = t2) : (t1 = $[1], t2 = $[2]), useClickOutsideEvent(t1, t2);
@@ -70617,7 +70624,7 @@ function CreateLinkedDocumentBannerContent(props2) {
70617
70624
  t25
70618
70625
  ] }), $[48] = t19, $[49] = t25, $[50] = t26) : t26 = $[50], t26;
70619
70626
  }
70620
- function _temp$X(current) {
70627
+ function _temp$Y(current) {
70621
70628
  return !current;
70622
70629
  }
70623
70630
  function SanityCreateConfigProvider(props2) {
@@ -71075,7 +71082,7 @@ function useScheduleOperation() {
71075
71082
  schedules: schedules2
71076
71083
  } = t42, displayToast_1 = t52 === void 0 ? !0 : t52;
71077
71084
  await (async () => {
71078
- const scheduleIds = schedules2.map(_temp$W), response = await api.deleteMultiple({
71085
+ const scheduleIds = schedules2.map(_temp$X), response = await api.deleteMultiple({
71079
71086
  scheduleIds
71080
71087
  }), {
71081
71088
  fulfilledIds,
@@ -71186,7 +71193,7 @@ function useScheduleOperation() {
71186
71193
  updateSchedule
71187
71194
  }, $[18] = createSchedule, $[19] = deleteSchedule, $[20] = deleteSchedules, $[21] = publishSchedule, $[22] = updateSchedule, $[23] = t6) : t6 = $[23], t6;
71188
71195
  }
71189
- function _temp$W(schedule_0) {
71196
+ function _temp$X(schedule_0) {
71190
71197
  return schedule_0.id;
71191
71198
  }
71192
71199
  function useScheduleBaseUrl() {
@@ -71332,7 +71339,7 @@ function SchedulesProvider(t0) {
71332
71339
  const scheduleDate = new Date(executeDate), zonedScheduleDate = utcToCurrentZoneDate(scheduleDate);
71333
71340
  return isSameDay(zonedScheduleDate, wallDate);
71334
71341
  }, $[1] = utcToCurrentZoneDate, $[2] = t2) : t2 = $[2];
71335
- const filterByDate = t2, filterByState = _temp$V;
71342
+ const filterByDate = t2, filterByState = _temp$W;
71336
71343
  let t3;
71337
71344
  $[3] !== filterByDate || $[4] !== sortBy2 || $[5] !== value.scheduleState || $[6] !== value.schedules || $[7] !== value.selectedDate ? (t3 = value.schedules.filter((scheduleState_0) => value.selectedDate ? filterByDate(value.selectedDate)(scheduleState_0) : filterByState(value.scheduleState)(scheduleState_0)).sort((a, b) => {
71338
71345
  if (sortBy2 === "createdAt")
@@ -71363,7 +71370,7 @@ function SchedulesProvider(t0) {
71363
71370
  let t7;
71364
71371
  return $[19] !== children || $[20] !== context ? (t7 = /* @__PURE__ */ jsx(SchedulesContext.Provider, { value: context, children }), $[19] = children, $[20] = context, $[21] = t7) : t7 = $[21], t7;
71365
71372
  }
71366
- function _temp$V(scheduleState) {
71373
+ function _temp$W(scheduleState) {
71367
71374
  return function(schedule_0) {
71368
71375
  return schedule_0.state === scheduleState;
71369
71376
  };
@@ -71779,7 +71786,7 @@ function CalendarMonth(props2) {
71779
71786
  let t1, t2;
71780
71787
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = {
71781
71788
  gridTemplateColumns: "repeat(7, minmax(44px, 46px))"
71782
- }, t2 = WEEK_DAY_NAMES.map(_temp$U), $[0] = t1, $[1] = t2) : (t1 = $[0], t2 = $[1]);
71789
+ }, t2 = WEEK_DAY_NAMES.map(_temp$V), $[0] = t1, $[1] = t2) : (t1 = $[0], t2 = $[1]);
71783
71790
  let t3;
71784
71791
  if ($[2] !== customValidation || $[3] !== getCurrentZoneDate || $[4] !== props2.date || $[5] !== props2.focused || $[6] !== props2.onSelect || $[7] !== props2.selected) {
71785
71792
  let t42;
@@ -71797,7 +71804,7 @@ function CalendarMonth(props2) {
71797
71804
  let t5;
71798
71805
  return $[17] !== t0 || $[18] !== t4 ? (t5 = /* @__PURE__ */ jsx(Box, { "aria-hidden": t0, "data-ui": "CalendarMonth", children: t4 }), $[17] = t0, $[18] = t4, $[19] = t5) : t5 = $[19], t5;
71799
71806
  }
71800
- function _temp$U(weekday) {
71807
+ function _temp$V(weekday) {
71801
71808
  return /* @__PURE__ */ jsx(Box, { paddingY: 2, children: /* @__PURE__ */ jsx(Text$1, { size: 1, weight: "medium", style: {
71802
71809
  textAlign: "center"
71803
71810
  }, children: weekday }) }, weekday);
@@ -71942,7 +71949,7 @@ const features = {
71942
71949
  }, children: [
71943
71950
  /* @__PURE__ */ jsxs(Flex, { align: "center", children: [
71944
71951
  /* @__PURE__ */ jsxs(Flex, { align: "center", flex: 1, children: [
71945
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Select, { "aria-label": "Select hour", value: selectedDate?.getHours(), onChange: handleHoursChange, children: HOURS_24.map(_temp$T) }) }),
71952
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Select, { "aria-label": "Select hour", value: selectedDate?.getHours(), onChange: handleHoursChange, children: HOURS_24.map(_temp$U) }) }),
71946
71953
  /* @__PURE__ */ jsx(Box, { paddingX: 1, children: /* @__PURE__ */ jsx(Text$1, { children: ":" }) }),
71947
71954
  /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Select, { "aria-label": "Select minutes", value: selectedDate?.getMinutes(), onChange: handleMinutesChange, children: range(0, 60, timeStep).map(_temp2$l) }) })
71948
71955
  ] }),
@@ -72015,7 +72022,7 @@ function CalendarYearSelect(props2) {
72015
72022
  t5
72016
72023
  ] }), $[12] = t2, $[13] = t4, $[14] = t5, $[15] = t6) : t6 = $[15], t6;
72017
72024
  }
72018
- function _temp$T(h) {
72025
+ function _temp$U(h) {
72019
72026
  return /* @__PURE__ */ jsx("option", { value: h, children: `${h}`.padStart(2, "0") }, h);
72020
72027
  }
72021
72028
  function _temp2$l(m_1) {
@@ -72144,7 +72151,7 @@ const DatePicker = forwardRef(function(props2, ref) {
72144
72151
  $[32] !== deserialize2 || $[33] !== formatInputValue || $[34] !== localValue || $[35] !== parseInputValue || $[36] !== value ? (parseResult = localValue ? parseInputValue(localValue) : value ? deserialize2(value) : null, t5 = localValue || (parseResult?.isValid ? formatInputValue(parseResult.date) : value), $[32] = deserialize2, $[33] = formatInputValue, $[34] = localValue, $[35] = parseInputValue, $[36] = value, $[37] = parseResult, $[38] = t5) : (parseResult = $[37], t5 = $[38]);
72145
72152
  const inputValue = t5;
72146
72153
  let t6;
72147
- $[39] !== markers ? (t6 = markers.map(_temp$S), $[39] = markers, $[40] = t6) : t6 = $[40];
72154
+ $[39] !== markers ? (t6 = markers.map(_temp$T), $[39] = markers, $[40] = t6) : t6 = $[40];
72148
72155
  const nodeValidations = t6;
72149
72156
  let t7;
72150
72157
  $[41] !== nodeValidations || $[42] !== parseResult ? (t7 = parseResult?.error ? [...nodeValidations, {
@@ -72157,7 +72164,7 @@ const DatePicker = forwardRef(function(props2, ref) {
72157
72164
  let t9;
72158
72165
  return $[59] !== description || $[60] !== id2 || $[61] !== level || $[62] !== t7 || $[63] !== t8 || $[64] !== title ? (t9 = /* @__PURE__ */ jsx(FormField, { validation: t7, title, level, description, inputId: id2, children: t8 }), $[59] = description, $[60] = id2, $[61] = level, $[62] = t7, $[63] = t8, $[64] = title, $[65] = t9) : t9 = $[65], t9;
72159
72166
  });
72160
- function _temp$S(m) {
72167
+ function _temp$T(m) {
72161
72168
  return {
72162
72169
  level: m.level,
72163
72170
  path: m.path,
@@ -73330,7 +73337,7 @@ function CalendarDay(props2) {
73330
73337
  isToday2 || selected ? tone = "primary" : (isWeekend(date), tone = "default");
73331
73338
  const hasSchedules = schedules2.length > 0;
73332
73339
  let t2;
73333
- $[7] !== schedules2 ? (t2 = schedules2.filter(_temp$R), $[7] = schedules2, $[8] = t2) : t2 = $[8];
73340
+ $[7] !== schedules2 ? (t2 = schedules2.filter(_temp$S), $[7] = schedules2, $[8] = t2) : t2 = $[8];
73334
73341
  let t3;
73335
73342
  $[9] !== schedules2 ? (t3 = schedules2.filter(_temp2$k), $[9] = schedules2, $[10] = t3) : t3 = $[10];
73336
73343
  let t4;
@@ -73401,7 +73408,7 @@ function _temp3$8(s_1) {
73401
73408
  function _temp2$k(s_0) {
73402
73409
  return s_0.state === "cancelled";
73403
73410
  }
73404
- function _temp$R(s) {
73411
+ function _temp$S(s) {
73405
73412
  return s.state === "succeeded";
73406
73413
  }
73407
73414
  function TooltipContent(props2) {
@@ -73708,9 +73715,9 @@ const Schedules = (props2) => {
73708
73715
  schedules: schedules2
73709
73716
  } = props2;
73710
73717
  let t0;
73711
- return $[0] !== schedules2 ? (t0 = /* @__PURE__ */ jsx(Stack, { space: 4, children: schedules2.length === 0 ? /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$1, { size: 1, children: "No schedules" }) }) : /* @__PURE__ */ jsx(Stack, { space: 2, children: schedules2.map(_temp$Q) }) }), $[0] = schedules2, $[1] = t0) : t0 = $[1], t0;
73718
+ return $[0] !== schedules2 ? (t0 = /* @__PURE__ */ jsx(Stack, { space: 4, children: schedules2.length === 0 ? /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$1, { size: 1, children: "No schedules" }) }) : /* @__PURE__ */ jsx(Stack, { space: 2, children: schedules2.map(_temp$R) }) }), $[0] = schedules2, $[1] = t0) : t0 = $[1], t0;
73712
73719
  };
73713
- function _temp$Q(schedule) {
73720
+ function _temp$R(schedule) {
73714
73721
  return /* @__PURE__ */ jsx(ScheduleItem, { schedule, type: "document" }, schedule.id);
73715
73722
  }
73716
73723
  const debug$6 = debugWithName$1("ScheduleAction"), useScheduleAction = (props2) => {
@@ -73885,7 +73892,7 @@ function ScheduleBanner(props2) {
73885
73892
  ] })
73886
73893
  ] }), $[7] = t5) : t5 = $[7];
73887
73894
  let t6;
73888
- $[8] !== schedules2 ? (t6 = schedules2.map(_temp$P), $[8] = schedules2, $[9] = t6) : t6 = $[9];
73895
+ $[8] !== schedules2 ? (t6 = schedules2.map(_temp$Q), $[8] = schedules2, $[9] = t6) : t6 = $[9];
73889
73896
  let t7;
73890
73897
  $[10] !== t6 ? (t7 = /* @__PURE__ */ jsx(Stack, { space: 2, children: t6 }), $[10] = t6, $[11] = t7) : t7 = $[11];
73891
73898
  let t8;
@@ -73904,7 +73911,7 @@ function ScheduleBanner(props2) {
73904
73911
  t10
73905
73912
  ] }), $[21] = t1, $[22] = t10, $[23] = t11) : t11 = $[23], t11;
73906
73913
  }
73907
- function _temp$P(schedule) {
73914
+ function _temp$Q(schedule) {
73908
73915
  if (!schedule.executeAt)
73909
73916
  return null;
73910
73917
  const formattedDateTime = format(new Date(schedule.executeAt), DATE_FORMAT.LARGE);
@@ -73922,7 +73929,7 @@ function ScheduledDocumentInput(props2) {
73922
73929
  children
73923
73930
  } = props2, doc = value;
73924
73931
  let t0;
73925
- $[0] !== validation2 ? (t0 = validation2.map(_temp$O), $[0] = validation2, $[1] = t0) : t0 = $[1];
73932
+ $[0] !== validation2 ? (t0 = validation2.map(_temp$P), $[0] = validation2, $[1] = t0) : t0 = $[1];
73926
73933
  const markers = t0;
73927
73934
  let t1;
73928
73935
  $[2] !== doc || $[3] !== markers ? (t1 = doc?._id ? /* @__PURE__ */ jsx(ScheduleBanner, { id: doc._id, markers }) : null, $[2] = doc, $[3] = markers, $[4] = t1) : t1 = $[4];
@@ -73932,7 +73939,7 @@ function ScheduledDocumentInput(props2) {
73932
73939
  children
73933
73940
  ] }), $[5] = children, $[6] = t1, $[7] = t2) : t2 = $[7], t2;
73934
73941
  }
73935
- function _temp$O(v) {
73942
+ function _temp$P(v) {
73936
73943
  return {
73937
73944
  level: v.level,
73938
73945
  path: v.path,
@@ -74501,14 +74508,14 @@ function useTasks() {
74501
74508
  let t0;
74502
74509
  return $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
74503
74510
  activeDocument: null,
74504
- setActiveDocument: _temp$N,
74511
+ setActiveDocument: _temp$O,
74505
74512
  data: [],
74506
74513
  isLoading: !1
74507
74514
  }, $[0] = t0) : t0 = $[0], t0;
74508
74515
  }
74509
74516
  return context;
74510
74517
  }
74511
- function _temp$N() {
74518
+ function _temp$O() {
74512
74519
  return null;
74513
74520
  }
74514
74521
  function TasksUpsellProvider(props2) {
@@ -74870,7 +74877,7 @@ function useRemoveTask(t0) {
74870
74877
  let t1;
74871
74878
  $[0] !== id2 || $[1] !== onError || $[2] !== onRemoved || $[3] !== operations ? (t1 = async () => {
74872
74879
  const run = async () => {
74873
- setRemoveStatus("loading"), await operations.remove(id2), onRemoved?.(), setRemoveStatus("idle"), await new Promise(_temp$M), setShowDialog(!1);
74880
+ setRemoveStatus("loading"), await operations.remove(id2), onRemoved?.(), setRemoveStatus("idle"), await new Promise(_temp$N), setShowDialog(!1);
74874
74881
  };
74875
74882
  try {
74876
74883
  await run();
@@ -74901,7 +74908,7 @@ function useRemoveTask(t0) {
74901
74908
  handleCloseDialog
74902
74909
  }, $[7] = error, $[8] = handleRemove, $[9] = removeStatus, $[10] = showDialog, $[11] = t4) : t4 = $[11], t4;
74903
74910
  }
74904
- function _temp$M(resolve) {
74911
+ function _temp$N(resolve) {
74905
74912
  return setTimeout(resolve, 300);
74906
74913
  }
74907
74914
  const DATE_FORMAT_OPTIONS$1 = {
@@ -75311,11 +75318,11 @@ function TasksSubscriberAvatars(props2) {
75311
75318
  $[0] !== subscriberIdsProp ? (t0 = subscriberIdsProp?.filter(Boolean) || EMPTY_ARRAY$4, $[0] = subscriberIdsProp, $[1] = t0) : t0 = $[1];
75312
75319
  const subscriberIds = t0;
75313
75320
  let t1;
75314
- $[2] !== subscriberIds ? (t1 = subscriberIds.map(_temp$L), $[2] = subscriberIds, $[3] = t1) : t1 = $[3];
75321
+ $[2] !== subscriberIds ? (t1 = subscriberIds.map(_temp$M), $[2] = subscriberIds, $[3] = t1) : t1 = $[3];
75315
75322
  let t2;
75316
75323
  return $[4] !== t1 ? (t2 = /* @__PURE__ */ jsx(AnimatePresence, { initial: !1, children: /* @__PURE__ */ jsx(AvatarStack, { maxLength: 3, size: 0, children: t1 }) }), $[4] = t1, $[5] = t2) : t2 = $[5], t2;
75317
75324
  }
75318
- function _temp$L(subscriberId) {
75325
+ function _temp$M(subscriberId) {
75319
75326
  return /* @__PURE__ */ jsx(motion.div, { exit: {
75320
75327
  opacity: 0,
75321
75328
  x: "2px",
@@ -75461,7 +75468,7 @@ function TasksActivityLog(props2) {
75461
75468
  const handleCommentEdit = t10;
75462
75469
  let t11;
75463
75470
  if ($[30] !== activityData || $[31] !== taskComments) {
75464
- const taskActivity = activityData.map(_temp$K), commentsActivity = taskComments.map(_temp2$j);
75471
+ const taskActivity = activityData.map(_temp$L), commentsActivity = taskComments.map(_temp2$j);
75465
75472
  t11 = taskActivity.concat(commentsActivity).sort(_temp3$7), $[30] = activityData, $[31] = taskComments, $[32] = t11;
75466
75473
  } else
75467
75474
  t11 = $[32];
@@ -75522,7 +75529,7 @@ function _temp2$j(comment_0) {
75522
75529
  timestamp: comment_0.parentComment._createdAt
75523
75530
  };
75524
75531
  }
75525
- function _temp$K(item) {
75532
+ function _temp$L(item) {
75526
75533
  return {
75527
75534
  _type: "activity",
75528
75535
  payload: item,
@@ -75594,7 +75601,7 @@ function MentionsMenu(t0) {
75594
75601
  let t62;
75595
75602
  if ($[6] !== options || $[7] !== searchTerm) {
75596
75603
  const deburredSearchTerm = deburr(searchTerm).toLocaleLowerCase();
75597
- t62 = options?.map(_temp$J)?.filter((option_0) => option_0?.searchName.includes(deburredSearchTerm))?.sort((a, b) => {
75604
+ t62 = options?.map(_temp$K)?.filter((option_0) => option_0?.searchName.includes(deburredSearchTerm))?.sort((a, b) => {
75598
75605
  const matchA = a.searchName.startsWith(deburredSearchTerm), matchB = b.searchName.startsWith(deburredSearchTerm);
75599
75606
  return matchA && !matchB ? -1 : !matchA && matchB ? 1 : 0;
75600
75607
  }), $[6] = options, $[7] = searchTerm, $[8] = t62;
@@ -75637,7 +75644,7 @@ function MentionsMenu(t0) {
75637
75644
  t11
75638
75645
  ] }), $[26] = t11, $[27] = t9, $[28] = t12) : t12 = $[28], t12;
75639
75646
  }
75640
- function _temp$J(option) {
75647
+ function _temp$K(option) {
75641
75648
  return {
75642
75649
  ...option,
75643
75650
  searchName: deburr(option.displayName || "").toLocaleLowerCase()
@@ -75852,7 +75859,7 @@ function DateEditFormField(props2) {
75852
75859
  }, $[12] = t3) : t3 = $[12];
75853
75860
  const handleKeyUp = t3;
75854
75861
  let t4;
75855
- $[13] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t4 = () => setPickerOpen(_temp$I), $[13] = t4) : t4 = $[13];
75862
+ $[13] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t4 = () => setPickerOpen(_temp$J), $[13] = t4) : t4 = $[13];
75856
75863
  const handleClick = t4;
75857
75864
  let t5;
75858
75865
  $[14] !== coreT ? (t5 = getCalendarLabels(coreT), $[14] = coreT, $[15] = t5) : t5 = $[15];
@@ -75895,7 +75902,7 @@ function DateEditFormField(props2) {
75895
75902
  let t16;
75896
75903
  return $[45] !== pickerOpen || $[46] !== t10 || $[47] !== t15 ? (t16 = /* @__PURE__ */ jsx(Popover, { constrainSize: !0, "data-testid": "date-input-dialog", portal: !0, ref: popoverRef, content: t10, open: pickerOpen, placement: "bottom", fallbackPlacements: t11, children: t15 }), $[45] = pickerOpen, $[46] = t10, $[47] = t15, $[48] = t16) : t16 = $[48], t16;
75897
75904
  }
75898
- function _temp$I(p) {
75905
+ function _temp$J(p) {
75899
75906
  return !p;
75900
75907
  }
75901
75908
  const NormalText = styled(Text$1)`
@@ -75973,11 +75980,11 @@ function DescriptionInput(props2) {
75973
75980
  let t7;
75974
75981
  $[11] !== t ? (t7 = t("form.input.description.placeholder"), $[11] = t, $[12] = t7) : t7 = $[12];
75975
75982
  let t8;
75976
- $[13] !== currentUser || $[14] !== handleChange || $[15] !== mentionOptions || $[16] !== t6 || $[17] !== t7 ? (t8 = /* @__PURE__ */ jsx(CommentInput, { expandOnFocus: !1, currentUser, mentionOptions, onChange: handleChange, value: t6, withAvatar: !1, placeholder: t7, onDiscardConfirm: _temp$H, renderBlock }), $[13] = currentUser, $[14] = handleChange, $[15] = mentionOptions, $[16] = t6, $[17] = t7, $[18] = t8) : t8 = $[18];
75983
+ $[13] !== currentUser || $[14] !== handleChange || $[15] !== mentionOptions || $[16] !== t6 || $[17] !== t7 ? (t8 = /* @__PURE__ */ jsx(CommentInput, { expandOnFocus: !1, currentUser, mentionOptions, onChange: handleChange, value: t6, withAvatar: !1, placeholder: t7, onDiscardConfirm: _temp$I, renderBlock }), $[13] = currentUser, $[14] = handleChange, $[15] = mentionOptions, $[16] = t6, $[17] = t7, $[18] = t8) : t8 = $[18];
75977
75984
  let t9;
75978
75985
  return $[19] !== mode || $[20] !== t8 || $[21] !== textBoxScrollHeight ? (t9 = /* @__PURE__ */ jsx(DescriptionInputRoot, { $mode: mode, ref: handleSetRootRef, $minHeight: textBoxScrollHeight, children: t8 }), $[19] = mode, $[20] = t8, $[21] = textBoxScrollHeight, $[22] = t9) : t9 = $[22], t9;
75979
75986
  }
75980
- function _temp$H() {
75987
+ function _temp$I() {
75981
75988
  return null;
75982
75989
  }
75983
75990
  const FieldWrapperRoot = styled.div((props2) => {
@@ -76324,7 +76331,7 @@ function FormCreate(props2) {
76324
76331
  setActiveTab
76325
76332
  } = useTasksNavigation(), toast = useToast(), telemetry = useTelemetry(), [createMore, setCreateMore] = useState(!1);
76326
76333
  let t0;
76327
- $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setCreateMore(_temp$G), $[0] = t0) : t0 = $[0];
76334
+ $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setCreateMore(_temp$H), $[0] = t0) : t0 = $[0];
76328
76335
  const handleCreateMore = t0, value = props2.value;
76329
76336
  let t1;
76330
76337
  $[1] !== setViewMode ? (t1 = () => {
@@ -76435,7 +76442,7 @@ function FormCreate(props2) {
76435
76442
  t20
76436
76443
  ] }), $[64] = t12, $[65] = t20, $[66] = t21) : t21 = $[66], t21;
76437
76444
  }
76438
- function _temp$G(p) {
76445
+ function _temp$H(p) {
76439
76446
  return !p;
76440
76447
  }
76441
76448
  function RemoveTaskDialog(props2) {
@@ -76565,7 +76572,7 @@ function FormActionsMenu(t0) {
76565
76572
  function FormEditInner(props2) {
76566
76573
  const $ = c(52);
76567
76574
  let t0;
76568
- $[0] !== props2.schemaType.fields ? (t0 = props2.schemaType.fields.find(_temp$F), $[0] = props2.schemaType.fields, $[1] = t0) : t0 = $[1];
76575
+ $[0] !== props2.schemaType.fields ? (t0 = props2.schemaType.fields.find(_temp$G), $[0] = props2.schemaType.fields, $[1] = t0) : t0 = $[1];
76569
76576
  const statusField = t0, value = props2.value, currentUser = useCurrentUser(), {
76570
76577
  t
76571
76578
  } = useTranslation(tasksLocaleNamespace), activityData = useActivityLog(value).changes;
@@ -76633,7 +76640,7 @@ function FormEditInner(props2) {
76633
76640
  t22
76634
76641
  ] }), $[47] = t18, $[48] = t19, $[49] = t22, $[50] = t8, $[51] = t23) : t23 = $[51], t23;
76635
76642
  }
76636
- function _temp$F(f) {
76643
+ function _temp$G(f) {
76637
76644
  return f.name === "status";
76638
76645
  }
76639
76646
  function FormEdit(props2) {
@@ -76685,7 +76692,7 @@ function TasksNotificationTargetInner(props2) {
76685
76692
  inputProps
76686
76693
  } = props2, {
76687
76694
  onChange
76688
- } = inputProps, activeToolName = useRouterState(_temp$E);
76695
+ } = inputProps, activeToolName = useRouterState(_temp$F);
76689
76696
  let t0;
76690
76697
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = [], $[0] = t0) : t0 = $[0];
76691
76698
  const {
@@ -76735,7 +76742,7 @@ function TasksNotificationTargetInner(props2) {
76735
76742
  let t7;
76736
76743
  return $[29] !== _rev || $[30] !== context || $[31] !== documentId || $[32] !== documentType || $[33] !== notificationTarget || $[34] !== onChange || $[35] !== previewValuesLoading ? (t7 = [_rev, context, documentId, documentType, notificationTarget, previewValuesLoading, onChange], $[29] = _rev, $[30] = context, $[31] = documentId, $[32] = documentType, $[33] = notificationTarget, $[34] = onChange, $[35] = previewValuesLoading, $[36] = t7) : t7 = $[36], useEffect(t6, t7), null;
76737
76744
  }
76738
- function _temp$E(routerState) {
76745
+ function _temp$F(routerState) {
76739
76746
  return typeof routerState.tool == "string" ? routerState.tool : void 0;
76740
76747
  }
76741
76748
  function TasksNotificationTarget(props2) {
@@ -76973,7 +76980,7 @@ const VARIANTS = {
76973
76980
  const $ = c(25), {
76974
76981
  documentId,
76975
76982
  initialValue
76976
- } = t0, [patchChannel] = useState(_temp$D);
76983
+ } = t0, [patchChannel] = useState(_temp$E);
76977
76984
  let t1;
76978
76985
  $[0] !== initialValue ? (t1 = initialValue ? {
76979
76986
  loading: !1,
@@ -77086,7 +77093,7 @@ function TasksFormBuilder() {
77086
77093
  let t4;
77087
77094
  return $[20] !== t2 || $[21] !== t3 ? (t4 = /* @__PURE__ */ jsx(MentionUserProvider, { children: /* @__PURE__ */ jsx(TasksAddonWorkspaceProvider, { mode: t2, children: t3 }) }), $[20] = t2, $[21] = t3, $[22] = t4) : t4 = $[22], t4;
77088
77095
  }
77089
- function _temp$D() {
77096
+ function _temp$E() {
77090
77097
  return createPatchChannel();
77091
77098
  }
77092
77099
  const HEADING_BY_STATUS = {
@@ -77445,7 +77452,7 @@ function TasksList(props2) {
77445
77452
  onTaskSelect
77446
77453
  } = props2, items = t0 === void 0 ? EMPTY_ARRAY$2 : t0;
77447
77454
  let t1;
77448
- $[0] !== items ? (t1 = items.reduce(_temp$C, {}), $[0] = items, $[1] = t1) : t1 = $[1];
77455
+ $[0] !== items ? (t1 = items.reduce(_temp$D, {}), $[0] = items, $[1] = t1) : t1 = $[1];
77449
77456
  const tasksByStatus = t1, hasOpenTasks = tasksByStatus.open?.length > 0, hasClosedTasks = tasksByStatus.closed?.length > 0;
77450
77457
  let t2;
77451
77458
  return $[2] !== hasClosedTasks || $[3] !== hasOpenTasks || $[4] !== onTaskSelect || $[5] !== tasksByStatus.closed || $[6] !== tasksByStatus.open ? (t2 = /* @__PURE__ */ jsx(Stack, { space: 4, flex: 1, children: !hasOpenTasks && !hasClosedTasks ? /* @__PURE__ */ jsx(EmptyTasksListState, {}) : /* @__PURE__ */ jsxs(Fragment$1, { children: [
@@ -77453,7 +77460,7 @@ function TasksList(props2) {
77453
77460
  /* @__PURE__ */ jsx(TaskList, { status: "closed", tasks: tasksByStatus.closed, onTaskSelect })
77454
77461
  ] }) }), $[2] = hasClosedTasks, $[3] = hasOpenTasks, $[4] = onTaskSelect, $[5] = tasksByStatus.closed, $[6] = tasksByStatus.open, $[7] = t2) : t2 = $[7], t2;
77455
77462
  }
77456
- function _temp$C(acc, task) {
77463
+ function _temp$D(acc, task) {
77457
77464
  return acc[task.status] || (acc[task.status] = []), acc[task.status].push(task), acc;
77458
77465
  }
77459
77466
  function TasksUpsellPanel() {
@@ -77561,7 +77568,7 @@ function TasksActiveTabNavigation(props2) {
77561
77568
  } = state;
77562
77569
  let items, t0;
77563
77570
  if ($[0] !== allItems || $[1] !== selectedTask) {
77564
- items = allItems.filter(_temp$B);
77571
+ items = allItems.filter(_temp$C);
77565
77572
  let t15;
77566
77573
  $[4] !== selectedTask ? (t15 = (item) => item._id === selectedTask, $[4] = selectedTask, $[5] = t15) : t15 = $[5], t0 = items.findIndex(t15), $[0] = allItems, $[1] = selectedTask, $[2] = items, $[3] = t0;
77567
77574
  } else
@@ -77626,7 +77633,7 @@ function TasksActiveTabNavigation(props2) {
77626
77633
  t13
77627
77634
  ] }) }), $[37] = t12, $[38] = t5, $[39] = t9, $[40] = t14) : t14 = $[40], t14;
77628
77635
  }
77629
- function _temp$B(t) {
77636
+ function _temp$C(t) {
77630
77637
  return t.status === "open";
77631
77638
  }
77632
77639
  const MENU_BUTTON_POPOVER_PROPS = {
@@ -78113,19 +78120,17 @@ class SchemaError extends Error {
78113
78120
  super("SchemaError"), this.schema = schema2, this.name = "SchemaError";
78114
78121
  }
78115
78122
  }
78116
- const debug$4 = debug$c("sanity:config"), TOGGLE$1 = "toggle.schema.upload-pause";
78123
+ const debug$4 = debug$c("sanity:config"), DISABLE_TOGGLE$1 = "toggle.schema.upload-pause.disable";
78117
78124
  async function isEnabled$1(client) {
78118
- if (typeof process < "u" && process?.env?.SANITY_STUDIO_SCHEMA_DESCRIPTOR)
78119
- return !0;
78120
78125
  const {
78121
78126
  projectId
78122
78127
  } = client.config();
78123
78128
  return projectId ? firstValueFrom(getFeatures({
78124
78129
  projectId,
78125
78130
  versionedClient: client
78126
- })).then((features2) => features2.includes(TOGGLE$1)).catch((err) => (debug$4("Fetching features failed. NOT sending schema to server.", {
78131
+ })).then((features2) => !features2.includes(DISABLE_TOGGLE$1)).catch((err) => (debug$4("Fetching features failed. Sending schema to server.", {
78127
78132
  err
78128
- }), !1)) : !1;
78133
+ }), !0)) : !1;
78129
78134
  }
78130
78135
  const MAX_SYNC_ITERATIONS = 5;
78131
78136
  async function uploadSchema(schema2, client) {
@@ -78991,12 +78996,12 @@ function useSyncPathnameWithWorkspace(history2, _workspaces) {
78991
78996
  getSnapshot: t3,
78992
78997
  getServerSnapshot: t4,
78993
78998
  selector: t5,
78994
- isEqual: _temp$A
78999
+ isEqual: _temp$B
78995
79000
  }, $[13] = t2, $[14] = t3, $[15] = t4, $[16] = t5, $[17] = t6) : t6 = $[17];
78996
79001
  const store = t6;
78997
79002
  return useSyncExternalStoreWithSelector(store.subscribe, store.getSnapshot, store.getServerSnapshot, store.selector, store.isEqual);
78998
79003
  }
78999
- function _temp$A(a, b) {
79004
+ function _temp$B(a, b) {
79000
79005
  if (a.type !== b.type)
79001
79006
  return !1;
79002
79007
  switch (a.type) {
@@ -79105,7 +79110,7 @@ function ColorSchemeLocalStorageProvider(t0) {
79105
79110
  const $ = c(10), {
79106
79111
  children,
79107
79112
  onSchemeChange
79108
- } = t0, scheme = useSyncExternalStore(subscribe, getSnapshot, _temp$z);
79113
+ } = t0, scheme = useSyncExternalStore(subscribe, getSnapshot, _temp$A);
79109
79114
  let t1, t2;
79110
79115
  $[0] !== onSchemeChange || $[1] !== scheme ? (t1 = () => {
79111
79116
  typeof onSchemeChange == "function" && onSchemeChange(scheme), localStorage.setItem(LOCAL_STORAGE_KEY, scheme);
@@ -79115,7 +79120,7 @@ function ColorSchemeLocalStorageProvider(t0) {
79115
79120
  let t4;
79116
79121
  return $[7] !== scheme || $[8] !== t3 ? (t4 = /* @__PURE__ */ jsx(ColorSchemeSetValueContext.Provider, { value: setSnapshot, children: /* @__PURE__ */ jsx(ColorSchemeValueContext.Provider, { value: scheme, children: t3 }) }), $[7] = scheme, $[8] = t3, $[9] = t4) : t4 = $[9], t4;
79117
79122
  }
79118
- function _temp$z() {
79123
+ function _temp$A() {
79119
79124
  return "system";
79120
79125
  }
79121
79126
  function ColorSchemeCustomProvider(t0) {
@@ -79331,7 +79336,7 @@ function ReleasesToolLink() {
79331
79336
  t
79332
79337
  } = useTranslation(), {
79333
79338
  errorCount$
79334
- } = useReleasesStore(), hasError = useObservable(errorCount$) !== 0, activeToolName = useRouterState(_temp$y);
79339
+ } = useReleasesStore(), hasError = useObservable(errorCount$) !== 0, activeToolName = useRouterState(_temp$z);
79335
79340
  let t0;
79336
79341
  $[0] !== t ? (t0 = t("release.navbar.tooltip"), $[0] = t, $[1] = t0) : t0 = $[1];
79337
79342
  const t1 = activeToolName === SCHEDULES_TOOL_NAME;
@@ -79344,7 +79349,7 @@ function ReleasesToolLink() {
79344
79349
  let t4;
79345
79350
  return $[7] !== t0 || $[8] !== t3 ? (t4 = /* @__PURE__ */ jsx(Tooltip, { content: t0, children: t3 }), $[7] = t0, $[8] = t3, $[9] = t4) : t4 = $[9], t4;
79346
79351
  }
79347
- function _temp$y(routerState) {
79352
+ function _temp$z(routerState) {
79348
79353
  return typeof routerState.tool == "string" ? routerState.tool : void 0;
79349
79354
  }
79350
79355
  const OversizedButton$1 = styled(IntentLink)`
@@ -79804,7 +79809,7 @@ function ReleasesList(t0) {
79804
79809
  selectedPerspectiveName
79805
79810
  } = usePerspective();
79806
79811
  let t1;
79807
- $[0] !== allReleases ? (t1 = allReleases.filter(_temp$x), $[0] = allReleases, $[1] = t1) : t1 = $[1];
79812
+ $[0] !== allReleases ? (t1 = allReleases.filter(_temp$y), $[0] = allReleases, $[1] = t1) : t1 = $[1];
79808
79813
  const releases2 = t1, {
79809
79814
  document: t2
79810
79815
  } = useWorkspace(), {
@@ -79888,7 +79893,7 @@ function ReleasesList(t0) {
79888
79893
  t14
79889
79894
  ] }), $[50] = t13, $[51] = t14, $[52] = t15) : t15 = $[52], t15;
79890
79895
  }
79891
- function _temp$x(release) {
79896
+ function _temp$y(release) {
79892
79897
  return !isCardinalityOneRelease(release);
79893
79898
  }
79894
79899
  function isElementVisibleInContainer(container, element) {
@@ -80584,7 +80589,7 @@ function Layout(props2) {
80584
80589
  let t7;
80585
80590
  $[15] !== prefersDark ? (t7 = /* @__PURE__ */ jsx(Text$1, { size: 3, children: /* @__PURE__ */ jsx(SanityLogo, { dark: prefersDark }) }), $[15] = prefersDark, $[16] = t7) : t7 = $[16];
80586
80591
  let t8;
80587
- $[17] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t8 = /* @__PURE__ */ jsx(Flex, { align: "center", gap: 2, children: LINKS.map(_temp$w) }), $[17] = t8) : t8 = $[17];
80592
+ $[17] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t8 = /* @__PURE__ */ jsx(Flex, { align: "center", gap: 2, children: LINKS.map(_temp$x) }), $[17] = t8) : t8 = $[17];
80588
80593
  let t9;
80589
80594
  $[18] !== t7 ? (t9 = /* @__PURE__ */ jsxs(Flex, { direction: "column", gap: 4, justify: "center", align: "center", paddingBottom: 4, children: [
80590
80595
  t7,
@@ -80596,7 +80601,7 @@ function Layout(props2) {
80596
80601
  t9
80597
80602
  ] }), $[20] = t6, $[21] = t9, $[22] = t10) : t10 = $[22], t10;
80598
80603
  }
80599
- function _temp$w(link, index) {
80604
+ function _temp$x(link, index) {
80600
80605
  return /* @__PURE__ */ jsxs(Fragment, { children: [
80601
80606
  /* @__PURE__ */ jsx(StyledText, { muted: !0, size: 1, children: /* @__PURE__ */ jsx("a", { href: link.url, target: "_blank", rel: "noopener noreferrer", children: link.title }) }),
80602
80607
  index < LINKS.length - 1 && /* @__PURE__ */ jsx(Text$1, { size: 1, muted: !0, children: "\u2022" })
@@ -80685,9 +80690,9 @@ function _temp3$5(grants) {
80685
80690
  return !!grants[PERMISSION_NAME]?.some(_temp2$g);
80686
80691
  }
80687
80692
  function _temp2$g(p) {
80688
- return p.grants.some(_temp$v);
80693
+ return p.grants.some(_temp$w);
80689
80694
  }
80690
- function _temp$v(g) {
80695
+ function _temp$w(g) {
80691
80696
  return g.name === GRANT_NAME;
80692
80697
  }
80693
80698
  function ManageMenu$1(t0) {
@@ -80899,12 +80904,12 @@ function CorsOriginErrorScreen(props2) {
80899
80904
  ] }) }) }) }), $[25] = t10, $[26] = t12) : t12 = $[26], t12;
80900
80905
  }
80901
80906
  function _temp2$f() {
80902
- const handleFocus = _temp$u;
80907
+ const handleFocus = _temp$v;
80903
80908
  return window.addEventListener("focus", handleFocus), () => {
80904
80909
  window.removeEventListener("focus", handleFocus);
80905
80910
  };
80906
80911
  }
80907
- function _temp$u() {
80912
+ function _temp$v() {
80908
80913
  window.location.reload();
80909
80914
  }
80910
80915
  function NotAuthenticatedScreen() {
@@ -81015,7 +81020,7 @@ function RequestAccessScreen() {
81015
81020
  let t3, t4;
81016
81021
  $[6] !== client || $[7] !== projectId ? (t3 = () => {
81017
81022
  if (!client || !projectId)
81018
- return _temp$t;
81023
+ return _temp$u;
81019
81024
  const request$ = client.observable.request({
81020
81025
  url: "/access/requests/me",
81021
81026
  tag: "request-access"
@@ -81138,7 +81143,7 @@ function _temp3$4(request_1) {
81138
81143
  function _temp2$e(request_0) {
81139
81144
  return request_0.status === "declined";
81140
81145
  }
81141
- function _temp$t() {
81146
+ function _temp$u() {
81142
81147
  }
81143
81148
  function useCopyToClipboard() {
81144
81149
  const $ = c(3), [copiedText, setCopiedText] = useState(null);
@@ -81253,14 +81258,14 @@ function _temp2$d(t0, i) {
81253
81258
  '"'
81254
81259
  ] }) : null }) })
81255
81260
  ] }),
81256
- /* @__PURE__ */ jsx(Box, { marginTop: 4, children: /* @__PURE__ */ jsx(Card, { border: !0, overflow: "auto", padding: 2, tone: "inherit", children: /* @__PURE__ */ jsx(Breadcrumbs, { separator: /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, children: "\u2192" }), children: group2.path.map(_temp$s) }) }) }),
81261
+ /* @__PURE__ */ jsx(Box, { marginTop: 4, children: /* @__PURE__ */ jsx(Card, { border: !0, overflow: "auto", padding: 2, tone: "inherit", children: /* @__PURE__ */ jsx(Breadcrumbs, { separator: /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, children: "\u2192" }), children: group2.path.map(_temp$t) }) }) }),
81257
81262
  /* @__PURE__ */ jsx(Box, { as: "ul", marginTop: 4, children: /* @__PURE__ */ jsx(Box, { as: "li", children: /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
81258
81263
  /* @__PURE__ */ jsx(ErrorMessageText, { muted: !0, size: 1, children: problem_0.message }),
81259
81264
  problem_0.helpId && /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, children: /* @__PURE__ */ jsx("a", { href: generateHelpUrl(problem_0.helpId), target: "_blank", rel: "noopener noreferrer", children: "View documentation \u2192" }) })
81260
81265
  ] }) }) })
81261
81266
  ] }, i);
81262
81267
  }
81263
- function _temp$s(segment, j) {
81268
+ function _temp$t(segment, j) {
81264
81269
  if (segment.kind === "type") {
81265
81270
  const text = `${_renderSegmentName(segment.name || `<anonymous ${segment.type}>`)}:${segment.type}`;
81266
81271
  return /* @__PURE__ */ jsx(Text$1, { title: text, size: 1, textOverflow: "ellipsis", children: /* @__PURE__ */ jsx(SegmentSpan, { children: text }) }, j);
@@ -81327,9 +81332,9 @@ function SchemaErrorsScreen(t0) {
81327
81332
  ] }) }) }), $[26] = t10, $[27] = t11, $[28] = t12) : t12 = $[28], t12;
81328
81333
  }
81329
81334
  function _temp2$c(group2) {
81330
- return group2.problems.some(_temp$r);
81335
+ return group2.problems.some(_temp$s);
81331
81336
  }
81332
- function _temp$r(problem) {
81337
+ function _temp$s(problem) {
81333
81338
  return problem.severity === "error";
81334
81339
  }
81335
81340
  const View$1 = styled(Box)`
@@ -81389,7 +81394,7 @@ function ImportErrorScreen(props2) {
81389
81394
  autoReload
81390
81395
  } = props2;
81391
81396
  let t0;
81392
- $[0] !== autoReload ? (t0 = autoReload ? timer(0, 1e3).pipe(take(COUNTDOWN_SECONDS + 1), map(_temp$q)) : of(0), $[0] = autoReload, $[1] = t0) : t0 = $[1];
81397
+ $[0] !== autoReload ? (t0 = autoReload ? timer(0, 1e3).pipe(take(COUNTDOWN_SECONDS + 1), map(_temp$r)) : of(0), $[0] = autoReload, $[1] = t0) : t0 = $[1];
81393
81398
  const countdownSeconds = useObservable(t0, COUNTDOWN_SECONDS);
81394
81399
  let t1, t2;
81395
81400
  $[2] !== autoReload || $[3] !== countdownSeconds ? (t1 = () => {
@@ -81426,7 +81431,7 @@ function ImportErrorScreen(props2) {
81426
81431
  t9
81427
81432
  ] }) }) }) }) }), $[17] = t6, $[18] = t7, $[19] = t9, $[20] = t10) : t10 = $[20], t10;
81428
81433
  }
81429
- function _temp$q(seconds) {
81434
+ function _temp$r(seconds) {
81430
81435
  return COUNTDOWN_SECONDS - seconds;
81431
81436
  }
81432
81437
  const DevServerStoppedErrorScreen = lazy(() => import("./_chunks-es/ViteDevServerStopped.js").then((DevServerStopped) => ({
@@ -81515,7 +81520,7 @@ function StudioLayoutComponent() {
81515
81520
  useNetworkProtocolCheck();
81516
81521
  let t0;
81517
81522
  $[0] !== tools ? (t0 = tools.filter(isDefaultRouteTool), $[0] = tools, $[1] = t0) : t0 = $[1];
81518
- const defaultRouteTools = t0, router = useRouter(), activeToolName = useRouterState(_temp$p);
81523
+ const defaultRouteTools = t0, router = useRouter(), activeToolName = useRouterState(_temp$q);
81519
81524
  let t1;
81520
81525
  if ($[2] !== activeToolName || $[3] !== tools) {
81521
81526
  let t24;
@@ -81609,7 +81614,7 @@ function _temp3$3(error) {
81609
81614
  function _temp2$b(tool_0) {
81610
81615
  return tool_0.name === "structure";
81611
81616
  }
81612
- function _temp$p(routerState) {
81617
+ function _temp$q(routerState) {
81613
81618
  return typeof routerState.tool == "string" ? routerState.tool : void 0;
81614
81619
  }
81615
81620
  function pickToolMenuComponent(plugin) {
@@ -81704,9 +81709,9 @@ function ConfigIssuesButton() {
81704
81709
  ] }), $[22] = t6, $[23] = t7, $[24] = t8) : t8 = $[24], t8;
81705
81710
  }
81706
81711
  function _temp2$a(group2) {
81707
- return group2.problems.some(_temp$o);
81712
+ return group2.problems.some(_temp$p);
81708
81713
  }
81709
- function _temp$o(problem) {
81714
+ function _temp$p(problem) {
81710
81715
  return problem.severity === "warning";
81711
81716
  }
81712
81717
  const TrialDialogViewed = defineEvent({
@@ -82114,7 +82119,7 @@ const FreeTrialProvider = (t0) => {
82114
82119
  url: `${queryURL}?${queryParams.toString()}`
82115
82120
  }).subscribe((response) => {
82116
82121
  setData(response), response?.showOnLoad && (setShowOnLoad(!0), setShowDialog(!0));
82117
- }, _temp$n);
82122
+ }, _temp$o);
82118
82123
  return () => {
82119
82124
  request.unsubscribe();
82120
82125
  };
@@ -82140,7 +82145,7 @@ const FreeTrialProvider = (t0) => {
82140
82145
  let t9;
82141
82146
  return $[27] !== children || $[28] !== t8 ? (t9 = /* @__PURE__ */ jsx(FreeTrialContext.Provider, { value: t8, children }), $[27] = children, $[28] = t8, $[29] = t9) : t9 = $[29], t9;
82142
82147
  };
82143
- function _temp$n() {
82148
+ function _temp$o() {
82144
82149
  }
82145
82150
  function _temp2$9(p) {
82146
82151
  return !p;
@@ -82194,11 +82199,11 @@ function AppearanceMenu$1(t0) {
82194
82199
  t
82195
82200
  } = useTranslation(), options = useColorSchemeOptions(setScheme, t);
82196
82201
  let t1;
82197
- $[0] !== options ? (t1 = options.map(_temp$m), $[0] = options, $[1] = t1) : t1 = $[1];
82202
+ $[0] !== options ? (t1 = options.map(_temp$n), $[0] = options, $[1] = t1) : t1 = $[1];
82198
82203
  let t2;
82199
82204
  return $[2] !== t1 ? (t2 = /* @__PURE__ */ jsx(Card, { borderTop: !0, flex: "none", padding: 2, overflow: "auto", children: /* @__PURE__ */ jsx(Stack, { as: "ul", space: 1, children: t1 }) }), $[2] = t1, $[3] = t2) : t2 = $[3], t2;
82200
82205
  }
82201
- function _temp$m(t0) {
82206
+ function _temp$n(t0) {
82202
82207
  const {
82203
82208
  icon,
82204
82209
  label,
@@ -82301,7 +82306,7 @@ const ANIMATION_TRANSITION = {
82301
82306
  }, $[2] = onClose, $[3] = t1) : t1 = $[3];
82302
82307
  const handleActionClick = t1;
82303
82308
  let t2;
82304
- $[4] !== actions || $[5] !== handleActionClick ? (t2 = actions?.filter(_temp$l)?.map((action_0) => {
82309
+ $[4] !== actions || $[5] !== handleActionClick ? (t2 = actions?.filter(_temp$m)?.map((action_0) => {
82305
82310
  const {
82306
82311
  render: ActionComponent
82307
82312
  } = action_0;
@@ -82342,7 +82347,7 @@ const ANIMATION_TRANSITION = {
82342
82347
  let t4;
82343
82348
  return $[21] !== t3 ? (t4 = /* @__PURE__ */ jsx(AnimatePresence, { children: t3 }), $[21] = t3, $[22] = t4) : t4 = $[22], t4;
82344
82349
  });
82345
- function _temp$l(v) {
82350
+ function _temp$m(v) {
82346
82351
  return v.location === "sidebar";
82347
82352
  }
82348
82353
  function isQueryMatch(query, option) {
@@ -82527,7 +82532,7 @@ function NewDocumentButton(props2) {
82527
82532
  }, $[15] = t6) : t6 = $[15];
82528
82533
  const handleSearchChange = t6;
82529
82534
  let t7;
82530
- $[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = () => setOpen(_temp$k), $[16] = t7) : t7 = $[16];
82535
+ $[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = () => setOpen(_temp$l), $[16] = t7) : t7 = $[16];
82531
82536
  const handleToggleOpen = t7;
82532
82537
  let t8;
82533
82538
  $[17] !== buttonElement ? (t8 = () => {
@@ -82643,7 +82648,7 @@ function NewDocumentButton(props2) {
82643
82648
  let t25;
82644
82649
  return $[84] !== handlePopoverKeyDown || $[85] !== open || $[86] !== scheme || $[87] !== t22 || $[88] !== t24 ? (t25 = /* @__PURE__ */ jsx(StyledPopover$1, { constrainSize: !0, onKeyDown: handlePopoverKeyDown, open, tone: "default", portal: !0, radius: 3, ref: popoverRef, scheme, content: t22, children: t24 }), $[84] = handlePopoverKeyDown, $[85] = open, $[86] = scheme, $[87] = t22, $[88] = t24, $[89] = t25) : t25 = $[89], t25;
82645
82650
  }
82646
- function _temp$k(v) {
82651
+ function _temp$l(v) {
82647
82652
  return !v;
82648
82653
  }
82649
82654
  function useNewDocumentOptions() {
@@ -82700,7 +82705,7 @@ const PresenceMenuItem = memo(function(props2) {
82700
82705
  if ($[7] !== handleFocus || $[8] !== locations || $[9] !== user) {
82701
82706
  t3 = /* @__PURE__ */ Symbol.for("react.early_return_sentinel");
82702
82707
  bb0: {
82703
- const lastActiveLocation = orderBy(locations || [], ["lastActiveAt"], ["desc"]).find(_temp$j);
82708
+ const lastActiveLocation = orderBy(locations || [], ["lastActiveAt"], ["desc"]).find(_temp$k);
82704
82709
  if (hasLink = !!lastActiveLocation?.documentId, lastActiveLocation) {
82705
82710
  const perspective = getVersionFromId(lastActiveLocation.documentId), t42 = {
82706
82711
  id: getPublishedId(lastActiveLocation.documentId),
@@ -82729,7 +82734,7 @@ const PresenceMenuItem = memo(function(props2) {
82729
82734
  let t7;
82730
82735
  return $[25] !== handleFocus || $[26] !== t4 || $[27] !== t5 || $[28] !== t6 || $[29] !== user.displayName ? (t7 = /* @__PURE__ */ jsx(MenuItem, { as: "div", disabled: t4, tooltipProps: t5, "data-as": "a", onFocus: handleFocus, preview: t6, ref: setMenuItemElement, text: user.displayName }), $[25] = handleFocus, $[26] = t4, $[27] = t5, $[28] = t6, $[29] = user.displayName, $[30] = t7) : t7 = $[30], t7;
82731
82736
  });
82732
- function _temp$j(location2) {
82737
+ function _temp$k(location2) {
82733
82738
  return location2.documentId;
82734
82739
  }
82735
82740
  const StyledMenu$2 = styled(Menu)`
@@ -82881,12 +82886,12 @@ function useStudioAnnouncements() {
82881
82886
  return $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
82882
82887
  studioAnnouncements: [],
82883
82888
  unseenAnnouncements: [],
82884
- onDialogOpen: _temp$i
82889
+ onDialogOpen: _temp$j
82885
82890
  }, $[0] = t0) : t0 = $[0], t0;
82886
82891
  }
82887
82892
  return context;
82888
82893
  }
82889
- function _temp$i() {
82894
+ function _temp$j() {
82890
82895
  }
82891
82896
  function StudioAnnouncementsMenuItem(t0) {
82892
82897
  const $ = c(9), {
@@ -82965,7 +82970,7 @@ function ResourcesMenuItems(t0) {
82965
82970
  let t10;
82966
82971
  $[21] !== error || $[22] !== fallbackLinks || $[23] !== value ? (t10 = (value === void 0 || error) && /* @__PURE__ */ jsx("div", { children: fallbackLinks }), $[21] = error, $[22] = fallbackLinks, $[23] = value, $[24] = t10) : t10 = $[24];
82967
82972
  let t11;
82968
- $[25] !== error || $[26] !== sections ? (t11 = !error && sections?.map(_temp$h), $[25] = error, $[26] = sections, $[27] = t11) : t11 = $[27];
82973
+ $[25] !== error || $[26] !== sections ? (t11 = !error && sections?.map(_temp$i), $[25] = error, $[26] = sections, $[27] = t11) : t11 = $[27];
82969
82974
  let t12;
82970
82975
  $[28] !== currentVersion.version || $[29] !== t ? (t12 = t("help-resources.studio-version", {
82971
82976
  studioVersion: currentVersion.version
@@ -82986,7 +82991,7 @@ function ResourcesMenuItems(t0) {
82986
82991
  t14
82987
82992
  ] }), $[40] = t10, $[41] = t11, $[42] = t13, $[43] = t14, $[44] = t15) : t15 = $[44], t15;
82988
82993
  }
82989
- function _temp$h(subSection) {
82994
+ function _temp$i(subSection) {
82990
82995
  return subSection ? /* @__PURE__ */ jsx(SubSection, { subSection }, subSection._key) : null;
82991
82996
  }
82992
82997
  function SubSection(t0) {
@@ -83264,14 +83269,14 @@ function AppearanceMenu(t0) {
83264
83269
  let t1;
83265
83270
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = /* @__PURE__ */ jsx(MenuDivider, {}), $[0] = t1) : t1 = $[0];
83266
83271
  let t2;
83267
- $[1] !== options ? (t2 = options.map(_temp$g), $[1] = options, $[2] = t2) : t2 = $[2];
83272
+ $[1] !== options ? (t2 = options.map(_temp$h), $[1] = options, $[2] = t2) : t2 = $[2];
83268
83273
  let t3;
83269
83274
  return $[3] !== t2 ? (t3 = /* @__PURE__ */ jsxs(Fragment$1, { children: [
83270
83275
  t1,
83271
83276
  t2
83272
83277
  ] }), $[3] = t2, $[4] = t3) : t3 = $[4], t3;
83273
83278
  }
83274
- function _temp$g(t0) {
83279
+ function _temp$h(t0) {
83275
83280
  const {
83276
83281
  icon,
83277
83282
  label,
@@ -83533,7 +83538,7 @@ function StudioNavbar(props2) {
83533
83538
  break bb0;
83534
83539
  }
83535
83540
  let t222;
83536
- $[33] !== actions ? (t222 = actions?.filter(_temp$f)?.map(_temp2$7), $[33] = actions, $[34] = t222) : t222 = $[34], t21 = t222;
83541
+ $[33] !== actions ? (t222 = actions?.filter(_temp$g)?.map(_temp2$7), $[33] = actions, $[34] = t222) : t222 = $[34], t21 = t222;
83537
83542
  }
83538
83543
  const actionNodes = t21;
83539
83544
  let t22;
@@ -83620,7 +83625,7 @@ function _temp2$7(action) {
83620
83625
  } = action;
83621
83626
  return ActionComponent ? /* @__PURE__ */ jsx(ActionComponent, {}, action.name) : /* @__PURE__ */ jsx(Button, { iconRight: action?.icon, mode: "bleed", onClick: action?.onAction, selected: action.selected, text: action.title }, action.name);
83622
83627
  }
83623
- function _temp$f(v) {
83628
+ function _temp$g(v) {
83624
83629
  return v.location === "topbar";
83625
83630
  }
83626
83631
  const SCHEDULED_PUBLISHING_TOOL_NAME = "schedules";
@@ -84628,7 +84633,7 @@ const CopyPasteProvider = (t0) => {
84628
84633
  const {
84629
84634
  targetValue,
84630
84635
  errors
84631
- } = await transferValue(transferValueOptions), nonWarningErrors = errors.filter(_temp$e), _isEmptyValue = isEmptyValue(targetValue);
84636
+ } = await transferValue(transferValueOptions), nonWarningErrors = errors.filter(_temp$f), _isEmptyValue = isEmptyValue(targetValue);
84632
84637
  if (nonWarningErrors.length > 0) {
84633
84638
  const description = t(nonWarningErrors[0].i18n.key, nonWarningErrors[0].i18n.args);
84634
84639
  toast.push({
@@ -84693,7 +84698,7 @@ const CopyPasteProvider = (t0) => {
84693
84698
  throw new Error("useCopyPaste must be used within a CopyPasteProvider");
84694
84699
  return context;
84695
84700
  };
84696
- function _temp$e(error_0) {
84701
+ function _temp$f(error_0) {
84697
84702
  return error_0.level !== "warning";
84698
84703
  }
84699
84704
  function _temp2$6(t0) {
@@ -84768,7 +84773,7 @@ const GlobalStyle = createGlobalStyle((props2) => {
84768
84773
  `;
84769
84774
  });
84770
84775
  function PerspectiveProvider(t0) {
84771
- const $ = c(17), {
84776
+ const $ = c(20), {
84772
84777
  children,
84773
84778
  selectedPerspectiveName,
84774
84779
  excludedPerspectives: t1
@@ -84791,18 +84796,23 @@ function PerspectiveProvider(t0) {
84791
84796
  excludedPerspectives,
84792
84797
  isDraftModelEnabled
84793
84798
  }), $[3] = excludedPerspectives, $[4] = isDraftModelEnabled, $[5] = releases2, $[6] = selectedPerspectiveName, $[7] = t5) : t5 = $[7];
84794
- const perspectiveStack = t5, t6 = isSystemBundleName(selectedPerspectiveName) ? void 0 : selectedPerspectiveName;
84799
+ const perspectiveStack = t5;
84800
+ let t6;
84801
+ $[8] !== releases2 || $[9] !== selectedPerspectiveName ? (t6 = isSystemBundleName(selectedPerspectiveName) ? void 0 : releases2.map(_temp$e).find((releaseName) => releaseName === selectedPerspectiveName), $[8] = releases2, $[9] = selectedPerspectiveName, $[10] = t6) : t6 = $[10];
84795
84802
  let t7;
84796
- $[8] !== excludedPerspectives || $[9] !== perspectiveStack || $[10] !== selectedPerspective || $[11] !== selectedPerspectiveName || $[12] !== t6 ? (t7 = {
84803
+ $[11] !== excludedPerspectives || $[12] !== perspectiveStack || $[13] !== selectedPerspective || $[14] !== selectedPerspectiveName || $[15] !== t6 ? (t7 = {
84797
84804
  selectedPerspective,
84798
84805
  selectedPerspectiveName,
84799
84806
  selectedReleaseId: t6,
84800
84807
  perspectiveStack,
84801
84808
  excludedPerspectives
84802
- }, $[8] = excludedPerspectives, $[9] = perspectiveStack, $[10] = selectedPerspective, $[11] = selectedPerspectiveName, $[12] = t6, $[13] = t7) : t7 = $[13];
84809
+ }, $[11] = excludedPerspectives, $[12] = perspectiveStack, $[13] = selectedPerspective, $[14] = selectedPerspectiveName, $[15] = t6, $[16] = t7) : t7 = $[16];
84803
84810
  const value = t7;
84804
84811
  let t8;
84805
- return $[14] !== children || $[15] !== value ? (t8 = /* @__PURE__ */ jsx(PerspectiveContext.Provider, { value, children }), $[14] = children, $[15] = value, $[16] = t8) : t8 = $[16], t8;
84812
+ return $[17] !== children || $[18] !== value ? (t8 = /* @__PURE__ */ jsx(PerspectiveContext.Provider, { value, children }), $[17] = children, $[18] = value, $[19] = t8) : t8 = $[19], t8;
84813
+ }
84814
+ function _temp$e(release) {
84815
+ return getReleaseIdFromReleaseDocumentId(release._id);
84806
84816
  }
84807
84817
  function GlobalPerspectiveProvider(t0) {
84808
84818
  const $ = c(6), {
@@ -84822,19 +84832,17 @@ function GlobalPerspectiveProvider(t0) {
84822
84832
  let t4;
84823
84833
  return $[2] !== children || $[3] !== excludedPerspectives || $[4] !== selectedPerspectiveName ? (t4 = /* @__PURE__ */ jsx(PerspectiveProvider, { selectedPerspectiveName, excludedPerspectives, children }), $[2] = children, $[3] = excludedPerspectives, $[4] = selectedPerspectiveName, $[5] = t4) : t4 = $[5], t4;
84824
84834
  }
84825
- const debug$2 = debug$c("sanity:store"), TOGGLE = "toggle.user-application.upload-live-manifest";
84835
+ const debug$2 = debug$c("sanity:store"), DISABLE_TOGGLE = "toggle.user-application.upload-live-manifest.disable";
84826
84836
  async function isEnabled(client) {
84827
- if (typeof process < "u" && process?.env?.SANITY_STUDIO_USER_APPLICATION_CACHE)
84828
- return !0;
84829
84837
  const {
84830
84838
  projectId
84831
84839
  } = client.config();
84832
84840
  return projectId ? firstValueFrom(getFeatures({
84833
84841
  projectId,
84834
84842
  versionedClient: client
84835
- })).then((features2) => features2.includes(TOGGLE)).catch((err) => (debug$2(`Fetching features failed. User applications cache not enabled for project ${projectId}.`, {
84843
+ })).then((features2) => !features2.includes(DISABLE_TOGGLE)).catch((err) => (debug$2(`Fetching features failed. User applications cache enabled for project ${projectId}.`, {
84836
84844
  err
84837
- }), !1)) : !1;
84845
+ }), !0)) : !1;
84838
84846
  }
84839
84847
  function createUserApplicationCache() {
84840
84848
  const appCache = {}, projectIndex = {};
@@ -85336,6 +85344,7 @@ async function generateStudioManifest(workspaces, theme) {
85336
85344
  const workspaceManifests = await Promise.all(workspaces.map((workspace) => generateWorkspaceManifest(workspace, theme)));
85337
85345
  return {
85338
85346
  buildId,
85347
+ bundleVersion: SANITY_VERSION,
85339
85348
  // Filter out null entries (workspaces without schemaDescriptorId)
85340
85349
  workspaces: workspaceManifests.filter((config) => config !== null)
85341
85350
  };
@@ -90105,6 +90114,7 @@ export {
90105
90114
  _createAuthStore,
90106
90115
  _isCustomDocumentTypeDefinition,
90107
90116
  _isSanityDocumentTypeDefinition,
90117
+ _isType,
90108
90118
  asLoadable,
90109
90119
  buildCommentRangeDecorations,
90110
90120
  buildLegacyTheme,