sanity 5.6.1-next.4 → 5.7.0-next.7

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
@@ -1,14 +1,14 @@
1
1
  import { jsx, jsxs, Fragment as Fragment$1 } from "react/jsx-runtime";
2
2
  import { c } from "react/compiler-runtime";
3
3
  import * as PathUtils from "@sanity/util/paths";
4
- import { toString, FOCUS_TERMINATOR, startsWith, isEqual as isEqual$3, pathFor, get as get$1, trimLeft, fromString, trimChildPath as trimChildPath$1 } from "@sanity/util/paths";
4
+ import { toString, FOCUS_TERMINATOR, startsWith, isEqual as isEqual$2, pathFor, get as get$1, trimLeft, fromString, trimChildPath as trimChildPath$1 } from "@sanity/util/paths";
5
5
  import React, { forwardRef, useRef, useState, useId, useCallback, useMemo, useImperativeHandle, useEffect, isValidElement, Fragment, cloneElement, memo, useContext, useSyncExternalStore, Suspense, useReducer, startTransition, Component, use as use$2, useLayoutEffect, useEffectEvent, createContext, useDebugValue, PureComponent, Children, useTransition, useInsertionEffect, lazy, useDeferredValue, version, StrictMode } from "react";
6
6
  import deepEquals from "react-fast-compare";
7
7
  import { WorkspacesContext, LocaleContext, MediaLibraryIdsContext, PerspectiveContext, UserColorManagerContext, ResourceCacheContext, EventsContext, WorkspaceContext, DocumentChangeContext, ReviewChangesContext, DiffContext, PresenceContext, FormBuilderContext, PortableTextMemberSchemaTypesContext, SelectedAnnotationsContext, ValidationContext, PortableTextMarkersContext, PortableTextMemberItemsContext, ChangeIndicatorTrackerContextStore, ChangeIndicatorTrackerContextGetSnapshot, FormCallbacksContext, ReferenceInputOptionsContext, DocumentIdContext, HoveredFieldContext, FieldActionsContext, FormValueContext, ReferenceItemRefContext, GetFormValueContext, EnhancedObjectDialogContext, DocumentFieldActionsContext, SortableItemIdContext, VirtualizerScrollInstanceContext, FullscreenPTEContext, PresenceTrackerContextStore, PresenceTrackerContextGetSnapshot, FormFieldPresenceContext, SourceContext, PortableTextMemberItemElementRefsContext, ScrollContext, AssetLimitUpsellContext, DialogStackContext, ReleasesUpsellContext, ReleasesMetadataContext, TableContext, SearchContext, SingleDocReleaseEnabledContext, SingleDocReleaseUpsellContext, SingleDocReleaseContext, ActiveWorkspaceMatcherContext, CalendarContext, AppIdCacheContext, CommentsAuthoringPathContext, CommentsIntentContext, CommentInputContext, CommentsContext, CommentsEnabledContext, CommentsOnboardingContext, CommentsSelectedPathContext, CommentsUpsellContext, AddonDatasetContext, SanityCreateConfigContext, ScheduledPublishingEnabledContext, SchedulesContext, SchedulePublishUpsellContext, DocumentActionPropsContext, TasksEnabledContext, IsLastPaneContext, MentionUserContext, TasksNavigationContext, TasksContext, TasksUpsellContext, RouterHistoryContext, ColorSchemeSetValueContext, ColorSchemeValueContext, DocumentLimitUpsellContext, NavbarContext, FreeTrialContext, LiveUserApplicationContext, PackageVersionInfoContext, StudioAnnouncementContext, CopyPasteContext, UserApplicationCacheContext, PreviewCardContext, ZIndexContext, zIndexContextDefaults } from "sanity/_singletons";
8
8
  import { SchedulesContext as SchedulesContext2 } from "sanity/_singletons";
9
9
  import { Badge, Grid, rem, Box, Stack, Card, Spinner, Text as Text$1, Layer, Flex, Dialog, useTheme, Button as Button$1, Skeleton, Heading, Avatar, AvatarStack, Inline, Breadcrumbs, useClickOutsideEvent, Code, MenuDivider, Menu, useElementRect, Autocomplete, useToast, useGlobalKeyDown, useElementSize, AvatarCounter, TextInput as TextInput$1, Container as Container$2, Checkbox as Checkbox$1, Switch as Switch$1, Select, LayerProvider, ElementQuery, TabList, rgba, useLayer, MenuItem as MenuItem$1, useBoundaryElement, BoundaryElementProvider, usePortal, PortalProvider, Portal, _responsive, useRootTheme, useArrayProp, TextArea, TextSkeleton, useMediaIndex, isHTMLElement, Radio, TabPanel, studioTheme, Label, ThemeColorProvider, DialogProvider, focusLastDescendant, focusFirstDescendant, VirtualList as VirtualList$1, usePrefersDark, ThemeProvider, ToastProvider } from "@sanity/ui";
10
10
  import { useVirtualizer, defaultRangeExtractor, elementScroll } from "@tanstack/react-virtual";
11
- import { throttle, isEqual as isEqual$2, memoize as memoize$1, partition, groupBy, omit, isPlainObject as isPlainObject$1, get, flatten as flatten$1, uniqBy, sample, uniq, orderBy, xor, debounce, keyBy, toLower, compact, words, intersection, union, flow, trim, sortBy, isFinite, pickBy, findIndex as findIndex$1, clone, isObject, isString as isString$1, noop as noop$7, capitalize, deburr, startCase, last as last$1, difference, upperFirst, set as set$1, find, uniqueId, castArray, pick, sortedIndex, values, identity as identity$2, isEmpty as isEmpty$1, range, sum as sum$1, max, escapeRegExp as escapeRegExp$1 } from "lodash-es";
11
+ import { throttle, isEqual as isEqual$1, memoize as memoize$1, partition, groupBy, omit, isPlainObject as isPlainObject$1, get, flatten as flatten$1, uniqBy, sample, uniq, orderBy, xor, debounce, keyBy, toLower, compact, words, intersection, union, flow, trim, sortBy, isFinite, pickBy, findIndex as findIndex$1, clone, isObject, isString as isString$1, noop as noop$7, capitalize, deburr, startCase, last as last$1, difference, upperFirst, set as set$1, find, uniqueId, castArray, pick, sortedIndex, values, identity as identity$2, isEmpty as isEmpty$1, range, sum as sum$1, max, escapeRegExp as escapeRegExp$1 } from "lodash-es";
12
12
  import { styled, css, keyframes, useTheme as useTheme$1, createGlobalStyle } from "styled-components";
13
13
  import { EllipsisHorizontalIcon, ErrorOutlineIcon, CircleIcon, CalendarIcon, UnpublishIcon, PublishIcon, EditIcon, CloseIcon, TrashIcon, AddCircleIcon, TimelineIcon, ChevronRightIcon, DocumentIcon, ImageIcon, ChevronDownIcon, ArrowRightIcon, ArrowDownIcon, RevertIcon, WarningOutlineIcon, InfoOutlineIcon, CheckmarkIcon, AddIcon, HelpCircleIcon, AccessDeniedIcon, ToggleArrowRightIcon, SyncIcon, LaunchIcon, BulbOutlineIcon, UnknownIcon, UploadIcon, DragHandleIcon, SearchIcon, StackCompactIcon, PanelLeftIcon, InsertAboveIcon, InsertBelowIcon, CopyIcon, AddDocumentIcon, ChevronLeftIcon, EarthGlobeIcon, EarthAmericasIcon, LinkIcon, UlistIcon, OlistIcon, CodeIcon, UnderlineIcon, StrikethroughIcon, ItalicIcon, BoldIcon, BlockElementIcon, InlineElementIcon, CollapseIcon, ExpandIcon, ResetIcon, Icon, ChevronUpIcon, DownloadIcon, DocumentsIcon, ReadOnlyIcon, BinaryDocumentIcon, LockIcon, CropIcon, EyeOpenIcon, DotIcon, CheckmarkCircleIcon, PinFilledIcon, PinIcon, RestoreIcon, ClockIcon, CloseCircleIcon, UnarchiveIcon, ArchiveIcon, ArrowUpIcon, ControlsIcon, SpinnerIcon, ArrowLeftIcon, SortIcon, ComposeSparklesIcon, UnlockIcon, ClipboardIcon, StringIcon, NumberIcon, BlockContentIcon, UndoIcon, UnlinkIcon, LinkRemovedIcon, AddCommentIcon, CommentIcon, SelectIcon, TaskIcon, UserIcon, DesktopIcon, MoonIcon, SunIcon, EyeClosedIcon, DoubleChevronRightIcon, AddUserIcon, CogIcon, BoltIcon, LeaveIcon, UsersIcon, GithubIcon, RefreshIcon, MenuIcon } from "@sanity/icons";
14
14
  import { Button, ErrorBoundary, Tooltip, Popover, MenuItem, MenuButton, TooltipDelayGroupProvider, Dialog as Dialog$1, Tab } from "./_chunks-es/TooltipDelayGroupProvider.js";
@@ -50,7 +50,7 @@ import QuickLRU from "quick-lru";
50
50
  import { useDevicePixelRatio, getDevicePixelRatio } from "use-device-pixel-ratio";
51
51
  import classNames from "classnames";
52
52
  import { DEFAULT_MAX_FIELD_DEPTH, builtinTypes, validateSchema, groupProblems, DescriptorConverter, ALL_FIELDS_GROUP_NAME, isActionEnabled, processSchemaSynchronization } from "@sanity/schema/_internal";
53
- import { randomKey as randomKey$1, isDeepEmpty, resolveTypeName as resolveTypeName$2, isShallowEmptyObject } from "@sanity/util/content";
53
+ import { randomKey as randomKey$1, isDeepEmpty, resolveTypeName as resolveTypeName$1, isShallowEmptyObject } from "@sanity/util/content";
54
54
  import shallowEquals from "shallow-equals";
55
55
  import { useSensors, useSensor, PointerSensor, KeyboardSensor, DndContext, closestCenter } from "@dnd-kit/core";
56
56
  import { restrictToHorizontalAxis, restrictToVerticalAxis } from "@dnd-kit/modifiers";
@@ -1766,6 +1766,8 @@ const studioLocaleNamespace = "studio", validationLocaleNamespace = "validation"
1766
1766
  "inputs.reference.strength-mismatch.title": "Reference strength mismatch",
1767
1767
  /** Label for button that triggers the action that weakens a reference on strength mismatch */
1768
1768
  "inputs.reference.strength-mismatch.weaken-button-label": "Convert to weak reference",
1769
+ /** Label for action to clear the current value of the select field */
1770
+ "inputs.select.action.clear": "Clear",
1769
1771
  /** Action message for generating the slug */
1770
1772
  "inputs.slug.action.generate": "Generate",
1771
1773
  /** Loading message for when the input is actively generating a slug */
@@ -2802,12 +2804,12 @@ const studioLocaleNamespace = "studio", validationLocaleNamespace = "validation"
2802
2804
  }
2803
2805
  })(), LOCAL_STORAGE_PREFIX = "sanity-locale";
2804
2806
  function getPreferredLocale(projectId, sourceId) {
2805
- return supportsLocalStorage ? localStorage.getItem(getItemKey$2(projectId, sourceId)) ?? void 0 : void 0;
2807
+ return supportsLocalStorage ? localStorage.getItem(getItemKey$1(projectId, sourceId)) ?? void 0 : void 0;
2806
2808
  }
2807
2809
  function storePreferredLocale(projectId, sourceId, locale) {
2808
- supportsLocalStorage && localStorage.setItem(getItemKey$2(projectId, sourceId), locale);
2810
+ supportsLocalStorage && localStorage.setItem(getItemKey$1(projectId, sourceId), locale);
2809
2811
  }
2810
- function getItemKey$2(projectId, sourceId) {
2812
+ function getItemKey$1(projectId, sourceId) {
2811
2813
  return [LOCAL_STORAGE_PREFIX, projectId, sourceId].join(":");
2812
2814
  }
2813
2815
  function LocaleProvider(props2) {
@@ -3149,7 +3151,7 @@ function useThrottledCallback(callback, wait, options) {
3149
3151
  }
3150
3152
  function useUnique(value) {
3151
3153
  const [previous, setPrevious] = useState(value);
3152
- return isEqual$2(previous, value) ? previous : (setPrevious(value), value);
3154
+ return isEqual$1(previous, value) ? previous : (setPrevious(value), value);
3153
3155
  }
3154
3156
  const DEBUG_MODE$1 = typeof process > "u" ? !1 : process?.env?.SANITY_STUDIO_DEBUG_I18N, DEBUG_I18N = !!DEBUG_MODE$1, debugWrappers = {
3155
3157
  reverse: (str) => `\u202E${str}`,
@@ -3222,9 +3224,9 @@ function useGetI18nText(input) {
3222
3224
  }, $[4] = t, $[5] = t2) : t2 = $[5], t2;
3223
3225
  }
3224
3226
  function _temp2$1H(item) {
3225
- return item?.i18n ? Object.values(item.i18n).map(_temp$4a) : [];
3227
+ return item?.i18n ? Object.values(item.i18n).map(_temp$49) : [];
3226
3228
  }
3227
- function _temp$4a(t0) {
3229
+ function _temp$49(t0) {
3228
3230
  const {
3229
3231
  ns
3230
3232
  } = t0;
@@ -3240,7 +3242,7 @@ function useI18nText(node) {
3240
3242
  break bb0;
3241
3243
  }
3242
3244
  let t12;
3243
- $[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;
3245
+ $[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;
3244
3246
  }
3245
3247
  const namespaces = t0, {
3246
3248
  t
@@ -3278,7 +3280,7 @@ function useI18nText(node) {
3278
3280
  }
3279
3281
  return t1;
3280
3282
  }
3281
- function _temp$49(t0) {
3283
+ function _temp$48(t0) {
3282
3284
  const {
3283
3285
  ns
3284
3286
  } = t0;
@@ -3561,7 +3563,7 @@ function useEnsureMediaLibrary(props2) {
3561
3563
  bb0: {
3562
3564
  const handleDefault = defaultIfEmpty({
3563
3565
  status: "inactive"
3564
- }), handleError = catchError$1(_temp$48);
3566
+ }), handleError = catchError$1(_temp$47);
3565
3567
  if (props2.from === "library") {
3566
3568
  let t23;
3567
3569
  $[6] !== props2.libraryId ? (t23 = (organizationId) => ({
@@ -3592,7 +3594,7 @@ function useEnsureMediaLibrary(props2) {
3592
3594
  status: "loading"
3593
3595
  }, $[10] = t2) : t2 = $[10], useObservable(observable, t2);
3594
3596
  }
3595
- function _temp$48(error) {
3597
+ function _temp$47(error) {
3596
3598
  if (error instanceof ProvisionError)
3597
3599
  return of({
3598
3600
  status: "error",
@@ -4058,11 +4060,11 @@ function pathsAreEqual(pathA, pathB) {
4058
4060
  return isKeySegment(segmentA) && isKeySegment(segmentB) ? segmentA._key === segmentB._key : isIndexSegment(segmentA) ? Number(segmentA) === Number(segmentB) : isIndexTuple(segmentA) && isIndexTuple(segmentB) ? segmentA[0] === segmentB[0] && segmentA[1] === segmentB[1] : segmentA === segmentB;
4059
4061
  });
4060
4062
  }
4061
- function getItemKey$1(arrayItem) {
4063
+ function getItemKey(arrayItem) {
4062
4064
  return isKeyedObject(arrayItem) ? arrayItem._key : void 0;
4063
4065
  }
4064
4066
  function getItemKeySegment(arrayItem) {
4065
- const key = getItemKey$1(arrayItem);
4067
+ const key = getItemKey(arrayItem);
4066
4068
  return key ? {
4067
4069
  _key: key
4068
4070
  } : void 0;
@@ -4345,7 +4347,7 @@ function withLocalStorageSWR(wrappedStore) {
4345
4347
  function getKey(key) {
4346
4348
  return merge(of(localStoreStorage.getKey(key)), wrappedStore.getKey(key).pipe(tap((wrappedStoreValue) => {
4347
4349
  localStoreStorage.setKey(key, wrappedStoreValue);
4348
- }))).pipe(distinctUntilChanged(isEqual$2));
4350
+ }))).pipe(distinctUntilChanged(isEqual$1));
4349
4351
  }
4350
4352
  function setKey2(key, nextValue) {
4351
4353
  return localStoreStorage.setKey(key, nextValue), wrappedStore.setKey(key, nextValue);
@@ -4408,7 +4410,7 @@ function createServerKeyValueStore({
4408
4410
  }
4409
4411
  return {
4410
4412
  getKey(key) {
4411
- return concat(getKey(key), events$.pipe(filter((event) => event.key === key), map((event) => event.value), distinctUntilChanged(isEqual$2)));
4413
+ return concat(getKey(key), events$.pipe(filter((event) => event.key === key), map((event) => event.value), distinctUntilChanged(isEqual$1)));
4412
4414
  },
4413
4415
  setKey: setKey2
4414
4416
  };
@@ -4818,7 +4820,7 @@ function _createAuthStore({
4818
4820
  distinctUntilChanged((prev, next) => (
4819
4821
  // Only notify subscribers if the the currentUser object has changed.
4820
4822
  // Using isEqual is OK since the currentUser object being a small data structure.
4821
- isEqual$2(prev.currentUser, next.currentUser)
4823
+ isEqual$1(prev.currentUser, next.currentUser)
4822
4824
  )),
4823
4825
  shareReplay(1)
4824
4826
  );
@@ -7380,7 +7382,7 @@ async function resolveInitialValue(schema2, template, params = {}, context, opti
7380
7382
  return validateInitialObjectValue(newValue, template);
7381
7383
  }
7382
7384
  function getItemType$1(arrayType, item) {
7383
- const itemTypeName = resolveTypeName$2(item);
7385
+ const itemTypeName = resolveTypeName$1(item);
7384
7386
  return itemTypeName === "object" && arrayType.of.length === 1 ? arrayType.of[0] : arrayType.of.find((memberType) => memberType.name === itemTypeName);
7385
7387
  }
7386
7388
  const DEFAULT_MAX_RECURSION_DEPTH = 10, memoizeResolveInitialValueForType = (fn) => {
@@ -7941,7 +7943,7 @@ function stateReducer(prev, action) {
7941
7943
  case "loading":
7942
7944
  return [prevResult, !0];
7943
7945
  case "value":
7944
- return !prevIsLoading && isEqual$2(action.value, prevResult) ? prev : [action.value, !1];
7946
+ return !prevIsLoading && isEqual$1(action.value, prevResult) ? prev : [action.value, !1];
7945
7947
  case "error":
7946
7948
  throw action.error;
7947
7949
  default:
@@ -7964,7 +7966,7 @@ function useDocumentValuePermissions(t0) {
7964
7966
  document: document2,
7965
7967
  permission
7966
7968
  });
7967
- return subscriptionRef.current = permissions$.pipe(distinctUntilChanged$1(_temp$47)).subscribe({
7969
+ return subscriptionRef.current = permissions$.pipe(distinctUntilChanged$1(_temp$46)).subscribe({
7968
7970
  next: (value) => dispatch({
7969
7971
  type: "value",
7970
7972
  value
@@ -7978,8 +7980,8 @@ function useDocumentValuePermissions(t0) {
7978
7980
  };
7979
7981
  }, t2 = [grantsStore, document2, permission], $[0] = document2, $[1] = grantsStore, $[2] = permission, $[3] = t1, $[4] = t2) : (t1 = $[3], t2 = $[4]), useEffect(t1, t2), state;
7980
7982
  }
7981
- function _temp$47(prev, next) {
7982
- return isEqual$2(prev, next);
7983
+ function _temp$46(prev, next) {
7984
+ return isEqual$1(prev, next);
7983
7985
  }
7984
7986
  function refCountDelay(duration, scheduler = asapScheduler) {
7985
7987
  return (source) => {
@@ -8643,7 +8645,7 @@ class Timeline {
8643
8645
  }
8644
8646
  calculateDiff(initialDoc, finalDoc, firstIdx, lastIdx) {
8645
8647
  let draftValue = incremental.wrap(initialDoc.draft, null), publishedValue = incremental.wrap(initialDoc.published, null);
8646
- const initialValue = getValue$1(draftValue, publishedValue), initialAttributes = getAttrs$1(initialDoc);
8648
+ const initialValue = getValue(draftValue, publishedValue), initialAttributes = getAttrs$1(initialDoc);
8647
8649
  let firstChunk = null;
8648
8650
  for (let chunkIdx = firstIdx; chunkIdx <= lastIdx; chunkIdx++) {
8649
8651
  const chunk = this._chunks.get(chunkIdx);
@@ -8662,7 +8664,7 @@ class Timeline {
8662
8664
  return diffValue$1(this, firstChunk, initialValue, initialAttributes, finalValue, finalAttributes);
8663
8665
  }
8664
8666
  }
8665
- function getValue$1(draftValue, publishedValue) {
8667
+ function getValue(draftValue, publishedValue) {
8666
8668
  return incremental.getType(draftValue) === "null" ? publishedValue : draftValue;
8667
8669
  }
8668
8670
  function emptyVersionState(id2) {
@@ -9202,7 +9204,7 @@ function useTimelineStore(t0) {
9202
9204
  }, $[32] = t10, $[33] = t11, $[34] = t13, $[35] = t9, $[36] = t14) : t14 = $[36], t14;
9203
9205
  }
9204
9206
  function _temp3$I(innerController_0) {
9205
- const chunks = innerController_0.timeline.mapChunks(_temp$46), lastNonDeletedChunk = chunks.filter(_temp2$1G), hasMoreChunks = !innerController_0.timeline.reachedEarliestEntry;
9207
+ const chunks = innerController_0.timeline.mapChunks(_temp$45), lastNonDeletedChunk = chunks.filter(_temp2$1G), hasMoreChunks = !innerController_0.timeline.reachedEarliestEntry;
9206
9208
  hasMoreChunks && chunks.length > 16 && innerController_0.setLoadMore(!1);
9207
9209
  const timelineReady = !["invalid", "loading"].includes(innerController_0.selectionState);
9208
9210
  return {
@@ -9225,7 +9227,7 @@ function _temp3$I(innerController_0) {
9225
9227
  function _temp2$1G(chunk_1) {
9226
9228
  return !["delete", "initial"].includes(chunk_1.type);
9227
9229
  }
9228
- function _temp$46(c2) {
9230
+ function _temp$45(c2) {
9229
9231
  return c2;
9230
9232
  }
9231
9233
  const handleIncomingMessage = (event) => {
@@ -9415,7 +9417,7 @@ function createPresenceStore(context) {
9415
9417
  documentId: item.documentId
9416
9418
  }))),
9417
9419
  // Only emit if the presence has changed for this document id
9418
- distinctUntilChanged((prev, curr) => isEqual$2(prev, curr))
9420
+ distinctUntilChanged((prev, curr) => isEqual$1(prev, curr))
9419
9421
  )
9420
9422
  };
9421
9423
  }
@@ -9538,11 +9540,11 @@ function createMultiKeyWeakMap() {
9538
9540
  function ResourceCacheProvider(t0) {
9539
9541
  const $ = c(3), {
9540
9542
  children
9541
- } = t0, [resourceCache] = useState(_temp$45);
9543
+ } = t0, [resourceCache] = useState(_temp$44);
9542
9544
  let t1;
9543
9545
  return $[0] !== children || $[1] !== resourceCache ? (t1 = /* @__PURE__ */ jsx(ResourceCacheContext.Provider, { value: resourceCache, children }), $[0] = children, $[1] = resourceCache, $[2] = t1) : t1 = $[2], t1;
9544
9546
  }
9545
- function _temp$45() {
9547
+ function _temp$44() {
9546
9548
  const namespaces = /* @__PURE__ */ new Map(), nullReplacer = {}, emptyDependenciesReplacer = [nullReplacer], removeNullDependencies = (dependencies) => dependencies.length ? dependencies.map((dep) => dep === null ? nullReplacer : dep) : emptyDependenciesReplacer;
9547
9549
  return {
9548
9550
  get: (t0) => {
@@ -9823,25 +9825,25 @@ function useComlinkStore() {
9823
9825
  }
9824
9826
  const initial$1 = [], fallback$1 = of(initial$1);
9825
9827
  function useDocumentPresence(documentId) {
9826
- const $ = c(6), [mounted, mount] = useReducer(_temp$44, !1);
9828
+ const $ = c(6), [mounted, mount] = useReducer(_temp$43, !1);
9827
9829
  let t0, t1;
9828
9830
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => startTransition(mount), t1 = [], $[0] = t0, $[1] = t1) : (t0 = $[0], t1 = $[1]), useEffect(t0, t1);
9829
9831
  const presenceStore = usePresenceStore();
9830
9832
  let t2;
9831
9833
  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);
9832
9834
  }
9833
- function _temp$44() {
9835
+ function _temp$43() {
9834
9836
  return !0;
9835
9837
  }
9836
9838
  const initial = [], fallback = of(initial);
9837
9839
  function useGlobalPresence() {
9838
- const $ = c(2), [mounted, mount] = useReducer(_temp$43, !1);
9840
+ const $ = c(2), [mounted, mount] = useReducer(_temp$42, !1);
9839
9841
  let t0, t1;
9840
9842
  $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => startTransition(mount), t1 = [], $[0] = t0, $[1] = t1) : (t0 = $[0], t1 = $[1]), useEffect(t0, t1);
9841
9843
  const presenceStore = usePresenceStore();
9842
9844
  return useObservable(mounted ? presenceStore.globalPresence$ : fallback, initial);
9843
9845
  }
9844
- function _temp$43() {
9846
+ function _temp$42() {
9845
9847
  return !0;
9846
9848
  }
9847
9849
  function EventsProvider(t0) {
@@ -11022,7 +11024,7 @@ function useRelativeTime(time, t0) {
11022
11024
  const $ = c(5);
11023
11025
  let t1;
11024
11026
  $[0] !== t0 ? (t1 = t0 === void 0 ? {} : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
11025
- const options = t1, [now, updateNow] = useReducer(_temp$42, null, _temp2$1F), resolved = useFormatRelativeTime(time, options.relativeTo || now, options);
11027
+ const options = t1, [now, updateNow] = useReducer(_temp$41, null, _temp2$1F), resolved = useFormatRelativeTime(time, options.relativeTo || now, options);
11026
11028
  let t2, t3;
11027
11029
  return $[2] !== resolved.refreshInterval ? (t2 = () => {
11028
11030
  let timerId;
@@ -11039,7 +11041,7 @@ function useRelativeTime(time, t0) {
11039
11041
  function _temp2$1F() {
11040
11042
  return Date.now();
11041
11043
  }
11042
- function _temp$42() {
11044
+ function _temp$41() {
11043
11045
  return Date.now();
11044
11046
  }
11045
11047
  function useFormatRelativeTime(date, now, t0) {
@@ -11375,7 +11377,7 @@ const IconBox$1 = styled(Flex)((props2) => {
11375
11377
  let t2;
11376
11378
  $[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];
11377
11379
  let t3;
11378
- $[4] !== collaborators ? (t3 = collaborators.map(_temp$41), $[4] = collaborators, $[5] = t3) : t3 = $[5];
11380
+ $[4] !== collaborators ? (t3 = collaborators.map(_temp$40), $[4] = collaborators, $[5] = t3) : t3 = $[5];
11379
11381
  let t4;
11380
11382
  return $[6] !== t2 || $[7] !== t3 ? (t4 = /* @__PURE__ */ jsxs(Stack, { paddingBottom: 1, children: [
11381
11383
  t2,
@@ -11471,7 +11473,7 @@ function Event$1(t0) {
11471
11473
  t23
11472
11474
  ] }), $[52] = t22, $[53] = t23, $[54] = t24) : t24 = $[54], t24;
11473
11475
  }
11474
- function _temp$41(userId) {
11476
+ function _temp$40(userId) {
11475
11477
  return /* @__PURE__ */ jsx(UserLine, { userId }, userId);
11476
11478
  }
11477
11479
  function DiffTooltip(props2) {
@@ -11520,7 +11522,7 @@ function DiffTooltipWithAnnotation(props2) {
11520
11522
  let t2;
11521
11523
  $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, weight: "medium", children: t1 }), $[9] = t1, $[10] = t2) : t2 = $[10];
11522
11524
  let t3;
11523
- $[11] !== annotations ? (t3 = annotations.map(_temp$40), $[11] = annotations, $[12] = t3) : t3 = $[12];
11525
+ $[11] !== annotations ? (t3 = annotations.map(_temp$3$), $[11] = annotations, $[12] = t3) : t3 = $[12];
11524
11526
  let t4;
11525
11527
  $[13] !== t3 ? (t4 = /* @__PURE__ */ jsx(Stack, { space: 2, children: t3 }), $[13] = t3, $[14] = t4) : t4 = $[14];
11526
11528
  let t5;
@@ -11532,7 +11534,7 @@ function DiffTooltipWithAnnotation(props2) {
11532
11534
  let t6;
11533
11535
  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;
11534
11536
  }
11535
- function _temp$40(annotation, idx) {
11537
+ function _temp$3$(annotation, idx) {
11536
11538
  return /* @__PURE__ */ jsx(AnnotationItem, { annotation }, idx);
11537
11539
  }
11538
11540
  function AnnotationItem(t0) {
@@ -11887,8 +11889,8 @@ const useConditionalProperty = (props2) => {
11887
11889
  value
11888
11890
  }, $[0] = currentUser, $[1] = document2, $[2] = parent, $[3] = value, $[4] = t1) : t1 = $[4], useCheckCondition(checkProperty, checkPropertyKey, t1);
11889
11891
  };
11890
- function resolveTypeName$1(value) {
11891
- return isTypedObject(value) ? value._type : resolveJSType$1(value);
11892
+ function resolveTypeName(value) {
11893
+ return isTypedObject(value) ? value._type : resolveJSType(value);
11892
11894
  }
11893
11895
  function getArrayDiffItemType(diff, schemaType) {
11894
11896
  return diff.action === "added" ? {
@@ -11903,10 +11905,10 @@ function getArrayDiffItemType(diff, schemaType) {
11903
11905
  };
11904
11906
  }
11905
11907
  function resolveArrayMemberType(schemaType, value) {
11906
- const typeName = resolveTypeName$1(value);
11908
+ const typeName = resolveTypeName(value);
11907
11909
  return schemaType.of.find((candidate) => candidate.name === typeName) || (schemaType.of.length === 1 ? schemaType.of[0] : void 0);
11908
11910
  }
11909
- function resolveJSType$1(val) {
11911
+ function resolveJSType(val) {
11910
11912
  return Array.isArray(val) ? "array" : val === null ? "null" : typeof val;
11911
11913
  }
11912
11914
  const ANNOTATION_SYMBOLS = [
@@ -12147,7 +12149,7 @@ function findAnnotationDiff(diff, markDefKey) {
12147
12149
  return diff.fields.markDefs && diff.fields.markDefs.isChanged && diff.fields.markDefs.type === "array" && diff.fields.markDefs.items.find((item) => item.diff && item.diff.type === "object" && (item.diff.toValue && item.diff.toValue._key && item.diff.toValue._key === markDefKey || item.diff.fromValue && item.diff.fromValue._key && item.diff.fromValue._key === markDefKey))?.diff || void 0;
12148
12150
  }
12149
12151
  function isEmptyObject(object) {
12150
- return object && isEqual$2(Object.keys(object), ["_key", "_type"]) || !1;
12152
+ return object && isEqual$1(Object.keys(object), ["_key", "_type"]) || !1;
12151
12153
  }
12152
12154
  function escapeRegExp(text) {
12153
12155
  return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
@@ -12385,7 +12387,7 @@ const SizeDiff = styled.div`
12385
12387
  $[2] !== fields ? (t3 = Object.entries(fields).filter((t42) => {
12386
12388
  const [name, field] = t42;
12387
12389
  return field.isChanged && !ignoredFields.includes(name);
12388
- }).map(_temp$3$), $[2] = fields, $[3] = t3) : t3 = $[3];
12390
+ }).map(_temp$3_), $[2] = fields, $[3] = t3) : t3 = $[3];
12389
12391
  const changedFields = t3, didAssetChange = changedFields.includes("asset");
12390
12392
  let t4;
12391
12393
  if ($[4] !== changedFields || $[5] !== schemaType.fields) {
@@ -12444,7 +12446,7 @@ const SizeDiff = styled.div`
12444
12446
  t15
12445
12447
  ] }), $[50] = t14, $[51] = t15, $[52] = t16) : t16 = $[52], t16;
12446
12448
  };
12447
- function _temp$3$(t0) {
12449
+ function _temp$3_(t0) {
12448
12450
  const [name_0] = t0;
12449
12451
  return name_0;
12450
12452
  }
@@ -12706,7 +12708,7 @@ const IMAGE_META_FIELDS = ["crop", "hotspot"], BASE_IMAGE_FIELDS = ["asset", "me
12706
12708
  let t4;
12707
12709
  if ($[7] !== changedFields || $[8] !== schemaType.fields) {
12708
12710
  let t52;
12709
- $[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;
12711
+ $[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;
12710
12712
  } else
12711
12713
  t4 = $[9];
12712
12714
  const nestedFields = t4;
@@ -12755,7 +12757,7 @@ function getChangeDescription(action, t) {
12755
12757
  return "Unknown change";
12756
12758
  }
12757
12759
  }
12758
- function _temp$3_(field_0) {
12760
+ function _temp$3Z(field_0) {
12759
12761
  return field_0.name;
12760
12762
  }
12761
12763
  const NumberWrapper = styled.div`
@@ -13571,6 +13573,23 @@ const PTDiff = (props2) => {
13571
13573
  } = t0;
13572
13574
  let t1;
13573
13575
  return $[0] !== diff || $[1] !== schemaType ? (t1 = /* @__PURE__ */ jsx(DiffFromTo, { align: "center", diff, layout: "grid", path: "_ref", previewComponent: ReferencePreview$1, schemaType }), $[0] = diff, $[1] = schemaType, $[2] = t1) : t1 = $[2], t1;
13576
+ }, SlugWrapper = styled.div`
13577
+ display: inline-block;
13578
+ word-break: break-all;
13579
+ white-space: pre-wrap;
13580
+ `, SlugPreview = (props2) => {
13581
+ const $ = c(2), {
13582
+ value
13583
+ } = props2;
13584
+ let t0;
13585
+ return $[0] !== value.current ? (t0 = /* @__PURE__ */ jsx(Box, { as: SlugWrapper, paddingX: 2, paddingY: 1, children: value.current }), $[0] = value.current, $[1] = t0) : t0 = $[1], t0;
13586
+ }, SlugFieldDiff = (t0) => {
13587
+ const $ = c(3), {
13588
+ diff,
13589
+ schemaType
13590
+ } = t0;
13591
+ let t1;
13592
+ return $[0] !== diff || $[1] !== schemaType ? (t1 = /* @__PURE__ */ jsx(DiffFromTo, { layout: "inline", diff, schemaType, previewComponent: SlugPreview }), $[0] = diff, $[1] = schemaType, $[2] = t1) : t1 = $[2], t1;
13574
13593
  }, StringWrapper$1 = styled.div`
13575
13594
  display: inline-block;
13576
13595
  word-break: break-all;
@@ -13609,6 +13628,7 @@ const PTDiff = (props2) => {
13609
13628
  image: ImageFieldDiff,
13610
13629
  number: NumberFieldDiff,
13611
13630
  reference: ReferenceFieldDiff,
13631
+ slug: SlugFieldDiff,
13612
13632
  string: StringFieldDiff
13613
13633
  };
13614
13634
  function resolveDiffComponent(type, parentSchemaType) {
@@ -13792,7 +13812,7 @@ const isAddedAction = (change) => change.type === "field" && change.diff.action
13792
13812
  return !1;
13793
13813
  return !0;
13794
13814
  }, pathSegmentOfCorrectType = (item, child) => {
13795
- const nextItem = item[child], key = getItemKey$1(nextItem);
13815
+ const nextItem = item[child], key = getItemKey(nextItem);
13796
13816
  return key ? {
13797
13817
  _key: key
13798
13818
  } : Array.isArray(item) ? parseInt(child, 10) : child;
@@ -14023,7 +14043,7 @@ function DiffInspectWrapper(props2) {
14023
14043
  } = props2, $[0] = props2, $[1] = as, $[2] = change, $[3] = children, $[4] = restProps) : (as = $[1], change = $[2], children = $[3], restProps = $[4]);
14024
14044
  const isHovering = useRef(!1), [isInspecting, setIsInspecting] = useState(!1);
14025
14045
  let t0;
14026
- $[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setIsInspecting(_temp$3Z), $[5] = t0) : t0 = $[5];
14046
+ $[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setIsInspecting(_temp$3Y), $[5] = t0) : t0 = $[5];
14027
14047
  const toggleInspect = t0;
14028
14048
  let t1;
14029
14049
  $[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => isHovering.current = !0, $[6] = t1) : t1 = $[6];
@@ -14047,7 +14067,7 @@ function DiffInspectWrapper(props2) {
14047
14067
  let t6;
14048
14068
  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;
14049
14069
  }
14050
- function _temp$3Z(state) {
14070
+ function _temp$3Y(state) {
14051
14071
  return !state;
14052
14072
  }
14053
14073
  const MetaLabel = (t0) => {
@@ -14451,7 +14471,7 @@ function FieldChange(props2) {
14451
14471
  }, $[17] = t7) : t7 = $[17];
14452
14472
  const handleRevertButtonMouseLeave = t7;
14453
14473
  let t8;
14454
- $[18] !== change.parentSchema ? (t8 = change.parentSchema?.jsonType === "array" && !change.parentSchema.of.some(_temp$3Y), $[18] = change.parentSchema, $[19] = t8) : t8 = $[19];
14474
+ $[18] !== change.parentSchema ? (t8 = change.parentSchema?.jsonType === "array" && !change.parentSchema.of.some(_temp$3X), $[18] = change.parentSchema, $[19] = t8) : t8 = $[19];
14455
14475
  const isArray2 = t8;
14456
14476
  let t9;
14457
14477
  $[20] !== change.path || $[21] !== isArray2 ? (t9 = isArray2 ? change.path.slice(0, -1) : change.path, $[20] = change.path, $[21] = isArray2, $[22] = t9) : t9 = $[22];
@@ -14492,7 +14512,7 @@ function FieldChange(props2) {
14492
14512
  t21
14493
14513
  ] }), $[65] = t20, $[66] = t21, $[67] = t22) : t22 = $[67], t22;
14494
14514
  }
14495
- function _temp$3Y(ofType) {
14515
+ function _temp$3X(ofType) {
14496
14516
  return ofType.type?.name === "block";
14497
14517
  }
14498
14518
  const ChangeListWrapper = styled.div`
@@ -14551,7 +14571,7 @@ function GroupChange(props2) {
14551
14571
  isComparingCurrent
14552
14572
  } = useDocumentChange(), FieldWrapper2 = t0 === void 0 ? Fragment : t0;
14553
14573
  let t1;
14554
- $[5] !== changes ? (t1 = changes.every(_temp$3X), $[5] = changes, $[6] = t1) : t1 = $[6];
14574
+ $[5] !== changes ? (t1 = changes.every(_temp$3W), $[5] = changes, $[6] = t1) : t1 = $[6];
14555
14575
  const isPortableText2 = t1;
14556
14576
  let t2;
14557
14577
  $[7] !== diffPath || $[8] !== groupPath ? (t2 = pathsAreEqual(diffPath, groupPath), $[7] = diffPath, $[8] = groupPath, $[9] = t2) : t2 = $[9];
@@ -14606,7 +14626,7 @@ function GroupChange(props2) {
14606
14626
  function _temp2$1D(ofType) {
14607
14627
  return ofType.name === "block";
14608
14628
  }
14609
- function _temp$3X(change) {
14629
+ function _temp$3W(change) {
14610
14630
  return isFieldChange(change) && isPTSchemaType(change.schemaType);
14611
14631
  }
14612
14632
  function useHover(node) {
@@ -14801,7 +14821,7 @@ function ChangesError(t0) {
14801
14821
  $[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: {
14802
14822
  revisionId: error.revisionId
14803
14823
  }, components: {
14804
- Break: _temp$3W
14824
+ Break: _temp$3V
14805
14825
  } }) }) }), $[8] = error, $[9] = revisionNotFoundError, $[10] = t, $[11] = t5) : t5 = $[11];
14806
14826
  let t6;
14807
14827
  return $[12] !== t2 || $[13] !== t4 || $[14] !== t5 ? (t6 = /* @__PURE__ */ jsx(Card, { tone: "caution", padding: 3, children: /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
@@ -14810,7 +14830,7 @@ function ChangesError(t0) {
14810
14830
  t5
14811
14831
  ] }) }), $[12] = t2, $[13] = t4, $[14] = t5, $[15] = t6) : t6 = $[15], t6;
14812
14832
  }
14813
- function _temp$3W() {
14833
+ function _temp$3V() {
14814
14834
  return /* @__PURE__ */ jsx("br", {});
14815
14835
  }
14816
14836
  const RoundedCard = styled.span`
@@ -14892,11 +14912,11 @@ function DiffString(props2) {
14892
14912
  let t0;
14893
14913
  $[0] !== diff.segments ? (t0 = diff.segments || [], $[0] = diff.segments, $[1] = t0) : t0 = $[1];
14894
14914
  let t1;
14895
- $[2] !== t0 ? (t1 = t0.map(_temp$3V), $[2] = t0, $[3] = t1) : t1 = $[3];
14915
+ $[2] !== t0 ? (t1 = t0.map(_temp$3U), $[2] = t0, $[3] = t1) : t1 = $[3];
14896
14916
  let t2;
14897
14917
  return $[4] !== t1 ? (t2 = /* @__PURE__ */ jsx(Fragment$1, { children: t1 }), $[4] = t1, $[5] = t2) : t2 = $[5], t2;
14898
14918
  }
14899
- function _temp$3V(segment, segmentIndex) {
14919
+ function _temp$3U(segment, segmentIndex) {
14900
14920
  return /* @__PURE__ */ jsx(DiffStringSegment, { segment }, segmentIndex);
14901
14921
  }
14902
14922
  const MetaText = styled(Text$1)`
@@ -14931,161 +14951,7 @@ function MetaInfo(props2) {
14931
14951
  t5
14932
14952
  ] }), $[14] = t0, $[15] = t5, $[16] = t6) : t6 = $[16], t6;
14933
14953
  }
14934
- function isEqual$1(item, otherItem) {
14935
- if (item === otherItem)
14936
- return !0;
14937
- if (typeof item != typeof otherItem)
14938
- return !1;
14939
- if (typeof item != "object" && !Array.isArray(item))
14940
- return item === otherItem;
14941
- if (isKeyedObject(item) && isKeyedObject(otherItem) && item._key === otherItem._key)
14942
- return !0;
14943
- if (Array.isArray(item) && Array.isArray(otherItem))
14944
- return item.length !== otherItem.length ? !1 : item.every((child, i) => isEqual$1(child, otherItem[i]));
14945
- if (item === null || otherItem === null)
14946
- return item === otherItem;
14947
- const obj = item, otherObj = otherItem, keys = Object.keys(obj), otherKeys = Object.keys(otherObj);
14948
- return keys.length !== otherKeys.length ? !1 : keys.every((keyName) => isEqual$1(obj[keyName], otherObj[keyName]));
14949
- }
14950
- const ArrayOfOptionsFieldDiff = (t0) => {
14951
- const $ = c(14), {
14952
- diff,
14953
- schemaType
14954
- } = t0, options = schemaType.options?.list, colorManager = useUserColorManager(), {
14955
- t
14956
- } = useTranslation();
14957
- if (!Array.isArray(options))
14958
- return null;
14959
- let t1;
14960
- if ($[0] !== colorManager || $[1] !== diff || $[2] !== schemaType || $[3] !== t) {
14961
- let t22;
14962
- $[5] !== diff || $[6] !== schemaType ? (t22 = (item) => normalizeItems$1(item, diff, schemaType), $[5] = diff, $[6] = schemaType, $[7] = t22) : t22 = $[7];
14963
- let t3;
14964
- $[8] !== colorManager || $[9] !== diff || $[10] !== t ? (t3 = (item_1, index) => {
14965
- const {
14966
- annotation,
14967
- isPresent,
14968
- value,
14969
- memberType,
14970
- title
14971
- } = item_1, color = getAnnotationColor(colorManager, annotation), action = t(isPresent ? "changes.added-label" : "changes.removed-label");
14972
- return /* @__PURE__ */ jsxs(Flex, { align: "center", children: [
14973
- /* @__PURE__ */ jsx(DiffTooltip, { annotations: annotation ? [annotation] : [], description: action, children: /* @__PURE__ */ jsxs(Flex, { align: "center", children: [
14974
- /* @__PURE__ */ jsx(Checkbox, { checked: !isPresent, color }),
14975
- /* @__PURE__ */ jsx(Box, { margin: 2, children: /* @__PURE__ */ jsx(FromToArrow, {}) }),
14976
- /* @__PURE__ */ jsx(Checkbox, { checked: isPresent, color })
14977
- ] }) }),
14978
- /* @__PURE__ */ jsx(Flex, { align: "center", children: /* @__PURE__ */ jsx(ItemPreview, { value: title || value, memberType }) })
14979
- ] }, getItemKey(diff, index));
14980
- }, $[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;
14981
- } else
14982
- t1 = $[4];
14983
- let t2;
14984
- return $[12] !== t1 ? (t2 = /* @__PURE__ */ jsx("div", { children: t1 }), $[12] = t1, $[13] = t2) : t2 = $[13], t2;
14985
- };
14986
- function normalizeItems$1(item, parentDiff, schemaType) {
14987
- if (item.diff.action === "unchanged")
14988
- return null;
14989
- const {
14990
- fromValue,
14991
- toValue
14992
- } = parentDiff, value = getValue(item.diff), wasPresent = isInArray(value, fromValue), isPresent = isInArray(value, toValue);
14993
- return wasPresent === isPresent ? null : {
14994
- title: getItemTitle(value, schemaType),
14995
- memberType: resolveMemberType(getValue(item.diff), schemaType),
14996
- itemIndex: getOptionIndex(value, schemaType),
14997
- annotation: item.annotation,
14998
- isPresent,
14999
- value
15000
- };
15001
- }
15002
- function sortItems(itemA, itemB) {
15003
- return itemA.itemIndex - itemB.itemIndex;
15004
- }
15005
- function ItemPreview(t0) {
15006
- const $ = c(5), {
15007
- value,
15008
- memberType
15009
- } = t0;
15010
- let t1;
15011
- $[0] !== memberType || $[1] !== value ? (t1 = typeof value == "string" || typeof value == "number" ? value : /* @__PURE__ */ jsx(Preview$1, { schemaType: memberType, value, layout: "default" }), $[0] = memberType, $[1] = value, $[2] = t1) : t1 = $[2];
15012
- let t2;
15013
- return $[3] !== t1 ? (t2 = /* @__PURE__ */ jsx(Box, { marginX: 2, marginY: 1, children: t1 }), $[3] = t1, $[4] = t2) : t2 = $[4], t2;
15014
- }
15015
- function isInArray(value, parent) {
15016
- const array = parent || [];
15017
- return typeof value == "object" && value !== null ? array.some((item) => isEqual$1(item, value)) : array.includes(value);
15018
- }
15019
- function getItemKey(diff, index) {
15020
- const value = diff.toValue || diff.fromValue;
15021
- return isKeyedObject(value) ? value._key : index;
15022
- }
15023
- function getValue(diff) {
15024
- return typeof diff.toValue > "u" ? diff.fromValue : diff.toValue;
15025
- }
15026
- function resolveMemberType(item, schemaType) {
15027
- const itemTypeName = resolveTypeName(item);
15028
- return schemaType.of.find((memberType) => memberType.name === itemTypeName);
15029
- }
15030
- function resolveTypeName(value) {
15031
- const jsType = resolveJSType(value);
15032
- if (jsType !== "object")
15033
- return jsType;
15034
- const obj = value;
15035
- return "_type" in obj && obj._type || jsType;
15036
- }
15037
- function resolveJSType(val) {
15038
- return val === null ? "null" : Array.isArray(val) ? "array" : typeof val;
15039
- }
15040
- function isNamedOption(item) {
15041
- return typeof item == "object" && item !== null && "title" in item;
15042
- }
15043
- function getOptionIndex(item, schemaType) {
15044
- return (schemaType.options?.list || []).findIndex((opt) => isEqual$1(isNamedOption(opt) ? opt.value : opt, item));
15045
- }
15046
- function getItemTitle(item, schemaType) {
15047
- const list = schemaType.options?.list || [], index = getOptionIndex(item, schemaType);
15048
- return index === -1 ? void 0 : list[index].title || void 0;
15049
- }
15050
- function _temp$3U(item_0) {
15051
- return item_0 !== null;
15052
- }
15053
- const SlugWrapper = styled.div`
15054
- display: inline-block;
15055
- word-break: break-all;
15056
- white-space: pre-wrap;
15057
- `, SlugPreview = (props2) => {
15058
- const $ = c(2), {
15059
- value
15060
- } = props2;
15061
- let t0;
15062
- return $[0] !== value.current ? (t0 = /* @__PURE__ */ jsx(Box, { as: SlugWrapper, paddingX: 2, paddingY: 1, children: value.current }), $[0] = value.current, $[1] = t0) : t0 = $[1], t0;
15063
- }, SlugFieldDiff = (t0) => {
15064
- const $ = c(3), {
15065
- diff,
15066
- schemaType
15067
- } = t0;
15068
- let t1;
15069
- return $[0] !== diff || $[1] !== schemaType ? (t1 = /* @__PURE__ */ jsx(DiffFromTo, { layout: "inline", diff, schemaType, previewComponent: SlugPreview }), $[0] = diff, $[1] = schemaType, $[2] = t1) : t1 = $[2], t1;
15070
- }, UrlFieldDiff = (t0) => {
15071
- const $ = c(3), {
15072
- diff,
15073
- schemaType
15074
- } = t0;
15075
- let t1;
15076
- return $[0] !== diff || $[1] !== schemaType ? (t1 = /* @__PURE__ */ jsx(DiffFromTo, { diff, schemaType, previewComponent: StringPreview }), $[0] = diff, $[1] = schemaType, $[2] = t1) : t1 = $[2], t1;
15077
- }, diffResolver = ({
15078
- schemaType
15079
- }) => {
15080
- if (["datetime", "date"].includes(schemaType.name))
15081
- return DatetimeFieldDiff;
15082
- if (schemaType.name === "url")
15083
- return UrlFieldDiff;
15084
- if (schemaType.name === "slug")
15085
- return SlugFieldDiff;
15086
- if (schemaType.jsonType === "array" && Array.isArray(schemaType.options?.list))
15087
- return ArrayOfOptionsFieldDiff;
15088
- }, IGNORE_KEYS = ["_key", "_type", "_weak"];
14954
+ const IGNORE_KEYS = ["_key", "_type", "_weak"];
15089
14955
  function isEmptyItem(value) {
15090
14956
  return Object.keys(value).every((key) => IGNORE_KEYS.includes(key));
15091
14957
  }
@@ -15282,7 +15148,7 @@ function useChildValidation(path, t0) {
15282
15148
  let t1;
15283
15149
  if ($[0] !== inclusive || $[1] !== path || $[2] !== validation2) {
15284
15150
  let t2;
15285
- $[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;
15151
+ $[4] !== inclusive || $[5] !== path ? (t2 = (item) => startsWith(path, item.path) && (inclusive || !isEqual$2(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;
15286
15152
  } else
15287
15153
  t1 = $[3];
15288
15154
  return t1;
@@ -15311,7 +15177,7 @@ function usePortableTextMarkers(path) {
15311
15177
  let t0;
15312
15178
  if ($[0] !== ctx || $[1] !== path) {
15313
15179
  let t1;
15314
- $[3] !== path ? (t1 = (m) => isEqual$3(m.path, path), $[3] = path, $[4] = t1) : t1 = $[4], t0 = ctx.filter(t1), $[0] = ctx, $[1] = path, $[2] = t0;
15180
+ $[3] !== path ? (t1 = (m) => isEqual$2(m.path, path), $[3] = path, $[4] = t1) : t1 = $[4], t0 = ctx.filter(t1), $[0] = ctx, $[1] = path, $[2] = t0;
15315
15181
  } else
15316
15182
  t0 = $[2];
15317
15183
  return t0;
@@ -15476,7 +15342,7 @@ function usePortableTextMemberItemsFromProps(props2) {
15476
15342
  return;
15477
15343
  }
15478
15344
  objectFormRenderInputProps.onChange(patch2);
15479
- }, _renderInput = (renderInputProps_0) => isEqual$3(renderInputProps_0.path, item.member.item.path) ? renderInput({
15345
+ }, _renderInput = (renderInputProps_0) => isEqual$2(renderInputProps_0.path, item.member.item.path) ? renderInput({
15480
15346
  ...renderInputProps_0,
15481
15347
  onChange: _onChangeDisableRemoveSelf(renderInputProps_0),
15482
15348
  onPathFocus: _onPathFocus,
@@ -15602,7 +15468,7 @@ function Annotation(props2) {
15602
15468
  let t8;
15603
15469
  if ($[25] !== path || $[26] !== presence) {
15604
15470
  let t92;
15605
- $[28] !== path ? (t92 = (p) => isEqual$3(p.path, path), $[28] = path, $[29] = t92) : t92 = $[29], t8 = presence.filter(t92), $[25] = path, $[26] = presence, $[27] = t8;
15471
+ $[28] !== path ? (t92 = (p) => isEqual$2(p.path, path), $[28] = path, $[29] = t92) : t92 = $[29], t8 = presence.filter(t92), $[25] = path, $[26] = presence, $[27] = t8;
15606
15472
  } else
15607
15473
  t8 = $[27];
15608
15474
  const rootPresence = t8, isOpen = !!memberItem?.member.open, input = memberItem?.input, nodePath = memberItem?.node.path || EMPTY_ARRAY$z, referenceElement = spanElement, t9 = schemaTypes.block, t10 = !!readOnly, t11 = markersToolTip || text;
@@ -18748,7 +18614,7 @@ function createDescriptionId(id2, description) {
18748
18614
  return `desc_${id2}`;
18749
18615
  }
18750
18616
  const getMemberTypeOfItem$2 = (schemaType, item) => {
18751
- const itemTypeName = resolveTypeName$2(item);
18617
+ const itemTypeName = resolveTypeName$1(item);
18752
18618
  return schemaType.of.find((memberType) => memberType.name === itemTypeName);
18753
18619
  };
18754
18620
  function assign(values2, path) {
@@ -19061,7 +18927,7 @@ function IncompatibleItemType$2(props2) {
19061
18927
  }, $[7] = t3) : t3 = $[7];
19062
18928
  const handleShowDetails = t3;
19063
18929
  let t4;
19064
- $[8] !== value ? (t4 = resolveTypeName$2(value), $[8] = value, $[9] = t4) : t4 = $[9];
18930
+ $[8] !== value ? (t4 = resolveTypeName$1(value), $[8] = value, $[9] = t4) : t4 = $[9];
19065
18931
  const typeName = t4;
19066
18932
  let t5;
19067
18933
  $[10] !== typeName ? (t5 = {
@@ -22996,7 +22862,7 @@ function IncompatibleItemType$1(props2) {
22996
22862
  }, $[7] = t3) : t3 = $[7];
22997
22863
  const handleShowDetails = t3;
22998
22864
  let t4;
22999
- $[8] !== value ? (t4 = resolveTypeName$2(value), $[8] = value, $[9] = t4) : t4 = $[9];
22865
+ $[8] !== value ? (t4 = resolveTypeName$1(value), $[8] = value, $[9] = t4) : t4 = $[9];
23000
22866
  const typeName = t4;
23001
22867
  let t5;
23002
22868
  $[10] !== t ? (t5 = t("inputs.array.error.type-is-incompatible-title"), $[10] = t, $[11] = t5) : t5 = $[11];
@@ -23145,7 +23011,7 @@ function useSearchableList(items) {
23145
23011
  let t2;
23146
23012
  $[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = (item) => {
23147
23013
  const path = item.path;
23148
- setSearchableList((prev) => prev.some((prevItem) => isEqual$2(prevItem.path, path)) ? prev.map((prevItem_0) => isEqual$2(prevItem_0.path, path) ? {
23014
+ setSearchableList((prev) => prev.some((prevItem) => isEqual$1(prevItem.path, path)) ? prev.map((prevItem_0) => isEqual$1(prevItem_0.path, path) ? {
23149
23015
  ...item,
23150
23016
  title: item?.title
23151
23017
  } : prevItem_0) : prev.concat(item));
@@ -23401,7 +23267,7 @@ function DialogBreadcrumbs$1(props2) {
23401
23267
  ] }) }, overflowItem.path.toString())) }) }),
23402
23268
  showSeparator && /* @__PURE__ */ jsx(SeparatorItem$1, { children: SEPARATOR$1 })
23403
23269
  ] }, key);
23404
- const isSelected = isEqual$2(item.path, selectedPath), isLast = index === items.length - 1;
23270
+ const isSelected = isEqual$1(item.path, selectedPath), isLast = index === items.length - 1;
23405
23271
  return /* @__PURE__ */ jsxs(Inline, { flex: isLast ? 1 : void 0, style: {
23406
23272
  minWidth: 0
23407
23273
  }, children: [
@@ -24392,14 +24258,14 @@ function FormInputInner(props2) {
24392
24258
  t
24393
24259
  } = useTranslation();
24394
24260
  let t0;
24395
- $[0] !== absolutePath || $[1] !== destinationRenderField || $[2] !== props2.includeField ? (t0 = (fieldProps) => (isEqual$3(absolutePath, fieldProps.path) ? props2.includeField : startsWith(absolutePath, fieldProps.path)) ? destinationRenderField(fieldProps) : pass(fieldProps), $[0] = absolutePath, $[1] = destinationRenderField, $[2] = props2.includeField, $[3] = t0) : t0 = $[3];
24261
+ $[0] !== absolutePath || $[1] !== destinationRenderField || $[2] !== props2.includeField ? (t0 = (fieldProps) => (isEqual$2(absolutePath, fieldProps.path) ? props2.includeField : startsWith(absolutePath, fieldProps.path)) ? destinationRenderField(fieldProps) : pass(fieldProps), $[0] = absolutePath, $[1] = destinationRenderField, $[2] = props2.includeField, $[3] = t0) : t0 = $[3];
24396
24262
  const renderField = t0;
24397
24263
  let t1;
24398
- $[4] !== absolutePath || $[5] !== destinationRenderItem || $[6] !== props2.includeItem ? (t1 = (itemProps) => (isEqual$3(absolutePath, itemProps.path) ? props2.includeItem : startsWith(absolutePath, itemProps.path)) ? destinationRenderItem(itemProps) : pass(itemProps), $[4] = absolutePath, $[5] = destinationRenderItem, $[6] = props2.includeItem, $[7] = t1) : t1 = $[7];
24264
+ $[4] !== absolutePath || $[5] !== destinationRenderItem || $[6] !== props2.includeItem ? (t1 = (itemProps) => (isEqual$2(absolutePath, itemProps.path) ? props2.includeItem : startsWith(absolutePath, itemProps.path)) ? destinationRenderItem(itemProps) : pass(itemProps), $[4] = absolutePath, $[5] = destinationRenderItem, $[6] = props2.includeItem, $[7] = t1) : t1 = $[7];
24399
24265
  const renderItem2 = t1;
24400
24266
  let t2;
24401
24267
  $[8] !== absolutePath || $[9] !== destinationRenderAnnotation || $[10] !== destinationRenderBlock || $[11] !== destinationRenderField || $[12] !== destinationRenderInlineBlock || $[13] !== destinationRenderInput || $[14] !== destinationRenderItem || $[15] !== destinationRenderPreview || $[16] !== props2.includeField || $[17] !== props2.includeItem ? (t2 = (inputProps) => {
24402
- if (isEqual$3(inputProps.path, absolutePath) || startsWith(absolutePath, inputProps.path))
24268
+ if (isEqual$2(inputProps.path, absolutePath) || startsWith(absolutePath, inputProps.path))
24403
24269
  return destinationRenderInput(inputProps);
24404
24270
  if (!isObjectInputProps(inputProps) && !isArrayInputProps(inputProps))
24405
24271
  throw new Error(`Expected either object input props or array input props for: ${JSON.stringify(inputProps.path)}`);
@@ -24407,13 +24273,13 @@ function FormInputInner(props2) {
24407
24273
  }, $[8] = absolutePath, $[9] = destinationRenderAnnotation, $[10] = destinationRenderBlock, $[11] = destinationRenderField, $[12] = destinationRenderInlineBlock, $[13] = destinationRenderInput, $[14] = destinationRenderItem, $[15] = destinationRenderPreview, $[16] = props2.includeField, $[17] = props2.includeItem, $[18] = t2) : t2 = $[18];
24408
24274
  const renderInput = t2;
24409
24275
  let t3;
24410
- $[19] !== absolutePath || $[20] !== destinationRenderBlock || $[21] !== props2.includeItem ? (t3 = (blockProps) => startsWith(absolutePath, blockProps.path) && (props2.includeItem || !isEqual$3(absolutePath, blockProps.path)) ? destinationRenderBlock(blockProps) : pass(blockProps), $[19] = absolutePath, $[20] = destinationRenderBlock, $[21] = props2.includeItem, $[22] = t3) : t3 = $[22];
24276
+ $[19] !== absolutePath || $[20] !== destinationRenderBlock || $[21] !== props2.includeItem ? (t3 = (blockProps) => startsWith(absolutePath, blockProps.path) && (props2.includeItem || !isEqual$2(absolutePath, blockProps.path)) ? destinationRenderBlock(blockProps) : pass(blockProps), $[19] = absolutePath, $[20] = destinationRenderBlock, $[21] = props2.includeItem, $[22] = t3) : t3 = $[22];
24411
24277
  const renderBlock2 = t3;
24412
24278
  let t4;
24413
- $[23] !== absolutePath || $[24] !== destinationRenderInlineBlock || $[25] !== props2.includeItem ? (t4 = (blockProps_0) => startsWith(absolutePath, blockProps_0.path) && (props2.includeItem || !isEqual$3(absolutePath, blockProps_0.path)) ? destinationRenderInlineBlock(blockProps_0) : pass(blockProps_0), $[23] = absolutePath, $[24] = destinationRenderInlineBlock, $[25] = props2.includeItem, $[26] = t4) : t4 = $[26];
24279
+ $[23] !== absolutePath || $[24] !== destinationRenderInlineBlock || $[25] !== props2.includeItem ? (t4 = (blockProps_0) => startsWith(absolutePath, blockProps_0.path) && (props2.includeItem || !isEqual$2(absolutePath, blockProps_0.path)) ? destinationRenderInlineBlock(blockProps_0) : pass(blockProps_0), $[23] = absolutePath, $[24] = destinationRenderInlineBlock, $[25] = props2.includeItem, $[26] = t4) : t4 = $[26];
24414
24280
  const renderInlineBlock = t4;
24415
24281
  let t5;
24416
- $[27] !== absolutePath || $[28] !== destinationRenderAnnotation || $[29] !== props2.includeItem ? (t5 = (annotationProps) => startsWith(absolutePath, annotationProps.path) && (props2.includeItem || !isEqual$3(absolutePath, annotationProps.path)) ? destinationRenderAnnotation(annotationProps) : pass(annotationProps), $[27] = absolutePath, $[28] = destinationRenderAnnotation, $[29] = props2.includeItem, $[30] = t5) : t5 = $[30];
24282
+ $[27] !== absolutePath || $[28] !== destinationRenderAnnotation || $[29] !== props2.includeItem ? (t5 = (annotationProps) => startsWith(absolutePath, annotationProps.path) && (props2.includeItem || !isEqual$2(absolutePath, annotationProps.path)) ? destinationRenderAnnotation(annotationProps) : pass(annotationProps), $[27] = absolutePath, $[28] = destinationRenderAnnotation, $[29] = props2.includeItem, $[30] = t5) : t5 = $[30];
24417
24283
  const renderAnnotation = t5;
24418
24284
  if (isArrayInputProps(props2)) {
24419
24285
  let t6;
@@ -24551,11 +24417,11 @@ function useFullscreenPTE() {
24551
24417
  return useContext(FullscreenPTEContext);
24552
24418
  }
24553
24419
  function getItemType(arrayType, item) {
24554
- const itemTypeName = resolveTypeName$2(item);
24420
+ const itemTypeName = resolveTypeName$1(item);
24555
24421
  return itemTypeName === "object" && arrayType.of.length === 1 ? arrayType.of[0] : arrayType.of.find((memberType) => memberType.name === itemTypeName);
24556
24422
  }
24557
24423
  function getPrimitiveItemType(arrayType, item) {
24558
- const itemTypeName = resolveTypeName$2(item);
24424
+ const itemTypeName = resolveTypeName$1(item);
24559
24425
  return arrayType?.of.find((memberType) => memberType.name === itemTypeName || memberType.jsonType === itemTypeName);
24560
24426
  }
24561
24427
  function isArrayItemSelected(itemPath, path) {
@@ -25278,7 +25144,7 @@ function TreeEditingSearchMenu(props2) {
25278
25144
  } = useTranslation();
25279
25145
  let t0;
25280
25146
  $[0] !== items[0].path || $[1] !== onPathSelect ? (t0 = (item) => {
25281
- const isFirst = isEqual$2(item.path, items[0].path);
25147
+ const isFirst = isEqual$1(item.path, items[0].path);
25282
25148
  return /* @__PURE__ */ jsx(ResultItem, { isFirst, item, onPathSelect });
25283
25149
  }, $[0] = items[0].path, $[1] = onPathSelect, $[2] = t0) : t0 = $[2];
25284
25150
  const renderItem2 = t0;
@@ -25376,7 +25242,7 @@ function getSiblingHasChildren(items) {
25376
25242
  return items.some((sibling) => sibling.children && sibling.children.length > 0);
25377
25243
  }
25378
25244
  function hasOpenChild(item, selectedPath) {
25379
- return item.children?.some((child) => isEqual$2(child.path, selectedPath) || hasOpenChild(child, selectedPath)) || !1;
25245
+ return item.children?.some((child) => isEqual$1(child.path, selectedPath) || hasOpenChild(child, selectedPath)) || !1;
25380
25246
  }
25381
25247
  const SCROLL_BEHAVIOR_OPTIONS = {
25382
25248
  block: "center",
@@ -25460,7 +25326,7 @@ function TreeEditingMenuItem(props2) {
25460
25326
  value
25461
25327
  } = useValuePreviewWithFallback(t0);
25462
25328
  let t1;
25463
- $[3] !== item.path || $[4] !== selectedPath ? (t1 = isEqual$2(item.path, selectedPath), $[3] = item.path, $[4] = selectedPath, $[5] = t1) : t1 = $[5];
25329
+ $[3] !== item.path || $[4] !== selectedPath ? (t1 = isEqual$1(item.path, selectedPath), $[3] = item.path, $[4] = selectedPath, $[5] = t1) : t1 = $[5];
25464
25330
  const selected = t1, isArrayParent = !isArrayItemPath(item.path);
25465
25331
  let t2;
25466
25332
  $[6] !== item.path ? (t2 = toString(item.path), $[6] = item.path, $[7] = t2) : t2 = $[7];
@@ -26180,7 +26046,7 @@ function IncompatibleItemType(props2) {
26180
26046
  }, $[7] = t3) : t3 = $[7];
26181
26047
  const handleShowDetails = t3;
26182
26048
  let t4;
26183
- $[8] !== value ? (t4 = resolveTypeName$2(value), $[8] = value, $[9] = t4) : t4 = $[9];
26049
+ $[8] !== value ? (t4 = resolveTypeName$1(value), $[8] = value, $[9] = t4) : t4 = $[9];
26184
26050
  const typeName = t4;
26185
26051
  let t5;
26186
26052
  $[10] !== t ? (t5 = t("inputs.array.error.type-is-incompatible-title"), $[10] = t, $[11] = t5) : t5 = $[11];
@@ -26457,7 +26323,7 @@ function inArray(array, candidate) {
26457
26323
  return array ? array.some((item) => isEqual(item, candidate)) : !1;
26458
26324
  }
26459
26325
  function getMemberTypeOfItem$1(schemaType, item) {
26460
- return schemaType.of.find((memberType) => memberType.name === resolveTypeName$2(item));
26326
+ return schemaType.of.find((memberType) => memberType.name === resolveTypeName$1(item));
26461
26327
  }
26462
26328
  const EMPTY_ARRAY$m = [];
26463
26329
  function ArrayOfObjectOptionsInput(props2) {
@@ -26535,7 +26401,7 @@ function normalizeOptions(options) {
26535
26401
  });
26536
26402
  }
26537
26403
  function getMemberTypeOfItem(schemaType, option) {
26538
- return schemaType.of.find((memberType) => memberType.name === resolveTypeName$2(option.value));
26404
+ return schemaType.of.find((memberType) => memberType.name === resolveTypeName$1(option.value));
26539
26405
  }
26540
26406
  function ArrayOfPrimitiveOptionsInput(props2) {
26541
26407
  const $ = c(31), {
@@ -29958,7 +29824,7 @@ function TextBlock(props2) {
29958
29824
  let t4;
29959
29825
  if ($[8] !== path || $[9] !== presence) {
29960
29826
  let t52;
29961
- $[11] !== path ? (t52 = (p) => isEqual$3(p.path, path) || p.path.slice(-3)[1] === "children" && p.path.length - path.length === 2, $[11] = path, $[12] = t52) : t52 = $[12], t4 = presence.filter(t52), $[8] = path, $[9] = presence, $[10] = t4;
29827
+ $[11] !== path ? (t52 = (p) => isEqual$2(p.path, path) || p.path.slice(-3)[1] === "children" && p.path.length - path.length === 2, $[11] = path, $[12] = t52) : t52 = $[12], t4 = presence.filter(t52), $[8] = path, $[9] = presence, $[10] = t4;
29962
29828
  } else
29963
29829
  t4 = $[10];
29964
29830
  const textPresence = t4, {
@@ -31405,7 +31271,7 @@ function useTrackFocusPath(props2) {
31405
31271
  } = props2, portableTextMemberItems = usePortableTextMemberItems(), elementRefs = usePortableTextMemberItemElementRefs(), editor2 = usePortableTextEditor(), selection = usePortableTextEditorSelection();
31406
31272
  let t0;
31407
31273
  $[0] !== boundaryElement || $[1] !== editor2 || $[2] !== elementRefs || $[3] !== focusPath || $[4] !== portableTextMemberItems || $[5] !== selection ? (t0 = () => {
31408
- if (focusPath.length === 0 || selection?.focus.path && isEqual$3(selection.focus.path, focusPath.slice(0, selection.focus.path.length)))
31274
+ if (focusPath.length === 0 || selection?.focus.path && isEqual$2(selection.focus.path, focusPath.slice(0, selection.focus.path.length)))
31409
31275
  return;
31410
31276
  const focusedItem = portableTextMemberItems.find(_temp$2P), openItem = portableTextMemberItems.find(_temp2$19), relatedEditorItem = focusedItem || openItem, elementRef = relatedEditorItem ? elementRefs[relatedEditorItem.member.key] : void 0;
31411
31277
  if (relatedEditorItem && elementRef) {
@@ -31936,7 +31802,7 @@ const InlineObject = (props2) => {
31936
31802
  let t5;
31937
31803
  if ($[15] !== path || $[16] !== presence) {
31938
31804
  let t62;
31939
- $[18] !== path ? (t62 = (p) => isEqual$3(p.path, path), $[18] = path, $[19] = t62) : t62 = $[19], t5 = presence.filter(t62), $[15] = path, $[16] = presence, $[17] = t5;
31805
+ $[18] !== path ? (t62 = (p) => isEqual$2(p.path, path), $[18] = path, $[19] = t62) : t62 = $[19], t5 = presence.filter(t62), $[15] = path, $[16] = presence, $[17] = t5;
31940
31806
  } else
31941
31807
  t5 = $[17];
31942
31808
  const rootPresence = t5;
@@ -32914,8 +32780,8 @@ function usePresenceCursorDecorations(props2) {
32914
32780
  const handleRangeDecorationMoved = t2;
32915
32781
  let t3, t4;
32916
32782
  $[3] !== fieldPresence || $[4] !== path ? (t3 = () => {
32917
- const nextPresence = fieldPresence.filter((p_0) => startsWith(path, p_0.path) && !isEqual$2(path, p_0.path)), filteredNext = nextPresence.map(_temp$2K), filteredPrevious = previousPresence.current.map(_temp2$16);
32918
- if (!isEqual$2(filteredNext, filteredPrevious)) {
32783
+ const nextPresence = fieldPresence.filter((p_0) => startsWith(path, p_0.path) && !isEqual$1(path, p_0.path)), filteredNext = nextPresence.map(_temp$2K), filteredPrevious = previousPresence.current.map(_temp2$16);
32784
+ if (!isEqual$1(filteredNext, filteredPrevious)) {
32919
32785
  const value = nextPresence.length > 0 ? nextPresence : EMPTY_ARRAY$z;
32920
32786
  setCurrentPresence(value), previousPresence.current = value;
32921
32787
  }
@@ -41067,7 +40933,7 @@ function _temp$2o(item_1, i) {
41067
40933
  return /* @__PURE__ */ jsx("option", { value: i - 1, children: item_1.title }, `${i - 1}`);
41068
40934
  }
41069
40935
  const RadioSelect = forwardRef(function(props2, ref) {
41070
- const $ = c(12), {
40936
+ const $ = c(22), {
41071
40937
  items,
41072
40938
  value,
41073
40939
  onChange,
@@ -41076,13 +40942,29 @@ const RadioSelect = forwardRef(function(props2, ref) {
41076
40942
  customValidity,
41077
40943
  direction,
41078
40944
  inputId
41079
- } = props2, Layout2 = direction === "horizontal" ? Inline : Stack;
40945
+ } = props2, {
40946
+ t
40947
+ } = useTranslation();
41080
40948
  let t0;
41081
- $[0] !== customValidity || $[1] !== inputId || $[2] !== items || $[3] !== onChange || $[4] !== onFocus || $[5] !== readOnly || $[6] !== ref || $[7] !== value ? (t0 = items.map((item, index) => /* @__PURE__ */ jsx(RadioSelectItem, { customValidity, inputId, item, onChange, onFocus, readOnly, ref: index === 0 ? ref : null, value }, index)), $[0] = customValidity, $[1] = inputId, $[2] = items, $[3] = onChange, $[4] = onFocus, $[5] = readOnly, $[6] = ref, $[7] = value, $[8] = t0) : t0 = $[8];
41082
- let t1;
41083
- return $[9] !== Layout2 || $[10] !== t0 ? (t1 = /* @__PURE__ */ jsx(Card, { border: !0, padding: 3, radius: 2, children: /* @__PURE__ */ jsx(Layout2, { space: 3, role: "group", children: t0 }) }), $[9] = Layout2, $[10] = t0, $[11] = t1) : t1 = $[11], t1;
40949
+ $[0] !== onChange ? (t0 = () => {
40950
+ onChange(null);
40951
+ }, $[0] = onChange, $[1] = t0) : t0 = $[1];
40952
+ const handleClear = t0, isHorizontal = direction === "horizontal", Layout2 = isHorizontal ? Inline : Stack, showClearButton = !readOnly && value, t1 = isHorizontal ? "center" : "flex-end";
40953
+ let t2;
40954
+ $[2] !== customValidity || $[3] !== inputId || $[4] !== items || $[5] !== onChange || $[6] !== onFocus || $[7] !== readOnly || $[8] !== ref || $[9] !== value ? (t2 = items.map((item, index) => /* @__PURE__ */ jsx(RadioSelectItem, { customValidity, inputId, item, onChange, onFocus, readOnly, ref: index === 0 ? ref : null, value }, index)), $[2] = customValidity, $[3] = inputId, $[4] = items, $[5] = onChange, $[6] = onFocus, $[7] = readOnly, $[8] = ref, $[9] = value, $[10] = t2) : t2 = $[10];
40955
+ let t3;
40956
+ $[11] !== Layout2 || $[12] !== t2 ? (t3 = /* @__PURE__ */ jsx(Layout2, { space: 3, role: "group", paddingY: 1, children: t2 }), $[11] = Layout2, $[12] = t2, $[13] = t3) : t3 = $[13];
40957
+ let t4;
40958
+ $[14] !== handleClear || $[15] !== showClearButton || $[16] !== t ? (t4 = showClearButton && /* @__PURE__ */ jsx(Button, { icon: ResetIcon, onClick: handleClear, tooltipProps: {
40959
+ content: t("inputs.select.action.clear")
40960
+ }, mode: "bleed" }), $[14] = handleClear, $[15] = showClearButton, $[16] = t, $[17] = t4) : t4 = $[17];
40961
+ let t5;
40962
+ return $[18] !== t1 || $[19] !== t3 || $[20] !== t4 ? (t5 = /* @__PURE__ */ jsx(Card, { border: !0, paddingY: 2, paddingX: 3, radius: 2, children: /* @__PURE__ */ jsxs(Flex, { align: t1, gap: 3, justify: "space-between", children: [
40963
+ t3,
40964
+ t4
40965
+ ] }) }), $[18] = t1, $[19] = t3, $[20] = t4, $[21] = t5) : t5 = $[21], t5;
41084
40966
  }), RadioSelectItem = forwardRef(function(props2, ref) {
41085
- const $ = c(16), {
40967
+ const $ = c(17), {
41086
40968
  customValidity,
41087
40969
  inputId,
41088
40970
  item,
@@ -41095,16 +40977,17 @@ const RadioSelect = forwardRef(function(props2, ref) {
41095
40977
  $[0] !== item || $[1] !== onChange ? (t0 = () => {
41096
40978
  onChange(item);
41097
40979
  }, $[0] = item, $[1] = onChange, $[2] = t0) : t0 = $[2];
41098
- const handleChange = t0, t1 = value === item;
41099
- let t2;
41100
- $[3] !== customValidity || $[4] !== handleChange || $[5] !== inputId || $[6] !== onFocus || $[7] !== readOnly || $[8] !== ref || $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Radio, { ref, checked: t1, onChange: handleChange, onFocus, readOnly, customValidity, name: inputId }), $[3] = customValidity, $[4] = handleChange, $[5] = inputId, $[6] = onFocus, $[7] = readOnly, $[8] = ref, $[9] = t1, $[10] = t2) : t2 = $[10];
40980
+ const handleChange = t0, checked = value === item;
40981
+ let t1;
40982
+ $[3] !== checked || $[4] !== customValidity || $[5] !== handleChange || $[6] !== inputId || $[7] !== onFocus || $[8] !== readOnly || $[9] !== ref ? (t1 = /* @__PURE__ */ jsx(Radio, { ref, checked, onChange: handleChange, onFocus, readOnly, customValidity, name: inputId }), $[3] = checked, $[4] = customValidity, $[5] = handleChange, $[6] = inputId, $[7] = onFocus, $[8] = readOnly, $[9] = ref, $[10] = t1) : t1 = $[10];
40983
+ const t2 = checked ? "medium" : "regular";
41101
40984
  let t3;
41102
- $[11] !== item.title ? (t3 = /* @__PURE__ */ jsx(Box, { marginLeft: 2, children: /* @__PURE__ */ jsx(Text$1, { size: 1, weight: "medium", children: item.title }) }), $[11] = item.title, $[12] = t3) : t3 = $[12];
40985
+ $[11] !== item.title || $[12] !== t2 ? (t3 = /* @__PURE__ */ jsx(Box, { marginLeft: 2, children: /* @__PURE__ */ jsx(Text$1, { size: 1, weight: t2, children: item.title }) }), $[11] = item.title, $[12] = t2, $[13] = t3) : t3 = $[13];
41103
40986
  let t4;
41104
- return $[13] !== t2 || $[14] !== t3 ? (t4 = /* @__PURE__ */ jsxs(Flex, { as: "label", align: "center", children: [
41105
- t2,
40987
+ return $[14] !== t1 || $[15] !== t3 ? (t4 = /* @__PURE__ */ jsxs(Flex, { as: "label", align: "center", children: [
40988
+ t1,
41106
40989
  t3
41107
- ] }), $[13] = t2, $[14] = t3, $[15] = t4) : t4 = $[15], t4;
40990
+ ] }), $[14] = t1, $[15] = t3, $[16] = t4) : t4 = $[16], t4;
41108
40991
  });
41109
40992
  function resolveNumberInput(type) {
41110
40993
  return getOption(type, "list") ? SelectInput : NumberInput;
@@ -41627,7 +41510,7 @@ function everyItemHasKey(array) {
41627
41510
  return array?.every((item) => isRecord$4(item) && hasKey(item));
41628
41511
  }
41629
41512
  function isChangedValue(value, comparisonValue) {
41630
- return Array.isArray(value) && typeof comparisonValue > "u" || Array.isArray(comparisonValue) && typeof value > "u" ? !1 : value && !comparisonValue ? !0 : !isEqual$2(value, comparisonValue);
41513
+ return Array.isArray(value) && typeof comparisonValue > "u" || Array.isArray(comparisonValue) && typeof value > "u" ? !1 : value && !comparisonValue ? !0 : !isEqual$1(value, comparisonValue);
41631
41514
  }
41632
41515
  function createPrepareFormState({
41633
41516
  decorators = {}
@@ -41844,7 +41727,7 @@ function createPrepareFormState({
41844
41727
  error: {
41845
41728
  type: "INCOMPATIBLE_TYPE",
41846
41729
  expectedSchemaType: field.type,
41847
- resolvedValueType: resolveTypeName$2(fieldValue),
41730
+ resolvedValueType: resolveTypeName$1(fieldValue),
41848
41731
  value: fieldValue
41849
41732
  }
41850
41733
  };
@@ -41897,7 +41780,7 @@ function createPrepareFormState({
41897
41780
  if (isArrayOfObjectsSchemaType(field.type)) {
41898
41781
  const hasValue2 = typeof fieldValue < "u";
41899
41782
  if (hasValue2 && !isValidArrayOfObjectsValue(fieldValue)) {
41900
- const resolvedValueType = resolveTypeName$2(fieldValue);
41783
+ const resolvedValueType = resolveTypeName$1(fieldValue);
41901
41784
  return {
41902
41785
  kind: "error",
41903
41786
  key: field.name,
@@ -41981,7 +41864,7 @@ function createPrepareFormState({
41981
41864
  };
41982
41865
  } else {
41983
41866
  if (!isValidArrayOfPrimitivesValue(fieldValue)) {
41984
- const resolvedValueType = resolveTypeName$2(fieldValue);
41867
+ const resolvedValueType = resolveTypeName$1(fieldValue);
41985
41868
  return {
41986
41869
  kind: "error",
41987
41870
  key: field.name,
@@ -42129,7 +42012,7 @@ function createPrepareFormState({
42129
42012
  columns: fieldSet?.options?.columns
42130
42013
  }
42131
42014
  }];
42132
- }), hasFieldGroups = schemaTypeGroupConfig.length > 0, filteredPresence = props2.presence.filter((item) => isEqual$3(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$3(item.path, props2.path)).map((v) => ({
42015
+ }), hasFieldGroups = schemaTypeGroupConfig.length > 0, filteredPresence = props2.presence.filter((item) => isEqual$2(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$2(item.path, props2.path)).map((v) => ({
42133
42016
  level: v.level,
42134
42017
  message: v.message,
42135
42018
  path: v.path
@@ -42158,7 +42041,7 @@ function createPrepareFormState({
42158
42041
  path: props2.path,
42159
42042
  id: toString(props2.path),
42160
42043
  level: props2.level,
42161
- focused: isEqual$3(props2.path, props2.focusPath),
42044
+ focused: isEqual$2(props2.path, props2.focusPath),
42162
42045
  focusPath: trimChildPath$1(props2.path, props2.focusPath),
42163
42046
  presence,
42164
42047
  validation: validation2,
@@ -42178,7 +42061,7 @@ function createPrepareFormState({
42178
42061
  }), prepareArrayOfPrimitivesInputState = memoizePrepareArrayOfPrimitivesInputState(function(props2) {
42179
42062
  if (props2.level === MAX_FIELD_DEPTH || props2.hidden === !0 || props2.hidden?.value)
42180
42063
  return null;
42181
- const items = Array.isArray(props2.value) ? props2.value : [], filteredPresence = props2.presence.filter((item) => isEqual$3(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$3(item.path, props2.path)).map((v) => ({
42064
+ const items = Array.isArray(props2.value) ? props2.value : [], filteredPresence = props2.presence.filter((item) => isEqual$2(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$2(item.path, props2.path)).map((v) => ({
42182
42065
  level: v.level,
42183
42066
  message: v.message,
42184
42067
  path: v.path
@@ -42191,7 +42074,7 @@ function createPrepareFormState({
42191
42074
  value: props2.value,
42192
42075
  readOnly: props2.readOnly === !0 || props2.readOnly?.value,
42193
42076
  schemaType: props2.schemaType,
42194
- focused: isEqual$3(props2.path, props2.focusPath),
42077
+ focused: isEqual$2(props2.path, props2.focusPath),
42195
42078
  focusPath: trimChildPath$1(props2.path, props2.focusPath),
42196
42079
  path: props2.path,
42197
42080
  perspective: props2.perspective,
@@ -42209,7 +42092,7 @@ function createPrepareFormState({
42209
42092
  }), prepareArrayOfObjectsInputState = memoizePrepareArrayOfObjectsInputState(function(props2) {
42210
42093
  if (props2.level === MAX_FIELD_DEPTH || props2.hidden === !0 || props2.hidden?.value)
42211
42094
  return null;
42212
- const items = Array.isArray(props2.value) ? props2.value : [], filteredPresence = props2.presence.filter((item) => isEqual$3(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$3(item.path, props2.path)).map((v) => ({
42095
+ const items = Array.isArray(props2.value) ? props2.value : [], filteredPresence = props2.presence.filter((item) => isEqual$2(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$2(item.path, props2.path)).map((v) => ({
42213
42096
  level: v.level,
42214
42097
  message: v.message,
42215
42098
  path: v.path
@@ -42223,7 +42106,7 @@ function createPrepareFormState({
42223
42106
  perspective: props2.perspective,
42224
42107
  readOnly: props2.readOnly === !0 || props2.readOnly?.value,
42225
42108
  schemaType: props2.schemaType,
42226
- focused: isEqual$3(props2.path, props2.focusPath),
42109
+ focused: isEqual$2(props2.path, props2.focusPath),
42227
42110
  focusPath: trimChildPath$1(props2.path, props2.focusPath),
42228
42111
  path: props2.path,
42229
42112
  id: toString(props2.path),
@@ -42245,7 +42128,7 @@ function createPrepareFormState({
42245
42128
  index
42246
42129
  } = props2, itemType = getItemType(parent.schemaType, arrayItem), key = arrayItem._key;
42247
42130
  if (!itemType) {
42248
- const itemTypeName = resolveTypeName$2(arrayItem);
42131
+ const itemTypeName = resolveTypeName$1(arrayItem);
42249
42132
  return {
42250
42133
  kind: "error",
42251
42134
  key,
@@ -42305,7 +42188,7 @@ function createPrepareFormState({
42305
42188
  error: {
42306
42189
  type: "INVALID_ITEM_TYPE",
42307
42190
  validTypes: parent.schemaType.of,
42308
- resolvedValueType: resolveTypeName$2(itemType),
42191
+ resolvedValueType: resolveTypeName$1(itemType),
42309
42192
  value: itemValue
42310
42193
  }
42311
42194
  };
@@ -42323,11 +42206,11 @@ function createPrepareFormState({
42323
42206
  key,
42324
42207
  index,
42325
42208
  parentSchemaType: parent.schemaType,
42326
- open: isEqual$3(itemPath, parent.openPath),
42209
+ open: isEqual$2(itemPath, parent.openPath),
42327
42210
  item
42328
42211
  };
42329
42212
  }), preparePrimitiveInputState = memoizePreparePrimitiveInputState(function(props2) {
42330
- const filteredPresence = props2.presence.filter((item) => isEqual$3(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$3(item.path, props2.path)).map((v) => ({
42213
+ const filteredPresence = props2.presence.filter((item) => isEqual$2(item.path, props2.path)), presence = filteredPresence.length ? filteredPresence : EMPTY_ARRAY$z, validation2 = props2.validation.filter((item) => isEqual$2(item.path, props2.path)).map((v) => ({
42331
42214
  level: v.level,
42332
42215
  message: v.message,
42333
42216
  path: v.path
@@ -42338,7 +42221,7 @@ function createPrepareFormState({
42338
42221
  level: props2.level,
42339
42222
  id: toString(props2.path),
42340
42223
  readOnly: props2.readOnly === !0 || props2.readOnly?.value,
42341
- focused: isEqual$3(props2.path, props2.focusPath),
42224
+ focused: isEqual$2(props2.path, props2.focusPath),
42342
42225
  path: props2.path,
42343
42226
  perspective: props2.perspective,
42344
42227
  presence,
@@ -43393,7 +43276,7 @@ function BlockObject(props2) {
43393
43276
  let t9;
43394
43277
  if ($[25] !== path || $[26] !== presence) {
43395
43278
  let t102;
43396
- $[28] !== path ? (t102 = (p) => isEqual$3(p.path, path), $[28] = path, $[29] = t102) : t102 = $[29], t9 = presence.filter(t102), $[25] = path, $[26] = presence, $[27] = t9;
43279
+ $[28] !== path ? (t102 = (p) => isEqual$2(p.path, path), $[28] = path, $[29] = t102) : t102 = $[29], t9 = presence.filter(t102), $[25] = path, $[26] = presence, $[27] = t9;
43397
43280
  } else
43398
43281
  t9 = $[27];
43399
43282
  const rootPresence = t9, tooltipEnabled = hasError || hasWarning || hasInfo || hasMarkers;
@@ -47329,7 +47212,7 @@ function ReleaseTypePicker(props2) {
47329
47212
  }
47330
47213
  }
47331
47214
  };
47332
- isEqual$2(newRelease, release) || (getIsScheduledDateInPast(newRelease) ? (setReleaseType(release.metadata.releaseType), setIntendedPublishAt(release.metadata.intendedPublishAt ? new Date(release.metadata.intendedPublishAt) : void 0), toast.push({
47215
+ isEqual$1(newRelease, release) || (getIsScheduledDateInPast(newRelease) ? (setReleaseType(release.metadata.releaseType), setIntendedPublishAt(release.metadata.intendedPublishAt ? new Date(release.metadata.intendedPublishAt) : void 0), toast.push({
47333
47216
  closable: !0,
47334
47217
  status: "warning",
47335
47218
  title: t("release.schedule-dialog.publish-date-in-past-warning")
@@ -48172,7 +48055,7 @@ const ReleaseScheduleButton = (t0) => {
48172
48055
  intendedPublishAt: publishAt.toISOString()
48173
48056
  }
48174
48057
  };
48175
- isEqual$2(newRelease, release) || updateRelease(newRelease);
48058
+ isEqual$1(newRelease, release) || updateRelease(newRelease);
48176
48059
  }
48177
48060
  if (isScheduledDateInPast()) {
48178
48061
  setRerenderDialog(_temp3$n);
@@ -51420,7 +51303,7 @@ function useRecentSearchesStore() {
51420
51303
  }
51421
51304
  }, newRecent = {
51422
51305
  version: RECENT_SEARCH_VERSION,
51423
- recentSearches: [newSearchItem, ...storedSearch.recentSearches.filter((r) => !isEqual$2(omit(r, "created"), omit(newSearchItem, "created")))].slice(0, MAX_RECENT_SEARCHES)
51306
+ recentSearches: [newSearchItem, ...storedSearch.recentSearches.filter((r) => !isEqual$1(omit(r, "created"), omit(newSearchItem, "created")))].slice(0, MAX_RECENT_SEARCHES)
51424
51307
  };
51425
51308
  return setStoredSearch(newRecent), getRecentSearchTerms({
51426
51309
  fieldDefinitions,
@@ -51919,7 +51802,7 @@ function CustomMenuItem$1(t0) {
51919
51802
  }, $[0] = dispatch, $[1] = ordering, $[2] = t2) : t2 = $[2];
51920
51803
  const handleClick = t2;
51921
51804
  let t3;
51922
- $[3] !== currentOrdering || $[4] !== ordering ? (t3 = isEqual$2(currentOrdering, ordering), $[3] = currentOrdering, $[4] = ordering, $[5] = t3) : t3 = $[5];
51805
+ $[3] !== currentOrdering || $[4] !== ordering ? (t3 = isEqual$1(currentOrdering, ordering), $[3] = currentOrdering, $[4] = ordering, $[5] = t3) : t3 = $[5];
51923
51806
  const isSelected = t3;
51924
51807
  let t4;
51925
51808
  $[6] !== ordering.titleKey || $[7] !== t ? (t4 = t(ordering.titleKey), $[6] = ordering.titleKey, $[7] = t, $[8] = t4) : t4 = $[8];
@@ -51956,7 +51839,7 @@ function SortMenu() {
51956
51839
  if ($[10] !== menuOrderings || $[11] !== ordering || $[12] !== t) {
51957
51840
  t12 = /* @__PURE__ */ Symbol.for("react.early_return_sentinel");
51958
51841
  bb0: {
51959
- const currentMenuItem = menuOrderings.find((item) => isEqual$2(ordering, item) && !isSearchDivider(item));
51842
+ const currentMenuItem = menuOrderings.find((item) => isEqual$1(ordering, item) && !isSearchDivider(item));
51960
51843
  if (!currentMenuItem) {
51961
51844
  t12 = null;
51962
51845
  break bb0;
@@ -52385,7 +52268,7 @@ function useSearch(t0) {
52385
52268
  }), $[0] = client, $[1] = maxFieldDepth, $[2] = schema2, $[3] = strategy, $[4] = t1) : t1 = $[4];
52386
52269
  const search2 = t1;
52387
52270
  let t2;
52388
- $[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({
52271
+ $[5] !== allowEmptyQueries || $[6] !== onComplete || $[7] !== onError || $[8] !== onStart || $[9] !== search2 ? (t2 = (inputValue$) => inputValue$.pipe(filter(nonNullable), map(sanitizeRequest), distinctUntilChanged(isEqual$1), debounce$1(_temp$1O), tap(onStart), switchMap((request_0) => concat(of({
52389
52272
  ...INITIAL_SEARCH_STATE,
52390
52273
  loading: !0,
52391
52274
  options: request_0.options,
@@ -52965,7 +52848,7 @@ function SearchProvider(t0) {
52965
52848
  const completeFilters = t14;
52966
52849
  let t15;
52967
52850
  $[43] !== completeFilters.length || $[44] !== cursor || $[45] !== documentTypes || $[46] !== handleSearch || $[47] !== ordering || $[48] !== strategy || $[49] !== terms ? (t15 = () => {
52968
- const orderingChanged = !isEqual$2(ordering, previousOrderingRef.current), cursorChanged = cursor !== previousCursorRef.current, termsChanged = !isEqual$2(terms, previousTermsRef.current);
52851
+ const orderingChanged = !isEqual$1(ordering, previousOrderingRef.current), cursorChanged = cursor !== previousCursorRef.current, termsChanged = !isEqual$1(terms, previousTermsRef.current);
52969
52852
  if (orderingChanged || cursorChanged || termsChanged) {
52970
52853
  let sortLabel = "findability-sort:";
52971
52854
  (ordering?.customMeasurementLabel || ordering.sort) && (sortLabel = "findability-sort:" + (ordering?.customMeasurementLabel || `${ordering.sort?.field} ${ordering.sort?.direction}`)), handleSearch({
@@ -65810,7 +65693,7 @@ function buildCommentBreadcrumbs(props2) {
65810
65693
  function useCommentHasChanged(message) {
65811
65694
  const $ = c(3), [prevMessage] = useState(message);
65812
65695
  let t0;
65813
- return $[0] !== message || $[1] !== prevMessage ? (t0 = isEqual$2(prevMessage, message), $[0] = message, $[1] = prevMessage, $[2] = t0) : t0 = $[2], !t0;
65696
+ return $[0] !== message || $[1] !== prevMessage ? (t0 = isEqual$1(prevMessage, message), $[0] = message, $[1] = prevMessage, $[2] = t0) : t0 = $[2], !t0;
65814
65697
  }
65815
65698
  function hasCommentMessageValue(value) {
65816
65699
  return value ? value?.some((block) => isPortableTextTextBlock(block) && (block?.children || [])?.some((c2) => isPortableTextSpan(c2) ? c2.text : c2.userId)) : !1;
@@ -66477,7 +66360,7 @@ function Editable(props2) {
66477
66360
  }, t9 = [mentionsSearchTerm], $[20] = mentionsSearchTerm, $[21] = t8, $[22] = t9) : (t8 = $[21], t9 = $[22]), useEffect(t8, t9);
66478
66361
  let t10, t11;
66479
66362
  $[23] !== closeMentions || $[24] !== mentionsMenuOpen || $[25] !== selection ? (t10 = () => {
66480
- mentionsMenuOpen && selection && !isEqual$2(selection.anchor, selection.focus) && closeMentions();
66363
+ mentionsMenuOpen && selection && !isEqual$1(selection.anchor, selection.focus) && closeMentions();
66481
66364
  }, t11 = [mentionsMenuOpen, closeMentions, selection], $[23] = closeMentions, $[24] = mentionsMenuOpen, $[25] = selection, $[26] = t10, $[27] = t11) : (t10 = $[26], t11 = $[27]), useEffect(t10, t11);
66482
66365
  const t12 = mentionOptions.data || EMPTY_ARRAY$e;
66483
66366
  let t13;
@@ -69618,7 +69501,7 @@ const CommentsSelectedPathProvider = memo(function(props2) {
69618
69501
  } = props2, [selectedPath, setSelectedPath] = useState(null);
69619
69502
  let t0;
69620
69503
  $[0] !== selectedPath ? (t0 = (nextPath) => {
69621
- isEqual$2(selectedPath, nextPath) || setSelectedPath(nextPath);
69504
+ isEqual$1(selectedPath, nextPath) || setSelectedPath(nextPath);
69622
69505
  }, $[0] = selectedPath, $[1] = t0) : t0 = $[1];
69623
69506
  const handleSelectPath = t0;
69624
69507
  let t1;
@@ -70307,7 +70190,7 @@ const CommentsPortableTextInputInner = memo(function(props2) {
70307
70190
  }
70308
70191
  }
70309
70192
  };
70310
- !isEqual$2(comment_1.target, nextComment.target) && operation.update(comment_1._id, nextComment);
70193
+ !isEqual$1(comment_1.target, nextComment.target) && operation.update(comment_1._id, nextComment);
70311
70194
  }), setAddedCommentsDecorations((prev_0) => prev_0.map((p_0) => decoratorsToUpdate.find((d) => d.payload?.commentId === p_0.payload?.commentId)?.payload?.dirty ? {
70312
70195
  ...p_0,
70313
70196
  payload: {
@@ -85336,7 +85219,7 @@ const CopyPasteProvider = (t0) => {
85336
85219
  schemaType,
85337
85220
  onChange
85338
85221
  };
85339
- setDocumentMetaState((prevMeta) => isEqual$2(prevMeta, processedMeta) ? prevMeta : processedMeta);
85222
+ setDocumentMetaState((prevMeta) => isEqual$1(prevMeta, processedMeta) ? prevMeta : processedMeta);
85340
85223
  }, $[0] = t1) : t1 = $[0];
85341
85224
  const setDocumentMeta = t1;
85342
85225
  let t2;
@@ -88173,7 +88056,7 @@ function useRouterFromWorkspaceHistory(history2, router, tools) {
88173
88056
  getServerSnapshot: _temp2$2,
88174
88057
  selector: t7
88175
88058
  }, $[16] = t5, $[17] = t6, $[18] = t7, $[19] = t8) : t8 = $[19];
88176
- const store = t8, event = useSyncExternalStoreWithSelector(store.subscribe, store.getSnapshot, store.getServerSnapshot, store.selector, isEqual$2), prevEvent = useRef(event);
88059
+ const store = t8, event = useSyncExternalStoreWithSelector(store.subscribe, store.getSnapshot, store.getServerSnapshot, store.selector, isEqual$1), prevEvent = useRef(event);
88177
88060
  let t9;
88178
88061
  $[20] !== event || $[21] !== history2 || $[22] !== router || $[23] !== tools ? (t9 = () => {
88179
88062
  if (event?.type === "state" && !event.state?.intent) {
@@ -91045,7 +90928,6 @@ export {
91045
90928
  defineSearchFilterOperators,
91046
90929
  defineSearchOperator,
91047
90930
  diffMatchPatch,
91048
- diffResolver,
91049
90931
  documentFieldActionsReducer,
91050
90932
  documentIdEquals,
91051
90933
  editState,
@@ -91073,7 +90955,7 @@ export {
91073
90955
  getExpandOperations,
91074
90956
  getIdPair,
91075
90957
  getInitialValueStream,
91076
- getItemKey$1 as getItemKey,
90958
+ getItemKey,
91077
90959
  getItemKeySegment,
91078
90960
  getNamelessWorkspaceIdentifier,
91079
90961
  getPairListener,