sanity 5.0.0-next-major.6 → 5.0.0-next-major.20251210134624
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/_chunks-es/package.js +1 -1
- package/lib/_chunks-es/version.js +1 -1
- package/lib/index.js +572 -540
- package/lib/index.js.map +1 -1
- package/package.json +17 -17
package/lib/index.js
CHANGED
|
@@ -9,18 +9,17 @@ import { SchedulesContext as SchedulesContext2 } from "sanity/_singletons";
|
|
|
9
9
|
import { Badge, Grid, rem, Box, Stack, Card, Spinner, Text as Text$1, Layer, Flex, Skeleton, Heading, Avatar, AvatarStack, Inline, Breadcrumbs, useClickOutsideEvent, Code, useTheme, useGlobalKeyDown, MenuDivider, Menu, useElementRect, Autocomplete, useToast, Button as Button$1, 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, Dialog as Dialog$1, 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
11
|
import throttle from "lodash/throttle.js";
|
|
12
|
-
import { styled, css, keyframes, createGlobalStyle, ServerStyleSheet } from "styled-components";
|
|
12
|
+
import { styled, css, keyframes, useTheme as useTheme$1, createGlobalStyle, ServerStyleSheet } 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, CropIcon, EyeOpenIcon, DotIcon, LockIcon, CheckmarkCircleIcon, PinFilledIcon, PinIcon, RestoreIcon, ClockIcon, CloseCircleIcon, UnarchiveIcon, ArchiveIcon, ArrowUpIcon, ControlsIcon, SpinnerIcon, ArrowLeftIcon, SortIcon, ComposeSparklesIcon, 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, Tab } from "./_chunks-es/TooltipDelayGroupProvider.js";
|
|
15
15
|
import { Hotkeys } from "./_chunks-es/TooltipDelayGroupProvider.js";
|
|
16
16
|
import "./_singletons.js";
|
|
17
17
|
import { ResizeObserver as ResizeObserver$2 } from "@juggle/resize-observer";
|
|
18
18
|
import createPubSub from "nano-pubsub";
|
|
19
|
-
import { COLOR_HUES, hues, white, red, gray, yellow, purple, black, green, blue } from "@sanity/color";
|
|
20
|
-
import { darken, lighten, hasBadContrast, readableColor } from "color2k";
|
|
21
19
|
import { I18nextProvider, useTranslation as useTranslation$1, initReactI18next } from "react-i18next";
|
|
22
20
|
import { isIndexSegment, isKeySegment, isIndexTuple, isKeyedObject, isReference as isReference$1, isArrayOfBlocksSchemaType, isSlug, isTypedObject, isGlobalDocumentReference, isObjectSchemaType, isArraySchemaType, isPortableTextSpan, isPortableTextTextBlock, isPrimitiveSchemaType, isBooleanSchemaType, isDateTimeSchemaType, isCrossDatasetReferenceSchemaType, isReferenceSchemaType, isStringSchemaType, isNumberSchemaType, isArrayOfObjectsSchemaType, isArrayOfPrimitivesSchemaType, isCrossDatasetReference, isTitledListValue, isImage, isValidationErrorMarker, isImageSchemaType, isSearchStrategy, searchStrategies as searchStrategies$1, defineType, defineField, defineArrayMember, isValidationWarningMarker, isValidationInfoMarker, isDeprecatedSchemaType, isFileSchemaType, isBlockSchemaType } from "@sanity/types";
|
|
23
21
|
export * from "@sanity/types";
|
|
22
|
+
import { COLOR_HUES, hues, white, red, gray, yellow, purple, black, green, blue } from "@sanity/color";
|
|
24
23
|
import { of, concat, defer, EMPTY as EMPTY$5, map as map$1, defaultIfEmpty, catchError as catchError$1, switchMap as switchMap$1, take, concatMap, from, Observable, merge, Subject, fromEvent, throwError, timer, NEVER, pipe, distinctUntilChanged as distinctUntilChanged$1, shareReplay as shareReplay$1, BehaviorSubject, tap as tap$1, finalize, share as share$1, ReplaySubject, combineLatest, asyncScheduler, bufferTime, mergeMap as mergeMap$1, firstValueFrom, filter as filter$1, lastValueFrom, partition as partition$1, asapScheduler, using, repeat, iif, startWith as startWith$1, concatWith, scan as scan$1, count, isObservable, retry, expand, reduce as reduce$2, skip as skip$1, forkJoin, debounce as debounce$2, toArray as toArray$2, delay as delay$1, timeout as timeout$1, connect, debounceTime as debounceTime$1 } from "rxjs";
|
|
25
24
|
import { catchError, tap, switchMap, map, scan, distinctUntilChanged, shareReplay, filter, startWith, mergeMapTo, takeUntil, take as take$1, publishReplay, refCount, withLatestFrom, share, mergeMap, concatMap as concatMap$1, groupBy as groupBy$1, throttleTime, last, mergeAll, toArray as toArray$1, distinct, skip, first, debounceTime, auditTime, switchMapTo, delay, reduce as reduce$1, debounce as debounce$1, finalize as finalize$1, expand as expand$1, mapTo, retry as retry$1, timeout } from "rxjs/operators";
|
|
26
25
|
import { SANITY_VERSION } from "./_chunks-es/version.js";
|
|
@@ -125,6 +124,7 @@ import escapeRegExp$1 from "lodash/escapeRegExp.js";
|
|
|
125
124
|
import { SanityLogo, SanityMonogram } from "@sanity/logos";
|
|
126
125
|
import DOMPurify from "isomorphic-dompurify";
|
|
127
126
|
import { renderToString, renderToStaticMarkup } from "react-dom/server";
|
|
127
|
+
import { darken, lighten, readableColor, hasBadContrast } from "color2k";
|
|
128
128
|
import semver, { satisfies } from "semver";
|
|
129
129
|
import { useHotModuleReload } from "use-hot-module-reload";
|
|
130
130
|
import isObject from "lodash/isObject.js";
|
|
@@ -3189,7 +3189,7 @@ function useGetI18nText(input) {
|
|
|
3189
3189
|
let t0;
|
|
3190
3190
|
if ($[0] !== input) {
|
|
3191
3191
|
const items = Array.isArray(input) ? input : [input];
|
|
3192
|
-
t0 = JSON.stringify(items.flatMap(_temp2$
|
|
3192
|
+
t0 = JSON.stringify(items.flatMap(_temp2$1I).filter(isNonNullable$3).sort()), $[0] = input, $[1] = t0;
|
|
3193
3193
|
} else
|
|
3194
3194
|
t0 = $[1];
|
|
3195
3195
|
const stableNamespaces = t0;
|
|
@@ -3223,10 +3223,10 @@ function useGetI18nText(input) {
|
|
|
3223
3223
|
}) : node;
|
|
3224
3224
|
}, $[4] = t, $[5] = t2) : t2 = $[5], t2;
|
|
3225
3225
|
}
|
|
3226
|
-
function _temp2$
|
|
3227
|
-
return item?.i18n ? Object.values(item.i18n).map(_temp$
|
|
3226
|
+
function _temp2$1I(item) {
|
|
3227
|
+
return item?.i18n ? Object.values(item.i18n).map(_temp$49) : [];
|
|
3228
3228
|
}
|
|
3229
|
-
function _temp$
|
|
3229
|
+
function _temp$49(t0) {
|
|
3230
3230
|
const {
|
|
3231
3231
|
ns
|
|
3232
3232
|
} = t0;
|
|
@@ -3242,7 +3242,7 @@ function useI18nText(node) {
|
|
|
3242
3242
|
break bb0;
|
|
3243
3243
|
}
|
|
3244
3244
|
let t12;
|
|
3245
|
-
$[1] !== node.i18n ? (t12 = Array.from(new Set(Object.values(node.i18n).map(_temp$
|
|
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;
|
|
3246
3246
|
}
|
|
3247
3247
|
const namespaces = t0, {
|
|
3248
3248
|
t
|
|
@@ -3280,7 +3280,7 @@ function useI18nText(node) {
|
|
|
3280
3280
|
}
|
|
3281
3281
|
return t1;
|
|
3282
3282
|
}
|
|
3283
|
-
function _temp$
|
|
3283
|
+
function _temp$48(t0) {
|
|
3284
3284
|
const {
|
|
3285
3285
|
ns
|
|
3286
3286
|
} = t0;
|
|
@@ -3563,7 +3563,7 @@ function useEnsureMediaLibrary(props2) {
|
|
|
3563
3563
|
bb0: {
|
|
3564
3564
|
const handleDefault = defaultIfEmpty({
|
|
3565
3565
|
status: "inactive"
|
|
3566
|
-
}), handleError = catchError$1(_temp$
|
|
3566
|
+
}), handleError = catchError$1(_temp$47);
|
|
3567
3567
|
if (props2.from === "library") {
|
|
3568
3568
|
let t23;
|
|
3569
3569
|
$[6] !== props2.libraryId ? (t23 = (organizationId) => ({
|
|
@@ -3594,7 +3594,7 @@ function useEnsureMediaLibrary(props2) {
|
|
|
3594
3594
|
status: "loading"
|
|
3595
3595
|
}, $[10] = t2) : t2 = $[10], useObservable(observable, t2);
|
|
3596
3596
|
}
|
|
3597
|
-
function _temp$
|
|
3597
|
+
function _temp$47(error) {
|
|
3598
3598
|
if (error instanceof ProvisionError)
|
|
3599
3599
|
return of({
|
|
3600
3600
|
status: "error",
|
|
@@ -7760,7 +7760,7 @@ function useDocumentValuePermissions(t0) {
|
|
|
7760
7760
|
document: document2,
|
|
7761
7761
|
permission
|
|
7762
7762
|
});
|
|
7763
|
-
return subscriptionRef.current = permissions$.pipe(distinctUntilChanged$1(_temp$
|
|
7763
|
+
return subscriptionRef.current = permissions$.pipe(distinctUntilChanged$1(_temp$46)).subscribe({
|
|
7764
7764
|
next: (value) => dispatch({
|
|
7765
7765
|
type: "value",
|
|
7766
7766
|
value
|
|
@@ -7774,7 +7774,7 @@ function useDocumentValuePermissions(t0) {
|
|
|
7774
7774
|
};
|
|
7775
7775
|
}, t2 = [grantsStore, document2, permission], $[0] = document2, $[1] = grantsStore, $[2] = permission, $[3] = t1, $[4] = t2) : (t1 = $[3], t2 = $[4]), useEffect(t1, t2), state;
|
|
7776
7776
|
}
|
|
7777
|
-
function _temp$
|
|
7777
|
+
function _temp$46(prev, next) {
|
|
7778
7778
|
return isEqual$2(prev, next);
|
|
7779
7779
|
}
|
|
7780
7780
|
function refCountDelay(duration, scheduler = asapScheduler) {
|
|
@@ -8982,7 +8982,7 @@ function useTimelineStore(t0) {
|
|
|
8982
8982
|
$[28] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t12 = () => timelineStateRef.current, $[28] = t12) : t12 = $[28];
|
|
8983
8983
|
let t13;
|
|
8984
8984
|
$[29] !== onError || $[30] !== timelineController$ ? (t13 = (callback) => {
|
|
8985
|
-
const subscription = timelineController$.pipe(map$1(_temp3$
|
|
8985
|
+
const subscription = timelineController$.pipe(map$1(_temp3$J), distinctUntilChanged$1(deepEquals), catchError$1((err_0) => (onError?.(err_0), of(INITIAL_TIMELINE_STATE))), tap$1((timelineState) => {
|
|
8986
8986
|
timelineStateRef.current = timelineState;
|
|
8987
8987
|
}), tap$1(callback)).subscribe();
|
|
8988
8988
|
return () => subscription.unsubscribe();
|
|
@@ -8996,8 +8996,8 @@ function useTimelineStore(t0) {
|
|
|
8996
8996
|
subscribe: t13
|
|
8997
8997
|
}, $[32] = t10, $[33] = t11, $[34] = t13, $[35] = t9, $[36] = t14) : t14 = $[36], t14;
|
|
8998
8998
|
}
|
|
8999
|
-
function _temp3$
|
|
9000
|
-
const chunks = innerController_0.timeline.mapChunks(_temp$
|
|
8999
|
+
function _temp3$J(innerController_0) {
|
|
9000
|
+
const chunks = innerController_0.timeline.mapChunks(_temp$45), lastNonDeletedChunk = chunks.filter(_temp2$1H), hasMoreChunks = !innerController_0.timeline.reachedEarliestEntry;
|
|
9001
9001
|
hasMoreChunks && chunks.length > 16 && innerController_0.setLoadMore(!1);
|
|
9002
9002
|
const timelineReady = !["invalid", "loading"].includes(innerController_0.selectionState);
|
|
9003
9003
|
return {
|
|
@@ -9017,10 +9017,10 @@ function _temp3$I(innerController_0) {
|
|
|
9017
9017
|
timelineReady
|
|
9018
9018
|
};
|
|
9019
9019
|
}
|
|
9020
|
-
function _temp2$
|
|
9020
|
+
function _temp2$1H(chunk_1) {
|
|
9021
9021
|
return !["delete", "initial"].includes(chunk_1.type);
|
|
9022
9022
|
}
|
|
9023
|
-
function _temp$
|
|
9023
|
+
function _temp$45(c2) {
|
|
9024
9024
|
return c2;
|
|
9025
9025
|
}
|
|
9026
9026
|
const handleIncomingMessage = (event) => {
|
|
@@ -9333,11 +9333,11 @@ function createMultiKeyWeakMap() {
|
|
|
9333
9333
|
function ResourceCacheProvider(t0) {
|
|
9334
9334
|
const $ = c(3), {
|
|
9335
9335
|
children
|
|
9336
|
-
} = t0, [resourceCache] = useState(_temp$
|
|
9336
|
+
} = t0, [resourceCache] = useState(_temp$44);
|
|
9337
9337
|
let t1;
|
|
9338
9338
|
return $[0] !== children || $[1] !== resourceCache ? (t1 = /* @__PURE__ */ jsx(ResourceCacheContext.Provider, { value: resourceCache, children }), $[0] = children, $[1] = resourceCache, $[2] = t1) : t1 = $[2], t1;
|
|
9339
9339
|
}
|
|
9340
|
-
function _temp$
|
|
9340
|
+
function _temp$44() {
|
|
9341
9341
|
const namespaces = /* @__PURE__ */ new Map(), nullReplacer = {}, emptyDependenciesReplacer = [nullReplacer], removeNullDependencies = (dependencies) => dependencies.length ? dependencies.map((dep) => dep === null ? nullReplacer : dep) : emptyDependenciesReplacer;
|
|
9342
9342
|
return {
|
|
9343
9343
|
get: (t0) => {
|
|
@@ -9618,25 +9618,25 @@ function useComlinkStore() {
|
|
|
9618
9618
|
}
|
|
9619
9619
|
const initial$1 = [], fallback$1 = of(initial$1);
|
|
9620
9620
|
function useDocumentPresence(documentId) {
|
|
9621
|
-
const $ = c(6), [mounted, mount] = useReducer(_temp$
|
|
9621
|
+
const $ = c(6), [mounted, mount] = useReducer(_temp$43, !1);
|
|
9622
9622
|
let t0, t1;
|
|
9623
9623
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => startTransition(mount), t1 = [], $[0] = t0, $[1] = t1) : (t0 = $[0], t1 = $[1]), useEffect(t0, t1);
|
|
9624
9624
|
const presenceStore = usePresenceStore();
|
|
9625
9625
|
let t2;
|
|
9626
9626
|
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);
|
|
9627
9627
|
}
|
|
9628
|
-
function _temp$
|
|
9628
|
+
function _temp$43() {
|
|
9629
9629
|
return !0;
|
|
9630
9630
|
}
|
|
9631
9631
|
const initial = [], fallback = of(initial);
|
|
9632
9632
|
function useGlobalPresence() {
|
|
9633
|
-
const $ = c(2), [mounted, mount] = useReducer(_temp$
|
|
9633
|
+
const $ = c(2), [mounted, mount] = useReducer(_temp$42, !1);
|
|
9634
9634
|
let t0, t1;
|
|
9635
9635
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => startTransition(mount), t1 = [], $[0] = t0, $[1] = t1) : (t0 = $[0], t1 = $[1]), useEffect(t0, t1);
|
|
9636
9636
|
const presenceStore = usePresenceStore();
|
|
9637
9637
|
return useObservable(mounted ? presenceStore.globalPresence$ : fallback, initial);
|
|
9638
9638
|
}
|
|
9639
|
-
function _temp$
|
|
9639
|
+
function _temp$42() {
|
|
9640
9640
|
return !0;
|
|
9641
9641
|
}
|
|
9642
9642
|
function EventsProvider(t0) {
|
|
@@ -10817,7 +10817,7 @@ function useRelativeTime(time, t0) {
|
|
|
10817
10817
|
const $ = c(5);
|
|
10818
10818
|
let t1;
|
|
10819
10819
|
$[0] !== t0 ? (t1 = t0 === void 0 ? {} : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
|
|
10820
|
-
const options = t1, [now, updateNow] = useReducer(_temp$
|
|
10820
|
+
const options = t1, [now, updateNow] = useReducer(_temp$41, null, _temp2$1G), resolved = useFormatRelativeTime(time, options.relativeTo || now, options);
|
|
10821
10821
|
let t2, t3;
|
|
10822
10822
|
return $[2] !== resolved.refreshInterval ? (t2 = () => {
|
|
10823
10823
|
let timerId;
|
|
@@ -10831,10 +10831,10 @@ function useRelativeTime(time, t0) {
|
|
|
10831
10831
|
};
|
|
10832
10832
|
}, t3 = [resolved.refreshInterval], $[2] = resolved.refreshInterval, $[3] = t2, $[4] = t3) : (t2 = $[3], t3 = $[4]), useEffect(t2, t3), resolved.timestamp;
|
|
10833
10833
|
}
|
|
10834
|
-
function _temp2$
|
|
10834
|
+
function _temp2$1G() {
|
|
10835
10835
|
return Date.now();
|
|
10836
10836
|
}
|
|
10837
|
-
function _temp$
|
|
10837
|
+
function _temp$41() {
|
|
10838
10838
|
return Date.now();
|
|
10839
10839
|
}
|
|
10840
10840
|
function useFormatRelativeTime(date, now, t0) {
|
|
@@ -11149,7 +11149,7 @@ const IconBox$1 = styled(Flex)((props2) => {
|
|
|
11149
11149
|
let t2;
|
|
11150
11150
|
$[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];
|
|
11151
11151
|
let t3;
|
|
11152
|
-
$[4] !== collaborators ? (t3 = collaborators.map(_temp$
|
|
11152
|
+
$[4] !== collaborators ? (t3 = collaborators.map(_temp$40), $[4] = collaborators, $[5] = t3) : t3 = $[5];
|
|
11153
11153
|
let t4;
|
|
11154
11154
|
return $[6] !== t2 || $[7] !== t3 ? (t4 = /* @__PURE__ */ jsxs(Stack, { paddingBottom: 1, children: [
|
|
11155
11155
|
t2,
|
|
@@ -11245,7 +11245,7 @@ function Event$1(t0) {
|
|
|
11245
11245
|
t23
|
|
11246
11246
|
] }), $[52] = t22, $[53] = t23, $[54] = t24) : t24 = $[54], t24;
|
|
11247
11247
|
}
|
|
11248
|
-
function _temp$
|
|
11248
|
+
function _temp$40(userId) {
|
|
11249
11249
|
return /* @__PURE__ */ jsx(UserLine, { userId }, userId);
|
|
11250
11250
|
}
|
|
11251
11251
|
function DiffTooltip(props2) {
|
|
@@ -11294,7 +11294,7 @@ function DiffTooltipWithAnnotation(props2) {
|
|
|
11294
11294
|
let t2;
|
|
11295
11295
|
$[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Text$1, { muted: !0, size: 1, weight: "medium", children: t1 }), $[9] = t1, $[10] = t2) : t2 = $[10];
|
|
11296
11296
|
let t3;
|
|
11297
|
-
$[11] !== annotations ? (t3 = annotations.map(_temp$
|
|
11297
|
+
$[11] !== annotations ? (t3 = annotations.map(_temp$3$), $[11] = annotations, $[12] = t3) : t3 = $[12];
|
|
11298
11298
|
let t4;
|
|
11299
11299
|
$[13] !== t3 ? (t4 = /* @__PURE__ */ jsx(Stack, { space: 2, children: t3 }), $[13] = t3, $[14] = t4) : t4 = $[14];
|
|
11300
11300
|
let t5;
|
|
@@ -11306,7 +11306,7 @@ function DiffTooltipWithAnnotation(props2) {
|
|
|
11306
11306
|
let t6;
|
|
11307
11307
|
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;
|
|
11308
11308
|
}
|
|
11309
|
-
function _temp$
|
|
11309
|
+
function _temp$3$(annotation, idx) {
|
|
11310
11310
|
return /* @__PURE__ */ jsx(AnnotationItem, { annotation }, idx);
|
|
11311
11311
|
}
|
|
11312
11312
|
function AnnotationItem(t0) {
|
|
@@ -12159,12 +12159,12 @@ const SizeDiff = styled.div`
|
|
|
12159
12159
|
$[2] !== fields ? (t3 = Object.entries(fields).filter((t42) => {
|
|
12160
12160
|
const [name, field] = t42;
|
|
12161
12161
|
return field.isChanged && !ignoredFields.includes(name);
|
|
12162
|
-
}).map(_temp$
|
|
12162
|
+
}).map(_temp$3_), $[2] = fields, $[3] = t3) : t3 = $[3];
|
|
12163
12163
|
const changedFields = t3, didAssetChange = changedFields.includes("asset");
|
|
12164
12164
|
let t4;
|
|
12165
12165
|
if ($[4] !== changedFields || $[5] !== schemaType.fields) {
|
|
12166
12166
|
let t52;
|
|
12167
|
-
$[7] !== changedFields ? (t52 = (field_0) => field_0.name !== "asset" && changedFields.includes(field_0.name), $[7] = changedFields, $[8] = t52) : t52 = $[8], t4 = schemaType.fields.filter(t52).map(_temp2$
|
|
12167
|
+
$[7] !== changedFields ? (t52 = (field_0) => field_0.name !== "asset" && changedFields.includes(field_0.name), $[7] = changedFields, $[8] = t52) : t52 = $[8], t4 = schemaType.fields.filter(t52).map(_temp2$1F), $[4] = changedFields, $[5] = schemaType.fields, $[6] = t4;
|
|
12168
12168
|
} else
|
|
12169
12169
|
t4 = $[6];
|
|
12170
12170
|
const nestedFields = t4, pctDiff = getSizeDiff(prev?.size, next?.size);
|
|
@@ -12218,11 +12218,11 @@ const SizeDiff = styled.div`
|
|
|
12218
12218
|
t15
|
|
12219
12219
|
] }), $[50] = t14, $[51] = t15, $[52] = t16) : t16 = $[52], t16;
|
|
12220
12220
|
};
|
|
12221
|
-
function _temp$
|
|
12221
|
+
function _temp$3_(t0) {
|
|
12222
12222
|
const [name_0] = t0;
|
|
12223
12223
|
return name_0;
|
|
12224
12224
|
}
|
|
12225
|
-
function _temp2$
|
|
12225
|
+
function _temp2$1F(field_1) {
|
|
12226
12226
|
return field_1.name;
|
|
12227
12227
|
}
|
|
12228
12228
|
function hexToRgba(hex, opacity) {
|
|
@@ -12480,7 +12480,7 @@ const IMAGE_META_FIELDS = ["crop", "hotspot"], BASE_IMAGE_FIELDS = ["asset", "me
|
|
|
12480
12480
|
let t4;
|
|
12481
12481
|
if ($[7] !== changedFields || $[8] !== schemaType.fields) {
|
|
12482
12482
|
let t52;
|
|
12483
|
-
$[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$
|
|
12483
|
+
$[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;
|
|
12484
12484
|
} else
|
|
12485
12485
|
t4 = $[9];
|
|
12486
12486
|
const nestedFields = t4;
|
|
@@ -12529,7 +12529,7 @@ function getChangeDescription(action, t) {
|
|
|
12529
12529
|
return "Unknown change";
|
|
12530
12530
|
}
|
|
12531
12531
|
}
|
|
12532
|
-
function _temp$
|
|
12532
|
+
function _temp$3Z(field_0) {
|
|
12533
12533
|
return field_0.name;
|
|
12534
12534
|
}
|
|
12535
12535
|
const NumberWrapper = styled.div`
|
|
@@ -13789,7 +13789,7 @@ function DiffInspectWrapper(props2) {
|
|
|
13789
13789
|
} = props2, $[0] = props2, $[1] = as, $[2] = change, $[3] = children, $[4] = restProps) : (as = $[1], change = $[2], children = $[3], restProps = $[4]);
|
|
13790
13790
|
const isHovering = useRef(!1), [isInspecting, setIsInspecting] = useState(!1);
|
|
13791
13791
|
let t0;
|
|
13792
|
-
$[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setIsInspecting(_temp$
|
|
13792
|
+
$[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setIsInspecting(_temp$3Y), $[5] = t0) : t0 = $[5];
|
|
13793
13793
|
const toggleInspect = t0;
|
|
13794
13794
|
let t1;
|
|
13795
13795
|
$[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => isHovering.current = !0, $[6] = t1) : t1 = $[6];
|
|
@@ -13813,7 +13813,7 @@ function DiffInspectWrapper(props2) {
|
|
|
13813
13813
|
let t6;
|
|
13814
13814
|
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;
|
|
13815
13815
|
}
|
|
13816
|
-
function _temp$
|
|
13816
|
+
function _temp$3Y(state) {
|
|
13817
13817
|
return !state;
|
|
13818
13818
|
}
|
|
13819
13819
|
const MetaLabel = (t0) => {
|
|
@@ -14217,7 +14217,7 @@ function FieldChange(props2) {
|
|
|
14217
14217
|
}, $[17] = t7) : t7 = $[17];
|
|
14218
14218
|
const handleRevertButtonMouseLeave = t7;
|
|
14219
14219
|
let t8;
|
|
14220
|
-
$[18] !== change.parentSchema ? (t8 = change.parentSchema?.jsonType === "array" && !change.parentSchema.of.some(_temp$
|
|
14220
|
+
$[18] !== change.parentSchema ? (t8 = change.parentSchema?.jsonType === "array" && !change.parentSchema.of.some(_temp$3X), $[18] = change.parentSchema, $[19] = t8) : t8 = $[19];
|
|
14221
14221
|
const isArray2 = t8;
|
|
14222
14222
|
let t9;
|
|
14223
14223
|
$[20] !== change.path || $[21] !== isArray2 ? (t9 = isArray2 ? change.path.slice(0, -1) : change.path, $[20] = change.path, $[21] = isArray2, $[22] = t9) : t9 = $[22];
|
|
@@ -14258,7 +14258,7 @@ function FieldChange(props2) {
|
|
|
14258
14258
|
t21
|
|
14259
14259
|
] }), $[65] = t20, $[66] = t21, $[67] = t22) : t22 = $[67], t22;
|
|
14260
14260
|
}
|
|
14261
|
-
function _temp$
|
|
14261
|
+
function _temp$3X(ofType) {
|
|
14262
14262
|
return ofType.type?.name === "block";
|
|
14263
14263
|
}
|
|
14264
14264
|
const ChangeListWrapper = styled.div`
|
|
@@ -14317,7 +14317,7 @@ function GroupChange(props2) {
|
|
|
14317
14317
|
isComparingCurrent
|
|
14318
14318
|
} = useDocumentChange(), FieldWrapper2 = t0 === void 0 ? Fragment : t0;
|
|
14319
14319
|
let t1;
|
|
14320
|
-
$[5] !== changes ? (t1 = changes.every(_temp$
|
|
14320
|
+
$[5] !== changes ? (t1 = changes.every(_temp$3W), $[5] = changes, $[6] = t1) : t1 = $[6];
|
|
14321
14321
|
const isPortableText2 = t1;
|
|
14322
14322
|
let t2;
|
|
14323
14323
|
$[7] !== diffPath || $[8] !== groupPath ? (t2 = pathsAreEqual(diffPath, groupPath), $[7] = diffPath, $[8] = groupPath, $[9] = t2) : t2 = $[9];
|
|
@@ -14361,7 +14361,7 @@ function GroupChange(props2) {
|
|
|
14361
14361
|
] }), $[20] = changes, $[21] = confirmRevertOpen, $[22] = group2.fieldsetName, $[23] = group2.path.length, $[24] = handleRevertChanges, $[25] = hidden, $[26] = isComparingCurrent, $[27] = isPermissionsLoading, $[28] = isPortableText2, $[29] = isRevertButtonHovered, $[30] = permissions?.granted, $[31] = readOnly, $[32] = revertButtonElement, $[33] = t8) : t8 = $[33];
|
|
14362
14362
|
const content = t8;
|
|
14363
14363
|
let t9;
|
|
14364
|
-
$[34] !== group2.schemaType ? (t9 = group2.schemaType?.jsonType === "array" && group2.schemaType.of.some(_temp2$
|
|
14364
|
+
$[34] !== group2.schemaType ? (t9 = group2.schemaType?.jsonType === "array" && group2.schemaType.of.some(_temp2$1E), $[34] = group2.schemaType, $[35] = t9) : t9 = $[35];
|
|
14365
14365
|
const isPortableTextGroupArray = t9;
|
|
14366
14366
|
let t10;
|
|
14367
14367
|
return $[36] !== FieldWrapper2 || $[37] !== content || $[38] !== groupPath || $[39] !== hidden || $[40] !== isNestedInDiff || $[41] !== isPortableTextGroupArray || $[42] !== isRevertButtonHovered || $[43] !== restProps || $[44] !== titlePath ? (t10 = hidden ? null : /* @__PURE__ */ jsxs(Stack, { space: 1, ...restProps, children: [
|
|
@@ -14369,10 +14369,10 @@ function GroupChange(props2) {
|
|
|
14369
14369
|
isNestedInDiff || isPortableTextGroupArray ? content : /* @__PURE__ */ jsx(FieldWrapper2, { hasRevertHover: isRevertButtonHovered, path: groupPath, children: content })
|
|
14370
14370
|
] }), $[36] = FieldWrapper2, $[37] = content, $[38] = groupPath, $[39] = hidden, $[40] = isNestedInDiff, $[41] = isPortableTextGroupArray, $[42] = isRevertButtonHovered, $[43] = restProps, $[44] = titlePath, $[45] = t10) : t10 = $[45], t10;
|
|
14371
14371
|
}
|
|
14372
|
-
function _temp2$
|
|
14372
|
+
function _temp2$1E(ofType) {
|
|
14373
14373
|
return ofType.name === "block";
|
|
14374
14374
|
}
|
|
14375
|
-
function _temp$
|
|
14375
|
+
function _temp$3W(change) {
|
|
14376
14376
|
return isFieldChange(change) && isPTSchemaType(change.schemaType);
|
|
14377
14377
|
}
|
|
14378
14378
|
function useHover(node) {
|
|
@@ -14567,7 +14567,7 @@ function ChangesError(t0) {
|
|
|
14567
14567
|
$[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: {
|
|
14568
14568
|
revisionId: error.revisionId
|
|
14569
14569
|
}, components: {
|
|
14570
|
-
Break: _temp$
|
|
14570
|
+
Break: _temp$3V
|
|
14571
14571
|
} }) }) }), $[8] = error, $[9] = revisionNotFoundError, $[10] = t, $[11] = t5) : t5 = $[11];
|
|
14572
14572
|
let t6;
|
|
14573
14573
|
return $[12] !== t2 || $[13] !== t4 || $[14] !== t5 ? (t6 = /* @__PURE__ */ jsx(Card, { tone: "caution", padding: 3, children: /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
|
|
@@ -14576,7 +14576,7 @@ function ChangesError(t0) {
|
|
|
14576
14576
|
t5
|
|
14577
14577
|
] }) }), $[12] = t2, $[13] = t4, $[14] = t5, $[15] = t6) : t6 = $[15], t6;
|
|
14578
14578
|
}
|
|
14579
|
-
function _temp$
|
|
14579
|
+
function _temp$3V() {
|
|
14580
14580
|
return /* @__PURE__ */ jsx("br", {});
|
|
14581
14581
|
}
|
|
14582
14582
|
const RoundedCard = styled.span`
|
|
@@ -14658,11 +14658,11 @@ function DiffString(props2) {
|
|
|
14658
14658
|
let t0;
|
|
14659
14659
|
$[0] !== diff.segments ? (t0 = diff.segments || [], $[0] = diff.segments, $[1] = t0) : t0 = $[1];
|
|
14660
14660
|
let t1;
|
|
14661
|
-
$[2] !== t0 ? (t1 = t0.map(_temp$
|
|
14661
|
+
$[2] !== t0 ? (t1 = t0.map(_temp$3U), $[2] = t0, $[3] = t1) : t1 = $[3];
|
|
14662
14662
|
let t2;
|
|
14663
14663
|
return $[4] !== t1 ? (t2 = /* @__PURE__ */ jsx(Fragment$1, { children: t1 }), $[4] = t1, $[5] = t2) : t2 = $[5], t2;
|
|
14664
14664
|
}
|
|
14665
|
-
function _temp$
|
|
14665
|
+
function _temp$3U(segment, segmentIndex) {
|
|
14666
14666
|
return /* @__PURE__ */ jsx(DiffStringSegment, { segment }, segmentIndex);
|
|
14667
14667
|
}
|
|
14668
14668
|
const MetaText = styled(Text$1)`
|
|
@@ -14743,7 +14743,7 @@ const ArrayOfOptionsFieldDiff = (t0) => {
|
|
|
14743
14743
|
] }) }),
|
|
14744
14744
|
/* @__PURE__ */ jsx(Flex, { align: "center", children: /* @__PURE__ */ jsx(ItemPreview, { value: title || value, memberType }) })
|
|
14745
14745
|
] }, getItemKey(diff, index));
|
|
14746
|
-
}, $[8] = colorManager, $[9] = diff, $[10] = t, $[11] = t3) : t3 = $[11], t1 = diff.items.map(t22).filter(_temp$
|
|
14746
|
+
}, $[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;
|
|
14747
14747
|
} else
|
|
14748
14748
|
t1 = $[4];
|
|
14749
14749
|
let t2;
|
|
@@ -14813,7 +14813,7 @@ function getItemTitle(item, schemaType) {
|
|
|
14813
14813
|
const list = schemaType.options?.list || [], index = getOptionIndex(item, schemaType);
|
|
14814
14814
|
return index === -1 ? void 0 : list[index].title || void 0;
|
|
14815
14815
|
}
|
|
14816
|
-
function _temp$
|
|
14816
|
+
function _temp$3T(item_0) {
|
|
14817
14817
|
return item_0 !== null;
|
|
14818
14818
|
}
|
|
14819
14819
|
const SlugWrapper = styled.div`
|
|
@@ -14989,12 +14989,12 @@ function useChildValidation(path, t0) {
|
|
|
14989
14989
|
let t1;
|
|
14990
14990
|
if ($[0] !== inclusive || $[1] !== path || $[2] !== validation2) {
|
|
14991
14991
|
let t2;
|
|
14992
|
-
$[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$
|
|
14992
|
+
$[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;
|
|
14993
14993
|
} else
|
|
14994
14994
|
t1 = $[3];
|
|
14995
14995
|
return t1;
|
|
14996
14996
|
}
|
|
14997
|
-
function _temp$
|
|
14997
|
+
function _temp$3S(marker) {
|
|
14998
14998
|
return {
|
|
14999
14999
|
message: marker.message,
|
|
15000
15000
|
level: marker.level,
|
|
@@ -15494,7 +15494,7 @@ const DefaultAnnotationComponent = (props2) => {
|
|
|
15494
15494
|
selected,
|
|
15495
15495
|
textElement,
|
|
15496
15496
|
validation: validation2
|
|
15497
|
-
} = props2, isLink = schemaType.name === "link", hasError = validation2.some(_temp$
|
|
15497
|
+
} = props2, isLink = schemaType.name === "link", hasError = validation2.some(_temp$3R), hasWarning = validation2.some(_temp2$1D), hasMarkers = markers.length > 0, isReady = !!children, {
|
|
15498
15498
|
t
|
|
15499
15499
|
} = useTranslation();
|
|
15500
15500
|
let t0;
|
|
@@ -15525,10 +15525,10 @@ const DefaultAnnotationComponent = (props2) => {
|
|
|
15525
15525
|
t7
|
|
15526
15526
|
] }), $[15] = t1, $[16] = t2, $[17] = t3, $[18] = t4, $[19] = t5, $[20] = t6, $[21] = t7, $[22] = textElement, $[23] = toneKey, $[24] = t8) : t8 = $[24], t8;
|
|
15527
15527
|
};
|
|
15528
|
-
function _temp$
|
|
15528
|
+
function _temp$3R(v) {
|
|
15529
15529
|
return v.level === "error";
|
|
15530
15530
|
}
|
|
15531
|
-
function _temp2$
|
|
15531
|
+
function _temp2$1D(v_0) {
|
|
15532
15532
|
return v_0.level === "warning";
|
|
15533
15533
|
}
|
|
15534
15534
|
function createStore(reportedValues, publish2) {
|
|
@@ -15548,7 +15548,7 @@ function createStore(reportedValues, publish2) {
|
|
|
15548
15548
|
};
|
|
15549
15549
|
}
|
|
15550
15550
|
function useTrackerStore() {
|
|
15551
|
-
const $ = c(9), [reportedValues] = useState(_temp$
|
|
15551
|
+
const $ = c(9), [reportedValues] = useState(_temp$3Q);
|
|
15552
15552
|
let t0;
|
|
15553
15553
|
$[0] !== reportedValues ? (t0 = () => Array.from(reportedValues.entries()), $[0] = reportedValues, $[1] = t0) : t0 = $[1];
|
|
15554
15554
|
let t1;
|
|
@@ -15568,7 +15568,7 @@ function useTrackerStore() {
|
|
|
15568
15568
|
snapshot: snapshot2
|
|
15569
15569
|
}, $[6] = snapshot2, $[7] = store, $[8] = t4) : t4 = $[8], t4;
|
|
15570
15570
|
}
|
|
15571
|
-
function _temp$
|
|
15571
|
+
function _temp$3Q() {
|
|
15572
15572
|
return /* @__PURE__ */ new Map();
|
|
15573
15573
|
}
|
|
15574
15574
|
function useTrackerStoreReporter(store, id2, value, t0) {
|
|
@@ -15614,17 +15614,17 @@ const useChangeIndicatorsReporter = (id2, value, isEqual2) => {
|
|
|
15614
15614
|
function useHoveredChange() {
|
|
15615
15615
|
const $ = c(2), reportedValues = useChangeIndicatorsReportedValues();
|
|
15616
15616
|
let t0;
|
|
15617
|
-
$[0] !== reportedValues ? (t0 = reportedValues.filter(_temp$
|
|
15617
|
+
$[0] !== reportedValues ? (t0 = reportedValues.filter(_temp$3P).sort(_temp2$1C), $[0] = reportedValues, $[1] = t0) : t0 = $[1];
|
|
15618
15618
|
const hoveredEntry = t0[0];
|
|
15619
15619
|
if (hoveredEntry) {
|
|
15620
15620
|
const [, change_0] = hoveredEntry;
|
|
15621
15621
|
return change_0;
|
|
15622
15622
|
}
|
|
15623
15623
|
}
|
|
15624
|
-
function _temp2$
|
|
15624
|
+
function _temp2$1C(a, b) {
|
|
15625
15625
|
return b[1].path.length - a[1].path.length;
|
|
15626
15626
|
}
|
|
15627
|
-
function _temp$
|
|
15627
|
+
function _temp$3P(t0) {
|
|
15628
15628
|
const [, change] = t0;
|
|
15629
15629
|
return change.hasHover;
|
|
15630
15630
|
}
|
|
@@ -15840,7 +15840,7 @@ const FieldActionMenu = memo(function(props2) {
|
|
|
15840
15840
|
$[4] !== nodes ? (t2 = nodes.filter(renderAsButton), $[4] = nodes, $[5] = t2) : t2 = $[5];
|
|
15841
15841
|
const buttonNodes = t2;
|
|
15842
15842
|
let t3;
|
|
15843
|
-
$[6] !== nodes ? (t3 = nodes.filter(_temp$
|
|
15843
|
+
$[6] !== nodes ? (t3 = nodes.filter(_temp$3O), $[6] = nodes, $[7] = t3) : t3 = $[7];
|
|
15844
15844
|
const menuNodesProp = t3;
|
|
15845
15845
|
let t4;
|
|
15846
15846
|
bb0: {
|
|
@@ -15925,7 +15925,7 @@ function RootFieldActionMenuGroup(props2) {
|
|
|
15925
15925
|
let t6;
|
|
15926
15926
|
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;
|
|
15927
15927
|
}
|
|
15928
|
-
function _temp$
|
|
15928
|
+
function _temp$3O(node) {
|
|
15929
15929
|
return !renderAsButton(node);
|
|
15930
15930
|
}
|
|
15931
15931
|
function useHoveredField() {
|
|
@@ -16030,7 +16030,7 @@ const FieldActionsResolver = memo(function(props2) {
|
|
|
16030
16030
|
t6 = $[15];
|
|
16031
16031
|
const FieldActions = t6;
|
|
16032
16032
|
let t7;
|
|
16033
|
-
$[21] !== FieldActions ? (t7 = FieldActions.map(_temp$
|
|
16033
|
+
$[21] !== FieldActions ? (t7 = FieldActions.map(_temp$3N), $[21] = FieldActions, $[22] = t7) : t7 = $[22];
|
|
16034
16034
|
let t8;
|
|
16035
16035
|
return $[23] !== t7 ? (t8 = /* @__PURE__ */ jsx(Fragment$1, { children: t7 }), $[23] = t7, $[24] = t8) : t8 = $[24], t8;
|
|
16036
16036
|
});
|
|
@@ -16062,7 +16062,7 @@ function defineFieldActionComponent({
|
|
|
16062
16062
|
}, t2 = [node], $[1] = node, $[2] = t1, $[3] = t2) : (t1 = $[2], t2 = $[3]), useEffect(t1, t2), null;
|
|
16063
16063
|
});
|
|
16064
16064
|
}
|
|
16065
|
-
function _temp$
|
|
16065
|
+
function _temp$3N(FieldAction, key) {
|
|
16066
16066
|
return /* @__PURE__ */ jsx(FieldAction, {}, key);
|
|
16067
16067
|
}
|
|
16068
16068
|
function useFieldActions() {
|
|
@@ -16071,7 +16071,7 @@ function useFieldActions() {
|
|
|
16071
16071
|
const HoveredFieldProvider = memo(function(props2) {
|
|
16072
16072
|
const $ = c(17), {
|
|
16073
16073
|
children
|
|
16074
|
-
} = props2, [listeners] = useState(_temp$
|
|
16074
|
+
} = props2, [listeners] = useState(_temp$3M);
|
|
16075
16075
|
let t0;
|
|
16076
16076
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = [], $[0] = t0) : t0 = $[0];
|
|
16077
16077
|
const hoveredStackRef = useRef(t0);
|
|
@@ -16117,7 +16117,7 @@ const HoveredFieldProvider = memo(function(props2) {
|
|
|
16117
16117
|
let t7;
|
|
16118
16118
|
return $[14] !== children || $[15] !== context ? (t7 = /* @__PURE__ */ jsx(HoveredFieldContext.Provider, { value: context, children }), $[14] = children, $[15] = context, $[16] = t7) : t7 = $[16], t7;
|
|
16119
16119
|
});
|
|
16120
|
-
function _temp$
|
|
16120
|
+
function _temp$3M() {
|
|
16121
16121
|
return /* @__PURE__ */ new Set();
|
|
16122
16122
|
}
|
|
16123
16123
|
function useDidUpdate(current, didUpdate, t0) {
|
|
@@ -16271,7 +16271,7 @@ function ImageOrFileField(field) {
|
|
|
16271
16271
|
const $ = c(32), [fieldActionsNodes, setFieldActionNodes] = useState(EMPTY_ARRAY$x), documentId = usePublishedId$1(), focused = !!field.inputProps.focused;
|
|
16272
16272
|
let t0;
|
|
16273
16273
|
if ($[0] !== field.inputProps.members || $[1] !== field.presence) {
|
|
16274
|
-
const hotspotField = field.inputProps.members.find(_temp$
|
|
16274
|
+
const hotspotField = field.inputProps.members.find(_temp$3L);
|
|
16275
16275
|
t0 = hotspotField?.open ? field.presence : field.presence.concat(hotspotField?.field.presence || EMPTY_ARRAY$x), $[0] = field.inputProps.members, $[1] = field.presence, $[2] = t0;
|
|
16276
16276
|
} else
|
|
16277
16277
|
t0 = $[2];
|
|
@@ -16288,7 +16288,7 @@ function ImageOrFileField(field) {
|
|
|
16288
16288
|
t3
|
|
16289
16289
|
] }), $[29] = t1, $[30] = t3, $[31] = t4) : t4 = $[31], t4;
|
|
16290
16290
|
}
|
|
16291
|
-
function _temp$
|
|
16291
|
+
function _temp$3L(member) {
|
|
16292
16292
|
return member.kind === "field" && member.name === "hotspot";
|
|
16293
16293
|
}
|
|
16294
16294
|
function defaultResolveFieldComponent(schemaType) {
|
|
@@ -16906,11 +16906,11 @@ function useSearchMaxFieldDepth(overrideClient) {
|
|
|
16906
16906
|
client
|
|
16907
16907
|
}).pipe(shareReplay()));
|
|
16908
16908
|
let t1;
|
|
16909
|
-
$[2] !== dataset ? (t1 = cachedSettings.get(dataset).pipe(map(_temp$
|
|
16909
|
+
$[2] !== dataset ? (t1 = cachedSettings.get(dataset).pipe(map(_temp$3K), startWith(INITIAL_LOADING_STATE$5), catchError(_temp2$1B)), $[2] = dataset, $[3] = t1) : t1 = $[3];
|
|
16910
16910
|
const maxFieldDepth = useObservable(t1, INITIAL_LOADING_STATE$5)?.settings?.partialIndexSettings?.maxFieldDepth;
|
|
16911
16911
|
return isFinite(maxFieldDepth) ? Math.min(maxFieldDepth, DEFAULT_MAX_FIELD_DEPTH) : DEFAULT_MAX_FIELD_DEPTH;
|
|
16912
16912
|
}
|
|
16913
|
-
function _temp2$
|
|
16913
|
+
function _temp2$1B(err) {
|
|
16914
16914
|
return console.error(err), of({
|
|
16915
16915
|
isLoading: !1,
|
|
16916
16916
|
enabled: !0,
|
|
@@ -16921,7 +16921,7 @@ function _temp2$1A(err) {
|
|
|
16921
16921
|
}
|
|
16922
16922
|
});
|
|
16923
16923
|
}
|
|
16924
|
-
function _temp$
|
|
16924
|
+
function _temp$3K(settings) {
|
|
16925
16925
|
return {
|
|
16926
16926
|
isLoading: !1,
|
|
16927
16927
|
settings
|
|
@@ -17065,7 +17065,7 @@ function CreateButton(props2) {
|
|
|
17065
17065
|
const currentUser = useCurrentUser(), {
|
|
17066
17066
|
t
|
|
17067
17067
|
} = useTranslation(), getI18nText = useGetI18nText(createOptions);
|
|
17068
|
-
if (!createOptions.some(_temp$
|
|
17068
|
+
if (!createOptions.some(_temp$3J)) {
|
|
17069
17069
|
let t02;
|
|
17070
17070
|
$[6] !== currentUser ? (t02 = /* @__PURE__ */ jsx(InsufficientPermissionsMessage, { currentUser, context: "create-new-reference" }), $[6] = currentUser, $[7] = t02) : t02 = $[7];
|
|
17071
17071
|
let t1;
|
|
@@ -17078,7 +17078,7 @@ function CreateButton(props2) {
|
|
|
17078
17078
|
let t0;
|
|
17079
17079
|
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;
|
|
17080
17080
|
}
|
|
17081
|
-
function _temp$
|
|
17081
|
+
function _temp$3J(option) {
|
|
17082
17082
|
return option.permission.granted;
|
|
17083
17083
|
}
|
|
17084
17084
|
function sortReleases(releases2 = []) {
|
|
@@ -17120,7 +17120,7 @@ function useActiveReleases() {
|
|
|
17120
17120
|
dispatch
|
|
17121
17121
|
} = useReleasesStore(), state = useObservable(state$);
|
|
17122
17122
|
let t0;
|
|
17123
|
-
$[0] !== state.releases ? (t0 = sortReleases(Array.from(state.releases.values()).filter(_temp$
|
|
17123
|
+
$[0] !== state.releases ? (t0 = sortReleases(Array.from(state.releases.values()).filter(_temp$3I)).reverse(), $[0] = state.releases, $[1] = t0) : t0 = $[1];
|
|
17124
17124
|
const releasesAsArray = t0, t1 = state.error;
|
|
17125
17125
|
let t2;
|
|
17126
17126
|
$[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = ["loading", "initialising"], $[2] = t2) : t2 = $[2];
|
|
@@ -17133,7 +17133,7 @@ function useActiveReleases() {
|
|
|
17133
17133
|
loading: t3
|
|
17134
17134
|
}, $[3] = dispatch, $[4] = releasesAsArray, $[5] = state.error, $[6] = t3, $[7] = t4) : t4 = $[7], t4;
|
|
17135
17135
|
}
|
|
17136
|
-
function _temp$
|
|
17136
|
+
function _temp$3I(release) {
|
|
17137
17137
|
return !ARCHIVED_RELEASE_STATES.includes(release.state);
|
|
17138
17138
|
}
|
|
17139
17139
|
const Dot$2 = styled.div((props2) => {
|
|
@@ -17221,15 +17221,15 @@ function DocumentStatusIndicator(t0) {
|
|
|
17221
17221
|
$[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];
|
|
17222
17222
|
const indicators = t14;
|
|
17223
17223
|
let t15;
|
|
17224
|
-
return $[19] !== indicators ? (t15 = /* @__PURE__ */ jsx(Flex, { children: indicators.filter(_temp$
|
|
17224
|
+
return $[19] !== indicators ? (t15 = /* @__PURE__ */ jsx(Flex, { children: indicators.filter(_temp$3H).map(_temp2$1A) }), $[19] = indicators, $[20] = t15) : t15 = $[20], t15;
|
|
17225
17225
|
}
|
|
17226
|
-
function _temp2$
|
|
17226
|
+
function _temp2$1A(t0, index) {
|
|
17227
17227
|
const {
|
|
17228
17228
|
status
|
|
17229
17229
|
} = t0;
|
|
17230
17230
|
return /* @__PURE__ */ jsx(Dot$2, { "data-status": status, $index: index + 1 }, status);
|
|
17231
17231
|
}
|
|
17232
|
-
function _temp$
|
|
17232
|
+
function _temp$3H(t0) {
|
|
17233
17233
|
const {
|
|
17234
17234
|
show
|
|
17235
17235
|
} = t0;
|
|
@@ -17365,7 +17365,7 @@ function PreviewReferenceValue$2(props2) {
|
|
|
17365
17365
|
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) {
|
|
17366
17366
|
const t72 = value._ref, t82 = value._strengthenOnPublish?.type;
|
|
17367
17367
|
let t92;
|
|
17368
|
-
$[15] !== type.to ? (t92 = type.to.map(_temp$
|
|
17368
|
+
$[15] !== type.to ? (t92 = type.to.map(_temp$3G), $[15] = type.to, $[16] = t92) : t92 = $[16];
|
|
17369
17369
|
let t10;
|
|
17370
17370
|
$[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;
|
|
17371
17371
|
break bb0;
|
|
@@ -17425,17 +17425,17 @@ function PreviewReferenceValue$2(props2) {
|
|
|
17425
17425
|
if (!refType_0) {
|
|
17426
17426
|
const t22 = value._ref, t3 = refTypeName || "<unknown>";
|
|
17427
17427
|
let t4;
|
|
17428
|
-
$[52] !== type.to ? (t4 = type.to.map(_temp2$
|
|
17428
|
+
$[52] !== type.to ? (t4 = type.to.map(_temp2$1z), $[52] = type.to, $[53] = t4) : t4 = $[53];
|
|
17429
17429
|
let t5;
|
|
17430
17430
|
return $[54] !== t3 || $[55] !== t4 || $[56] !== value._ref ? (t5 = /* @__PURE__ */ jsx(InvalidType, { documentId: t22, actualType: t3, declaredTypes: t4 }), $[54] = t3, $[55] = t4, $[56] = value._ref, $[57] = t5) : t5 = $[57], t5;
|
|
17431
17431
|
}
|
|
17432
17432
|
let t2;
|
|
17433
17433
|
return $[58] !== layout || $[59] !== refType_0 || $[60] !== renderPreview || $[61] !== showTypeLabel || $[62] !== value._ref ? (t2 = /* @__PURE__ */ jsx(ReferencePreview, { id: value._ref, layout, refType: refType_0, renderPreview, showTypeLabel }), $[58] = layout, $[59] = refType_0, $[60] = renderPreview, $[61] = showTypeLabel, $[62] = value._ref, $[63] = t2) : t2 = $[63], t2;
|
|
17434
17434
|
}
|
|
17435
|
-
function _temp2$
|
|
17435
|
+
function _temp2$1z(toType_2) {
|
|
17436
17436
|
return toType_2.name;
|
|
17437
17437
|
}
|
|
17438
|
-
function _temp$
|
|
17438
|
+
function _temp$3G(toType_0) {
|
|
17439
17439
|
return toType_0.name;
|
|
17440
17440
|
}
|
|
17441
17441
|
function UnavailableMessage(props2) {
|
|
@@ -17500,13 +17500,13 @@ function HumanizedList(props2) {
|
|
|
17500
17500
|
let T0, t1;
|
|
17501
17501
|
if ($[1] !== listFormat || $[2] !== props2.values) {
|
|
17502
17502
|
const parts = listFormat.formatToParts(props2.values);
|
|
17503
|
-
T0 = Fragment, t1 = parts.map(_temp3$
|
|
17503
|
+
T0 = Fragment, t1 = parts.map(_temp3$I), $[1] = listFormat, $[2] = props2.values, $[3] = T0, $[4] = t1;
|
|
17504
17504
|
} else
|
|
17505
17505
|
T0 = $[3], t1 = $[4];
|
|
17506
17506
|
let t2;
|
|
17507
17507
|
return $[5] !== T0 || $[6] !== t1 ? (t2 = /* @__PURE__ */ jsx(T0, { children: t1 }), $[5] = T0, $[6] = t1, $[7] = t2) : t2 = $[7], t2;
|
|
17508
17508
|
}
|
|
17509
|
-
function _temp3$
|
|
17509
|
+
function _temp3$I(segment) {
|
|
17510
17510
|
return segment.type === "element" ? /* @__PURE__ */ jsx("code", { children: segment.value }, segment.value) : segment.value;
|
|
17511
17511
|
}
|
|
17512
17512
|
const HeaderButton = styled.button`
|
|
@@ -17548,7 +17548,7 @@ function Details(props2) {
|
|
|
17548
17548
|
} = props2, $[0] = props2, $[1] = children, $[2] = icon, $[3] = openProp, $[4] = restProps, $[5] = t0) : (children = $[1], icon = $[2], openProp = $[3], restProps = $[4], t0 = $[5]);
|
|
17549
17549
|
const title = t0 === void 0 ? "Details" : t0, [open, setOpen] = useState(openProp || !1);
|
|
17550
17550
|
let t1;
|
|
17551
|
-
$[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => setOpen(_temp$
|
|
17551
|
+
$[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => setOpen(_temp$3F), $[6] = t1) : t1 = $[6];
|
|
17552
17552
|
const handleToggle = t1;
|
|
17553
17553
|
let t2, t3;
|
|
17554
17554
|
$[7] !== openProp ? (t2 = () => setOpen(openProp || !1), t3 = [openProp], $[7] = openProp, $[8] = t2, $[9] = t3) : (t2 = $[8], t3 = $[9]), useEffect(t2, t3);
|
|
@@ -17576,7 +17576,7 @@ function Details(props2) {
|
|
|
17576
17576
|
t11
|
|
17577
17577
|
] }), $[26] = restProps, $[27] = t11, $[28] = t9, $[29] = t12) : t12 = $[29], t12;
|
|
17578
17578
|
}
|
|
17579
|
-
function _temp$
|
|
17579
|
+
function _temp$3F(v) {
|
|
17580
17580
|
return !v;
|
|
17581
17581
|
}
|
|
17582
17582
|
const STATUS_TONES = {
|
|
@@ -17731,7 +17731,7 @@ const noop$4 = () => {
|
|
|
17731
17731
|
retry: noop$4
|
|
17732
17732
|
};
|
|
17733
17733
|
function useReferenceInfo$2(id2, getReferenceInfo2) {
|
|
17734
|
-
const $ = c(10), [t0] = useState(_temp$
|
|
17734
|
+
const $ = c(10), [t0] = useState(_temp$3E), [onRetry$2, onRetry2] = t0;
|
|
17735
17735
|
let t1;
|
|
17736
17736
|
if ($[0] !== getReferenceInfo2 || $[1] !== id2 || $[2] !== onRetry2 || $[3] !== onRetry$2) {
|
|
17737
17737
|
let t2;
|
|
@@ -17752,7 +17752,7 @@ function useReferenceInfo$2(id2, getReferenceInfo2) {
|
|
|
17752
17752
|
t1 = $[4];
|
|
17753
17753
|
return useObservable(t1, INITIAL_LOADING_STATE$4);
|
|
17754
17754
|
}
|
|
17755
|
-
function _temp$
|
|
17755
|
+
function _temp$3E() {
|
|
17756
17756
|
return observableCallback();
|
|
17757
17757
|
}
|
|
17758
17758
|
const READABLE = {
|
|
@@ -17878,7 +17878,7 @@ function useReferenceInput(options) {
|
|
|
17878
17878
|
let t72;
|
|
17879
17879
|
if ($[22] !== initialValueTemplateItems || $[23] !== schemaType.to) {
|
|
17880
17880
|
let t82;
|
|
17881
|
-
$[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$
|
|
17881
|
+
$[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;
|
|
17882
17882
|
} else
|
|
17883
17883
|
t72 = $[24];
|
|
17884
17884
|
t6 = t72;
|
|
@@ -17897,7 +17897,7 @@ function useReferenceInput(options) {
|
|
|
17897
17897
|
getReferenceInfo: getReferenceInfo$1
|
|
17898
17898
|
}, $[31] = EditReferenceLink, $[32] = createOptions, $[33] = getReferenceInfo$1, $[34] = handleEditReference, $[35] = isCurrentDocumentLiveEdit, $[36] = selectedState, $[37] = t8) : t8 = $[37], t8;
|
|
17899
17899
|
}
|
|
17900
|
-
function _temp$
|
|
17900
|
+
function _temp$3D(item) {
|
|
17901
17901
|
return item.template?.schemaType ? {
|
|
17902
17902
|
id: item.id,
|
|
17903
17903
|
title: item.title || `${item.template.schemaType} from template ${item.template.id}`,
|
|
@@ -17957,7 +17957,7 @@ function ReferenceInputPreview(props2) {
|
|
|
17957
17957
|
$[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = (hadFocus, hasFocus) => {
|
|
17958
17958
|
!hadFocus && hasFocus && elementRef.current && elementRef.current.focus();
|
|
17959
17959
|
}, $[6] = t2) : t2 = $[6], useDidUpdate(focused, t2);
|
|
17960
|
-
const hasErrors = props2.validation.some(_temp$
|
|
17960
|
+
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;
|
|
17961
17961
|
let t3;
|
|
17962
17962
|
$[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];
|
|
17963
17963
|
const refType = t3, pressed = selectedState === "pressed", selected = selectedState === "selected", hasRef = value?._ref, publishedReferenceExists = hasRef && loadableReferenceInfo.result?.isPublished;
|
|
@@ -18048,10 +18048,10 @@ function ReferenceInputPreview(props2) {
|
|
|
18048
18048
|
let t25;
|
|
18049
18049
|
return $[76] !== t24 || $[77] !== tone ? (t25 = /* @__PURE__ */ jsx(Card, { border: !0, radius: 2, padding: 1, tone, children: t24 }), $[76] = t24, $[77] = tone, $[78] = t25) : t25 = $[78], t25;
|
|
18050
18050
|
}
|
|
18051
|
-
function _temp2$
|
|
18051
|
+
function _temp2$1y(v_0) {
|
|
18052
18052
|
return v_0.level === "warning";
|
|
18053
18053
|
}
|
|
18054
|
-
function _temp$
|
|
18054
|
+
function _temp$3C(v) {
|
|
18055
18055
|
return v.level === "error";
|
|
18056
18056
|
}
|
|
18057
18057
|
function useReferenceItemRef() {
|
|
@@ -18167,7 +18167,7 @@ function ReferenceInput(props2) {
|
|
|
18167
18167
|
hits: [],
|
|
18168
18168
|
searchString,
|
|
18169
18169
|
isLoading: !1
|
|
18170
|
-
})))))), scan(_temp$
|
|
18170
|
+
})))))), scan(_temp$3B, INITIAL_SEARCH_STATE$3), tap(setSearchState)), $[24] = id2, $[25] = onSearch, $[26] = push, $[27] = t, $[28] = t5) : t5 = $[28];
|
|
18171
18171
|
const handleQueryChange = useObservableEvent(t5);
|
|
18172
18172
|
let t6;
|
|
18173
18173
|
$[29] !== handleQueryChange ? (t6 = () => {
|
|
@@ -18198,7 +18198,7 @@ function ReferenceInput(props2) {
|
|
|
18198
18198
|
!hadFocusAtRef && hasFocusAtRef && elementProps.ref.current?.focus();
|
|
18199
18199
|
}, $[45] = elementProps, $[46] = t12) : t12 = $[46], useDidUpdate(focusPath?.[0] === "_ref", t12);
|
|
18200
18200
|
let t13;
|
|
18201
|
-
$[47] !== searchState.hits ? (t13 = searchState.hits.map(_temp2$
|
|
18201
|
+
$[47] !== searchState.hits ? (t13 = searchState.hits.map(_temp2$1x), $[47] = searchState.hits, $[48] = t13) : t13 = $[48];
|
|
18202
18202
|
const hits_0 = t13, isEditing = focusPath.length === 1 && focusPath[0] === "_ref", {
|
|
18203
18203
|
menuRef,
|
|
18204
18204
|
menuButtonRef,
|
|
@@ -18240,13 +18240,13 @@ function ReferenceInput(props2) {
|
|
|
18240
18240
|
let t27;
|
|
18241
18241
|
return $[96] !== props2 || $[97] !== t26 ? (t27 = /* @__PURE__ */ jsx(ReferenceInputPreview, { ...props2, children: t26 }), $[96] = props2, $[97] = t26, $[98] = t27) : t27 = $[98], t27;
|
|
18242
18242
|
}
|
|
18243
|
-
function _temp2$
|
|
18243
|
+
function _temp2$1x(hit_0) {
|
|
18244
18244
|
return {
|
|
18245
18245
|
value: hit_0.id,
|
|
18246
18246
|
hit: hit_0
|
|
18247
18247
|
};
|
|
18248
18248
|
}
|
|
18249
|
-
function _temp$
|
|
18249
|
+
function _temp$3B(prevState, nextState) {
|
|
18250
18250
|
return {
|
|
18251
18251
|
...prevState,
|
|
18252
18252
|
...nextState
|
|
@@ -18337,7 +18337,7 @@ function StudioReferenceInput(props2) {
|
|
|
18337
18337
|
})(searchString, {
|
|
18338
18338
|
perspective: options.perspective,
|
|
18339
18339
|
limit: 101
|
|
18340
|
-
}).pipe(map(_temp2$
|
|
18340
|
+
}).pipe(map(_temp2$1w), switchMap((docs) => combineLatest(docs.map((doc) => documentPreviewStore.observePaths({
|
|
18341
18341
|
_id: getPublishedId(doc._id)
|
|
18342
18342
|
}, ["_rev"]).pipe(map((published) => ({
|
|
18343
18343
|
id: doc._id,
|
|
@@ -18380,7 +18380,7 @@ function StudioReferenceInput(props2) {
|
|
|
18380
18380
|
let t92;
|
|
18381
18381
|
if ($[35] !== initialValueTemplateItems || $[36] !== schemaType.to) {
|
|
18382
18382
|
let t102;
|
|
18383
|
-
$[38] !== schemaType.to ? (t102 = (i) => schemaType.to.some((_refType) => _refType.name === i.template?.schemaType), $[38] = schemaType.to, $[39] = t102) : t102 = $[39], t92 = (initialValueTemplateItems || []).filter(t102).map(_temp3$
|
|
18383
|
+
$[38] !== schemaType.to ? (t102 = (i) => schemaType.to.some((_refType) => _refType.name === i.template?.schemaType), $[38] = schemaType.to, $[39] = t102) : t102 = $[39], t92 = (initialValueTemplateItems || []).filter(t102).map(_temp3$H).filter(isNonNullable$3), $[35] = initialValueTemplateItems, $[36] = schemaType.to, $[37] = t92;
|
|
18384
18384
|
} else
|
|
18385
18385
|
t92 = $[37];
|
|
18386
18386
|
t8 = t92;
|
|
@@ -18392,7 +18392,7 @@ function StudioReferenceInput(props2) {
|
|
|
18392
18392
|
let t10;
|
|
18393
18393
|
return $[43] !== EditReferenceLink || $[44] !== createOptions || $[45] !== getReferenceInfo$1 || $[46] !== handleEditReference || $[47] !== handleSearch || $[48] !== isDocumentLiveEdit || $[49] !== props2 || $[50] !== selectedState ? (t10 = /* @__PURE__ */ jsx(ReferenceInput, { ...props2, onSearch: handleSearch, liveEdit: isDocumentLiveEdit, getReferenceInfo: getReferenceInfo$1, selectedState, editReferenceLinkComponent: EditReferenceLink, createOptions, onEditReference: handleEditReference }), $[43] = EditReferenceLink, $[44] = createOptions, $[45] = getReferenceInfo$1, $[46] = handleEditReference, $[47] = handleSearch, $[48] = isDocumentLiveEdit, $[49] = props2, $[50] = selectedState, $[51] = t10) : t10 = $[51], t10;
|
|
18394
18394
|
}
|
|
18395
|
-
function _temp3$
|
|
18395
|
+
function _temp3$H(item) {
|
|
18396
18396
|
return item.template?.schemaType ? {
|
|
18397
18397
|
id: item.id,
|
|
18398
18398
|
title: item.title || `${item.template.schemaType} from template ${item.template?.id}`,
|
|
@@ -18409,13 +18409,13 @@ function _temp3$G(item) {
|
|
|
18409
18409
|
}
|
|
18410
18410
|
} : void 0;
|
|
18411
18411
|
}
|
|
18412
|
-
function _temp2$
|
|
18412
|
+
function _temp2$1w(t0) {
|
|
18413
18413
|
const {
|
|
18414
18414
|
hits
|
|
18415
18415
|
} = t0;
|
|
18416
|
-
return hits.map(_temp$
|
|
18416
|
+
return hits.map(_temp$3A);
|
|
18417
18417
|
}
|
|
18418
|
-
function _temp$
|
|
18418
|
+
function _temp$3A(t0) {
|
|
18419
18419
|
const {
|
|
18420
18420
|
hit
|
|
18421
18421
|
} = t0;
|
|
@@ -18646,7 +18646,7 @@ function ArrayOfObjectsItem(props2) {
|
|
|
18646
18646
|
$[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) => {
|
|
18647
18647
|
if (event_0.items.length === 0)
|
|
18648
18648
|
throw new Error("Insert event should include at least one item");
|
|
18649
|
-
const itemsWithKeys = event_0.items.map(_temp$
|
|
18649
|
+
const itemsWithKeys = event_0.items.map(_temp$3z);
|
|
18650
18650
|
onChange(PatchEvent.from([insert$1(itemsWithKeys, event_0.position, [{
|
|
18651
18651
|
_key: member.key
|
|
18652
18652
|
}])]));
|
|
@@ -18826,7 +18826,7 @@ function ArrayOfObjectsItem(props2) {
|
|
|
18826
18826
|
let t29;
|
|
18827
18827
|
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;
|
|
18828
18828
|
}
|
|
18829
|
-
function _temp$
|
|
18829
|
+
function _temp$3z(item) {
|
|
18830
18830
|
return ensureKey(item);
|
|
18831
18831
|
}
|
|
18832
18832
|
function RenderInput$5({
|
|
@@ -18871,7 +18871,7 @@ function IncompatibleItemType$2(props2) {
|
|
|
18871
18871
|
const handleKeyDown = t2;
|
|
18872
18872
|
let t3;
|
|
18873
18873
|
$[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = () => {
|
|
18874
|
-
setShowDetails(_temp$
|
|
18874
|
+
setShowDetails(_temp$3y);
|
|
18875
18875
|
}, $[7] = t3) : t3 = $[7];
|
|
18876
18876
|
const handleShowDetails = t3;
|
|
18877
18877
|
let t4;
|
|
@@ -18940,7 +18940,7 @@ function IncompatibleItemType$2(props2) {
|
|
|
18940
18940
|
let t24;
|
|
18941
18941
|
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;
|
|
18942
18942
|
}
|
|
18943
|
-
function _temp$
|
|
18943
|
+
function _temp$3y(v) {
|
|
18944
18944
|
return !v;
|
|
18945
18945
|
}
|
|
18946
18946
|
function MemberItemError(props2) {
|
|
@@ -19736,7 +19736,7 @@ function ArrayOfObjectsField(props2) {
|
|
|
19736
19736
|
let t7;
|
|
19737
19737
|
$[12] !== member.name || $[13] !== onChange ? (t7 = (event_1) => {
|
|
19738
19738
|
const patches = PatchEvent.from(event_1).patches;
|
|
19739
|
-
if (patches.some(_temp$
|
|
19739
|
+
if (patches.some(_temp$3x) && (valueRef.current = applyAll(valueRef.current || [], patches), Array.isArray(valueRef.current) && !valueRef.current.length)) {
|
|
19740
19740
|
onChange(PatchEvent.from(unset([member.name])));
|
|
19741
19741
|
return;
|
|
19742
19742
|
}
|
|
@@ -19783,7 +19783,7 @@ function ArrayOfObjectsField(props2) {
|
|
|
19783
19783
|
$[34] !== handleChange || $[35] !== handleOpenItem || $[36] !== member.field.path || $[37] !== member.field.schemaType || $[38] !== onPathFocus || $[39] !== resolveInitialValue2 || $[40] !== toast ? (t14 = (event_2) => {
|
|
19784
19784
|
if (event_2.items.length === 0)
|
|
19785
19785
|
throw new Error("Insert event should include at least one item");
|
|
19786
|
-
const itemsWithKeys = event_2.items.map(_temp2$
|
|
19786
|
+
const itemsWithKeys = event_2.items.map(_temp2$1v);
|
|
19787
19787
|
handleChange(PatchEvent.from([insert$1(itemsWithKeys, event_2.position, [event_2.referenceItem])]));
|
|
19788
19788
|
const focusItemKey = itemsWithKeys[0]._key, itemPath = [...member.field.path, {
|
|
19789
19789
|
_key: focusItemKey
|
|
@@ -19910,7 +19910,7 @@ function ArrayOfObjectsField(props2) {
|
|
|
19910
19910
|
break bb183;
|
|
19911
19911
|
}
|
|
19912
19912
|
case "error": {
|
|
19913
|
-
event_4.files.forEach(_temp3$
|
|
19913
|
+
event_4.files.forEach(_temp3$G), toast.push({
|
|
19914
19914
|
status: "error",
|
|
19915
19915
|
description: t("asset-sources.common.uploader.upload-failed.description"),
|
|
19916
19916
|
title: t("asset-sources.common.uploader.upload-failed.title")
|
|
@@ -20000,13 +20000,13 @@ function ArrayOfObjectsField(props2) {
|
|
|
20000
20000
|
assetSourceUploadComponents
|
|
20001
20001
|
] }), $[136] = assetSourceUploadComponents, $[137] = handleChange, $[138] = onFieldGroupSelect, $[139] = onPathBlur, $[140] = onPathFocus, $[141] = onPathOpen, $[142] = onSetFieldSetCollapsed, $[143] = onSetPathCollapsed, $[144] = t31, $[145] = t32) : t32 = $[145], t32;
|
|
20002
20002
|
}
|
|
20003
|
-
function _temp3$
|
|
20003
|
+
function _temp3$G(_file) {
|
|
20004
20004
|
console.error(_file.error);
|
|
20005
20005
|
}
|
|
20006
|
-
function _temp2$
|
|
20006
|
+
function _temp2$1v(item) {
|
|
20007
20007
|
return ensureKey(item);
|
|
20008
20008
|
}
|
|
20009
|
-
function _temp$
|
|
20009
|
+
function _temp$3x(patch2) {
|
|
20010
20010
|
return patch2.type === "unset" && patch2.path.length === 1;
|
|
20011
20011
|
}
|
|
20012
20012
|
function RenderInput$3({
|
|
@@ -20097,7 +20097,7 @@ function ArrayOfPrimitivesField(props2) {
|
|
|
20097
20097
|
let t3;
|
|
20098
20098
|
$[7] !== member.field.value || $[8] !== member.name || $[9] !== onChange ? (t3 = (event_1) => {
|
|
20099
20099
|
const patches = PatchEvent.from(event_1).patches;
|
|
20100
|
-
if (patches.some(_temp$
|
|
20100
|
+
if (patches.some(_temp$3w)) {
|
|
20101
20101
|
const result = applyAll(member.field.value || [], patches);
|
|
20102
20102
|
if (Array.isArray(result) && !result.length) {
|
|
20103
20103
|
onChange(PatchEvent.from(unset([member.name])));
|
|
@@ -20192,7 +20192,7 @@ function ArrayOfPrimitivesField(props2) {
|
|
|
20192
20192
|
file: file_0,
|
|
20193
20193
|
schemaType: schemaType_0,
|
|
20194
20194
|
uploader
|
|
20195
|
-
} = t212, events$ = uploader.upload(client, file_0, schemaType_0).pipe(map(_temp2$
|
|
20195
|
+
} = t212, events$ = uploader.upload(client, file_0, schemaType_0).pipe(map(_temp2$1u), tap((event_4) => handleChange(event_4.patches)));
|
|
20196
20196
|
uploadSubscriptions.current && uploadSubscriptions.current.unsubscribe(), uploadSubscriptions.current = events$.subscribe();
|
|
20197
20197
|
}, $[51] = client, $[52] = handleChange, $[53] = t20) : t20 = $[53];
|
|
20198
20198
|
const handleUpload = t20, t21 = member.field.value, t22 = member.field.displayInlineChanges ?? !1;
|
|
@@ -20240,10 +20240,10 @@ function ArrayOfPrimitivesField(props2) {
|
|
|
20240
20240
|
let t27;
|
|
20241
20241
|
return $[110] !== handleChange || $[111] !== onFieldGroupSelect || $[112] !== onPathBlur || $[113] !== onPathFocus || $[114] !== onPathOpen || $[115] !== onSetFieldSetCollapsed || $[116] !== onSetPathCollapsed || $[117] !== t26 ? (t27 = /* @__PURE__ */ jsx(FormCallbacksProvider, { onFieldGroupSelect, onChange: handleChange, onPathOpen, onSetFieldSetCollapsed, onSetPathCollapsed, onPathBlur, onPathFocus, children: t26 }), $[110] = handleChange, $[111] = onFieldGroupSelect, $[112] = onPathBlur, $[113] = onPathFocus, $[114] = onPathOpen, $[115] = onSetFieldSetCollapsed, $[116] = onSetPathCollapsed, $[117] = t26, $[118] = t27) : t27 = $[118], t27;
|
|
20242
20242
|
}
|
|
20243
|
-
function _temp2$
|
|
20243
|
+
function _temp2$1u(uploadProgressEvent) {
|
|
20244
20244
|
return PatchEvent.from(uploadProgressEvent.patches || []);
|
|
20245
20245
|
}
|
|
20246
|
-
function _temp$
|
|
20246
|
+
function _temp$3w(patch2) {
|
|
20247
20247
|
return patch2.type === "unset" && patch2.path.length === 1;
|
|
20248
20248
|
}
|
|
20249
20249
|
function RenderInput$2({
|
|
@@ -20495,7 +20495,7 @@ function PrimitiveField(props2) {
|
|
|
20495
20495
|
}, $[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];
|
|
20496
20496
|
const elementProps = t11;
|
|
20497
20497
|
let t12;
|
|
20498
|
-
$[32] !== member.field.validation ? (t12 = member.field.validation.filter(_temp$
|
|
20498
|
+
$[32] !== member.field.validation ? (t12 = member.field.validation.filter(_temp$3v).map(_temp2$1t).join(`
|
|
20499
20499
|
`) || void 0, $[32] = member.field.validation, $[33] = t12) : t12 = $[33];
|
|
20500
20500
|
const validationError = t12, t13 = member.field.value, t14 = member.field.schemaType, t15 = member.field.displayInlineChanges ?? !1;
|
|
20501
20501
|
let t16;
|
|
@@ -20524,10 +20524,10 @@ function PrimitiveField(props2) {
|
|
|
20524
20524
|
let t21;
|
|
20525
20525
|
return $[55] !== fieldActions || $[56] !== member.field.changed || $[57] !== member.field.id || $[58] !== member.field.level || $[59] !== member.field.path || $[60] !== member.field.presence || $[61] !== member.field.schemaType.description || $[62] !== member.field.schemaType.title || $[63] !== member.field.validation || $[64] !== member.index || $[65] !== member.name || $[66] !== renderField || $[67] !== t17 || $[68] !== t18 || $[69] !== t19 || $[70] !== t20 ? (t21 = /* @__PURE__ */ jsx(RenderField, { actions: fieldActions, changed: member.field.changed, description: member.field.schemaType.description, index: member.index, inputId: member.field.id, inputProps: t17, level: member.field.level, name: member.name, path: member.field.path, presence: member.field.presence, schemaType: t18, title: member.field.schemaType.title, validation: member.field.validation, value: t19, render: renderField, children: t20 }), $[55] = fieldActions, $[56] = member.field.changed, $[57] = member.field.id, $[58] = member.field.level, $[59] = member.field.path, $[60] = member.field.presence, $[61] = member.field.schemaType.description, $[62] = member.field.schemaType.title, $[63] = member.field.validation, $[64] = member.index, $[65] = member.name, $[66] = renderField, $[67] = t17, $[68] = t18, $[69] = t19, $[70] = t20, $[71] = t21) : t21 = $[71], t21;
|
|
20526
20526
|
}
|
|
20527
|
-
function _temp2$
|
|
20527
|
+
function _temp2$1t(item_0) {
|
|
20528
20528
|
return item_0.message;
|
|
20529
20529
|
}
|
|
20530
|
-
function _temp$
|
|
20530
|
+
function _temp$3v(item) {
|
|
20531
20531
|
return item.level === "error";
|
|
20532
20532
|
}
|
|
20533
20533
|
function RenderInput({
|
|
@@ -20707,7 +20707,7 @@ function UntypedValueInput(t0) {
|
|
|
20707
20707
|
let t6;
|
|
20708
20708
|
$[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];
|
|
20709
20709
|
let t7;
|
|
20710
|
-
$[16] !== isSingleValidType || $[17] !== validTypes ? (t7 = !isSingleValidType && /* @__PURE__ */ jsx(Stack, { as: "ul", space: 2, children: validTypes.map(_temp$
|
|
20710
|
+
$[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];
|
|
20711
20711
|
let t8;
|
|
20712
20712
|
$[19] !== t ? (t8 = t("inputs.untyped-value.details.json-dump-prefix"), $[19] = t, $[20] = t8) : t8 = $[20];
|
|
20713
20713
|
let t9;
|
|
@@ -20746,7 +20746,7 @@ function UntypedValueInput(t0) {
|
|
|
20746
20746
|
let t19;
|
|
20747
20747
|
return $[53] !== t18 || $[54] !== t2 ? (t19 = /* @__PURE__ */ jsx(Alert, { status: "warning", title: t2, children: t18 }), $[53] = t18, $[54] = t2, $[55] = t19) : t19 = $[55], t19;
|
|
20748
20748
|
}
|
|
20749
|
-
function _temp$
|
|
20749
|
+
function _temp$3u(validType) {
|
|
20750
20750
|
return /* @__PURE__ */ jsx(Text$1, { as: "li", muted: !0, size: 1, children: /* @__PURE__ */ jsx("code", { children: validType }) }, validType);
|
|
20751
20751
|
}
|
|
20752
20752
|
function getConverters(value, actualType, validTypes) {
|
|
@@ -20763,7 +20763,7 @@ const InvalidValueInput = forwardRef((props2, ref) => {
|
|
|
20763
20763
|
validTypes,
|
|
20764
20764
|
onChange
|
|
20765
20765
|
} = props2;
|
|
20766
|
-
useImperativeHandle(ref, _temp2$
|
|
20766
|
+
useImperativeHandle(ref, _temp2$1s);
|
|
20767
20767
|
let t0;
|
|
20768
20768
|
$[0] !== onChange ? (t0 = () => {
|
|
20769
20769
|
onChange(PatchEvent.from(unset()));
|
|
@@ -20806,7 +20806,7 @@ const InvalidValueInput = forwardRef((props2, ref) => {
|
|
|
20806
20806
|
let t11;
|
|
20807
20807
|
$[32] !== t || $[33] !== validTypes.length ? (t11 = validTypes.length !== 1 && /* @__PURE__ */ jsx(Text$1, { as: "p", muted: !0, size: 1, children: t("inputs.invalid-value.details.multi-type-description") }), $[32] = t, $[33] = validTypes.length, $[34] = t11) : t11 = $[34];
|
|
20808
20808
|
let t12;
|
|
20809
|
-
$[35] !== validTypes ? (t12 = validTypes.length !== 1 && /* @__PURE__ */ jsx(Stack, { as: "ul", space: 2, children: validTypes.map(_temp3$
|
|
20809
|
+
$[35] !== validTypes ? (t12 = validTypes.length !== 1 && /* @__PURE__ */ jsx(Stack, { as: "ul", space: 2, children: validTypes.map(_temp3$F) }), $[35] = validTypes, $[36] = t12) : t12 = $[36];
|
|
20810
20810
|
let t13;
|
|
20811
20811
|
$[37] !== actualType ? (t13 = {
|
|
20812
20812
|
actualType
|
|
@@ -20860,14 +20860,14 @@ function ConvertButton(t0) {
|
|
|
20860
20860
|
let t3;
|
|
20861
20861
|
return $[7] !== handleClick || $[8] !== t2 ? (t3 = /* @__PURE__ */ jsx(Button, { onClick: handleClick, text: t2 }), $[7] = handleClick, $[8] = t2, $[9] = t3) : t3 = $[9], t3;
|
|
20862
20862
|
}
|
|
20863
|
-
function _temp$
|
|
20863
|
+
function _temp$3t() {
|
|
20864
20864
|
}
|
|
20865
|
-
function _temp2$
|
|
20865
|
+
function _temp2$1s() {
|
|
20866
20866
|
return {
|
|
20867
|
-
focus: _temp$
|
|
20867
|
+
focus: _temp$3t
|
|
20868
20868
|
};
|
|
20869
20869
|
}
|
|
20870
|
-
function _temp3$
|
|
20870
|
+
function _temp3$F(validType) {
|
|
20871
20871
|
return /* @__PURE__ */ jsx(Text$1, { as: "li", children: /* @__PURE__ */ jsx("code", { children: validType }) }, validType);
|
|
20872
20872
|
}
|
|
20873
20873
|
const MAX_AVATARS_DOCK = 3, DEFAULT_MAX_AVATARS_FIELDS = 3, AVATAR_DISTANCE = -4, AVATAR_SIZE = 25, AVATAR_ARROW_HEIGHT = 4, INTERSECTION_THRESHOLDS = [0, 0.25, 0.75, 1], INTERSECTION_ELEMENT_PADDING = 23, SNAP_TO_DOCK_DISTANCE_TOP = 8, SNAP_TO_DOCK_DISTANCE_BOTTOM = 8, SLIDE_RIGHT_THRESHOLD_TOP = 20, SLIDE_RIGHT_THRESHOLD_BOTTOM = 20, DEBUG$1 = !1, splitRight = (array, max2) => {
|
|
@@ -21103,11 +21103,11 @@ function FormFieldValidationStatus(props2) {
|
|
|
21103
21103
|
__unstable_showSummary: showSummary,
|
|
21104
21104
|
fontSize,
|
|
21105
21105
|
placement
|
|
21106
|
-
} = props2, validation2 = t0 === void 0 ? EMPTY_ARRAY$w : t0, hasErrors = validation2.some(_temp$
|
|
21106
|
+
} = 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];
|
|
21107
21107
|
let t1;
|
|
21108
21108
|
$[0] !== showSummary || $[1] !== validation2 ? (t1 = showSummary && /* @__PURE__ */ jsx(FormFieldValidationSummary, { validation: validation2 }), $[0] = showSummary, $[1] = validation2, $[2] = t1) : t1 = $[2];
|
|
21109
21109
|
let t2;
|
|
21110
|
-
$[3] !== showSummary || $[4] !== validation2 ? (t2 = !showSummary && /* @__PURE__ */ jsx(Fragment$1, { children: validation2.map(_temp3$
|
|
21110
|
+
$[3] !== showSummary || $[4] !== validation2 ? (t2 = !showSummary && /* @__PURE__ */ jsx(Fragment$1, { children: validation2.map(_temp3$E) }), $[3] = showSummary, $[4] = validation2, $[5] = t2) : t2 = $[5];
|
|
21111
21111
|
let t3;
|
|
21112
21112
|
$[6] !== t1 || $[7] !== t2 ? (t3 = /* @__PURE__ */ jsxs(StyledStack, { space: 3, children: [
|
|
21113
21113
|
t1,
|
|
@@ -21122,13 +21122,13 @@ function FormFieldValidationStatus(props2) {
|
|
|
21122
21122
|
let t7;
|
|
21123
21123
|
return $[16] !== placement || $[17] !== t3 || $[18] !== t6 ? (t7 = /* @__PURE__ */ jsx(Tooltip, { content: t3, portal: !0, placement, fallbackPlacements: t4, children: t6 }), $[16] = placement, $[17] = t3, $[18] = t6, $[19] = t7) : t7 = $[19], t7;
|
|
21124
21124
|
}
|
|
21125
|
-
function _temp3$
|
|
21125
|
+
function _temp3$E(item, itemIndex) {
|
|
21126
21126
|
return /* @__PURE__ */ jsx(FormFieldValidationStatusItem, { validation: item }, itemIndex);
|
|
21127
21127
|
}
|
|
21128
|
-
function _temp2$
|
|
21128
|
+
function _temp2$1r(v_0) {
|
|
21129
21129
|
return v_0.level === "warning";
|
|
21130
21130
|
}
|
|
21131
|
-
function _temp$
|
|
21131
|
+
function _temp$3s(v) {
|
|
21132
21132
|
return v.level === "error";
|
|
21133
21133
|
}
|
|
21134
21134
|
function FormFieldValidationStatusItem(props2) {
|
|
@@ -21541,7 +21541,7 @@ function DuplicateKeysAlert(props2) {
|
|
|
21541
21541
|
} = props2;
|
|
21542
21542
|
let t0;
|
|
21543
21543
|
$[0] !== error.duplicates || $[1] !== onChange ? (t0 = () => {
|
|
21544
|
-
onChange(PatchEvent.from((error.duplicates || []).map(_temp$
|
|
21544
|
+
onChange(PatchEvent.from((error.duplicates || []).map(_temp$3r)));
|
|
21545
21545
|
}, $[0] = error.duplicates, $[1] = onChange, $[2] = t0) : t0 = $[2];
|
|
21546
21546
|
const handleFixDuplicateKeys = t0, {
|
|
21547
21547
|
t
|
|
@@ -21577,7 +21577,7 @@ function DuplicateKeysAlert(props2) {
|
|
|
21577
21577
|
let t14;
|
|
21578
21578
|
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;
|
|
21579
21579
|
}
|
|
21580
|
-
function _temp$
|
|
21580
|
+
function _temp$3r(t0) {
|
|
21581
21581
|
const [index, key] = t0;
|
|
21582
21582
|
return set(`${key}_deduped_${index}`, [index, "_key"]);
|
|
21583
21583
|
}
|
|
@@ -21588,7 +21588,7 @@ function MissingKeysAlert(props2) {
|
|
|
21588
21588
|
} = props2;
|
|
21589
21589
|
let t0;
|
|
21590
21590
|
$[0] !== error.value || $[1] !== onChange ? (t0 = () => {
|
|
21591
|
-
onChange(PatchEvent.from((error.value || []).map(_temp$
|
|
21591
|
+
onChange(PatchEvent.from((error.value || []).map(_temp$3q)));
|
|
21592
21592
|
}, $[0] = error.value, $[1] = onChange, $[2] = t0) : t0 = $[2];
|
|
21593
21593
|
const handleFixMissingKeys = t0, {
|
|
21594
21594
|
t
|
|
@@ -21624,7 +21624,7 @@ function MissingKeysAlert(props2) {
|
|
|
21624
21624
|
let t14;
|
|
21625
21625
|
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;
|
|
21626
21626
|
}
|
|
21627
|
-
function _temp$
|
|
21627
|
+
function _temp$3q(val, i) {
|
|
21628
21628
|
return setIfMissing(randomKey$1(), [i, "_key"]);
|
|
21629
21629
|
}
|
|
21630
21630
|
function MixedArrayAlert(props2) {
|
|
@@ -21634,7 +21634,7 @@ function MixedArrayAlert(props2) {
|
|
|
21634
21634
|
} = props2;
|
|
21635
21635
|
let t0;
|
|
21636
21636
|
$[0] !== error.value || $[1] !== onChange ? (t0 = () => {
|
|
21637
|
-
const patches = (error.value || []).flatMap(_temp$
|
|
21637
|
+
const patches = (error.value || []).flatMap(_temp$3p).reverse().map(_temp2$1q);
|
|
21638
21638
|
onChange(PatchEvent.from(patches));
|
|
21639
21639
|
}, $[0] = error.value, $[1] = onChange, $[2] = t0) : t0 = $[2];
|
|
21640
21640
|
const handleRemoveNonObjectValues = t0, {
|
|
@@ -21666,10 +21666,10 @@ function MixedArrayAlert(props2) {
|
|
|
21666
21666
|
let t13;
|
|
21667
21667
|
return $[28] !== error.schemaType.description || $[29] !== error.schemaType.title || $[30] !== t12 ? (t13 = /* @__PURE__ */ jsx(FormField, { title: t1, description: t2, children: t12 }), $[28] = error.schemaType.description, $[29] = error.schemaType.title, $[30] = t12, $[31] = t13) : t13 = $[31], t13;
|
|
21668
21668
|
}
|
|
21669
|
-
function _temp2$
|
|
21669
|
+
function _temp2$1q(index_0) {
|
|
21670
21670
|
return unset([index_0]);
|
|
21671
21671
|
}
|
|
21672
|
-
function _temp$
|
|
21672
|
+
function _temp$3p(item, index) {
|
|
21673
21673
|
return isPlainObject$1(item) ? [] : [index];
|
|
21674
21674
|
}
|
|
21675
21675
|
function MemberFieldError(props2) {
|
|
@@ -21992,7 +21992,7 @@ function fileTarget(Component2) {
|
|
|
21992
21992
|
}, t6 = [pasteTarget, handlePaste], $[16] = handlePaste, $[17] = pasteTarget, $[18] = t5, $[19] = t6) : (t5 = $[18], t6 = $[19]), useEffect(t5, t6);
|
|
21993
21993
|
let t7;
|
|
21994
21994
|
$[20] !== emitFiles || $[21] !== onFiles || $[22] !== onFilesOut ? (t7 = (event_2) => {
|
|
21995
|
-
if (enteredElements.current = [], Array.from(event_2.dataTransfer.items).map(_temp$
|
|
21995
|
+
if (enteredElements.current = [], Array.from(event_2.dataTransfer.items).map(_temp$3o).some(_temp2$1p))
|
|
21996
21996
|
return;
|
|
21997
21997
|
event_2.preventDefault(), event_2.stopPropagation();
|
|
21998
21998
|
const dataTransfer = event_2.nativeEvent.dataTransfer;
|
|
@@ -22004,7 +22004,7 @@ function fileTarget(Component2) {
|
|
|
22004
22004
|
let t8;
|
|
22005
22005
|
$[24] !== onFiles ? (t8 = (event_3) => {
|
|
22006
22006
|
if (onFiles) {
|
|
22007
|
-
if (Array.from(event_3.dataTransfer.items).map(_temp3$
|
|
22007
|
+
if (Array.from(event_3.dataTransfer.items).map(_temp3$D).some(_temp4$i))
|
|
22008
22008
|
return;
|
|
22009
22009
|
event_3.preventDefault(), event_3.stopPropagation();
|
|
22010
22010
|
}
|
|
@@ -22054,16 +22054,16 @@ function select(el) {
|
|
|
22054
22054
|
const sel = window.getSelection();
|
|
22055
22055
|
sel?.removeAllRanges(), sel?.addRange(range2);
|
|
22056
22056
|
}
|
|
22057
|
-
function _temp$
|
|
22057
|
+
function _temp$3o(item) {
|
|
22058
22058
|
return {
|
|
22059
22059
|
type: item.type,
|
|
22060
22060
|
kind: item.kind
|
|
22061
22061
|
};
|
|
22062
22062
|
}
|
|
22063
|
-
function _temp2$
|
|
22063
|
+
function _temp2$1p(item_0) {
|
|
22064
22064
|
return isPortableTextItem(item_0);
|
|
22065
22065
|
}
|
|
22066
|
-
function _temp3$
|
|
22066
|
+
function _temp3$D(item_1) {
|
|
22067
22067
|
return {
|
|
22068
22068
|
type: item_1.type,
|
|
22069
22069
|
kind: item_1.kind
|
|
@@ -22098,7 +22098,7 @@ function UploadDestinationPicker(props2) {
|
|
|
22098
22098
|
onClose
|
|
22099
22099
|
} = props2, {
|
|
22100
22100
|
t
|
|
22101
|
-
} = useTranslation(), assetSourcesWithUpload = assetSources.filter(_temp$
|
|
22101
|
+
} = useTranslation(), assetSourcesWithUpload = assetSources.filter(_temp$3n);
|
|
22102
22102
|
let t0;
|
|
22103
22103
|
$[0] !== assetSources || $[1] !== onSelectAssetSource ? (t0 = (event) => {
|
|
22104
22104
|
const sourceName2 = event.currentTarget.getAttribute("data-asset-source-name"), assetSource = assetSources.find((source) => source.name === sourceName2);
|
|
@@ -22132,7 +22132,7 @@ function UploadDestinationPicker(props2) {
|
|
|
22132
22132
|
let t12;
|
|
22133
22133
|
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;
|
|
22134
22134
|
}
|
|
22135
|
-
function _temp$
|
|
22135
|
+
function _temp$3n(s) {
|
|
22136
22136
|
return !!s.Uploader;
|
|
22137
22137
|
}
|
|
22138
22138
|
const Overlay$2 = styled(Layer)`
|
|
@@ -22175,14 +22175,14 @@ function uploadTarget$1(Component2) {
|
|
|
22175
22175
|
const [filesToUpload, setFilesToUpload] = useState(t0), [showAssetSourceDestinationPicker, setShowAssetSourceDestinationPicker] = useState(!1), [tone, setTone] = useState(toneFromProps || (isReadOnly ? "transparent" : "default")), assetSourceDestinationName = useRef(null);
|
|
22176
22176
|
let t1;
|
|
22177
22177
|
$[10] !== formBuilder || $[11] !== onSelectFile || $[12] !== pushToast || $[13] !== t || $[14] !== types ? (t1 = (files) => {
|
|
22178
|
-
const filesAndAssetSources = getFilesAndAssetSources(files, types, assetSourceDestinationName.current, formBuilder), ready = filesAndAssetSources.filter(_temp$
|
|
22178
|
+
const filesAndAssetSources = getFilesAndAssetSources(files, types, assetSourceDestinationName.current, formBuilder), ready = filesAndAssetSources.filter(_temp$3m), rejected = filesAndAssetSources.filter(_temp2$1o);
|
|
22179
22179
|
rejected.length > 0 && pushToast({
|
|
22180
22180
|
closable: !0,
|
|
22181
22181
|
status: "warning",
|
|
22182
22182
|
title: t("inputs.array.error.cannot-upload-unable-to-convert", {
|
|
22183
22183
|
count: rejected.length
|
|
22184
22184
|
}),
|
|
22185
|
-
description: rejected.map(_temp3$
|
|
22185
|
+
description: rejected.map(_temp3$C)
|
|
22186
22186
|
}), onSelectFile && ready.forEach((entry_1) => {
|
|
22187
22187
|
onSelectFile({
|
|
22188
22188
|
assetSource: entry_1.assetSource,
|
|
@@ -22287,13 +22287,13 @@ function getFilesAndAssetSources(files, types, assetSourceDestinationName, formB
|
|
|
22287
22287
|
};
|
|
22288
22288
|
});
|
|
22289
22289
|
}
|
|
22290
|
-
function _temp$
|
|
22290
|
+
function _temp$3m(entry) {
|
|
22291
22291
|
return entry.assetSource !== null;
|
|
22292
22292
|
}
|
|
22293
|
-
function _temp2$
|
|
22293
|
+
function _temp2$1o(entry_0) {
|
|
22294
22294
|
return entry_0.assetSource === null;
|
|
22295
22295
|
}
|
|
22296
|
-
function _temp3$
|
|
22296
|
+
function _temp3$C(task, i) {
|
|
22297
22297
|
return /* @__PURE__ */ jsxs(Flex, { gap: 2, padding: 2, children: [
|
|
22298
22298
|
/* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$1, { weight: "medium", children: task.file.name }) }),
|
|
22299
22299
|
/* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$1, { size: 1, children: [
|
|
@@ -22571,7 +22571,7 @@ function ArrayOfObjectsFunctions(props2) {
|
|
|
22571
22571
|
let t6;
|
|
22572
22572
|
$[18] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t6 = ["top"], $[18] = t6) : t6 = $[18];
|
|
22573
22573
|
let t7;
|
|
22574
|
-
$[19] !== props2.schemaType.options?.insertMenu?.views ? (t7 = props2.schemaType.options?.insertMenu?.views?.some(_temp$
|
|
22574
|
+
$[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];
|
|
22575
22575
|
let t8;
|
|
22576
22576
|
$[21] !== gridElement || $[22] !== popoverToggleElement || $[23] !== t7 ? (t8 = {
|
|
22577
22577
|
placement: "bottom",
|
|
@@ -22615,7 +22615,7 @@ function ArrayOfObjectsFunctions(props2) {
|
|
|
22615
22615
|
children
|
|
22616
22616
|
] }), $[41] = children, $[42] = t11, $[43] = t12) : t12 = $[43], t12;
|
|
22617
22617
|
}
|
|
22618
|
-
function _temp$
|
|
22618
|
+
function _temp$3l(view) {
|
|
22619
22619
|
return view.name === "grid";
|
|
22620
22620
|
}
|
|
22621
22621
|
const DragHandleButton = styled(Button)((props2) => {
|
|
@@ -22769,7 +22769,7 @@ function IncompatibleItemType$1(props2) {
|
|
|
22769
22769
|
const handleKeyDown = t2;
|
|
22770
22770
|
let t3;
|
|
22771
22771
|
$[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = () => {
|
|
22772
|
-
setShowDetails(_temp$
|
|
22772
|
+
setShowDetails(_temp$3k);
|
|
22773
22773
|
}, $[7] = t3) : t3 = $[7];
|
|
22774
22774
|
const handleShowDetails = t3;
|
|
22775
22775
|
let t4;
|
|
@@ -22835,7 +22835,7 @@ function IncompatibleItemType$1(props2) {
|
|
|
22835
22835
|
let t23;
|
|
22836
22836
|
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;
|
|
22837
22837
|
}
|
|
22838
|
-
function _temp$
|
|
22838
|
+
function _temp$3k(v) {
|
|
22839
22839
|
return !v;
|
|
22840
22840
|
}
|
|
22841
22841
|
const MENU_POPOVER_PROPS$8 = {
|
|
@@ -22985,20 +22985,20 @@ function useDocumentPreview(props2) {
|
|
|
22985
22985
|
viewOptions: {
|
|
22986
22986
|
ordering
|
|
22987
22987
|
}
|
|
22988
|
-
}).pipe(map(_temp$
|
|
22988
|
+
}).pipe(map(_temp$3j), catchError(_temp2$1n)), $[3] = chosenPerspectiveStack, $[4] = observeForPreview, $[5] = ordering, $[6] = perspectiveStack, $[7] = previewValue, $[8] = schemaType, $[9] = t3;
|
|
22989
22989
|
} else
|
|
22990
22990
|
t3 = $[9];
|
|
22991
22991
|
t2 = t3;
|
|
22992
22992
|
}
|
|
22993
22993
|
return useObservable(t2, INITIAL_STATE$9);
|
|
22994
22994
|
}
|
|
22995
|
-
function _temp2$
|
|
22995
|
+
function _temp2$1n(error) {
|
|
22996
22996
|
return of({
|
|
22997
22997
|
isLoading: !1,
|
|
22998
22998
|
error
|
|
22999
22999
|
});
|
|
23000
23000
|
}
|
|
23001
|
-
function _temp$
|
|
23001
|
+
function _temp$3j(event) {
|
|
23002
23002
|
return {
|
|
23003
23003
|
isLoading: !1,
|
|
23004
23004
|
value: event.snapshot || void 0
|
|
@@ -23305,7 +23305,7 @@ function useImageObjectUrl(url) {
|
|
|
23305
23305
|
let t2, t3;
|
|
23306
23306
|
return $[5] !== cacheKey || $[6] !== token || $[7] !== url ? (t2 = () => {
|
|
23307
23307
|
if (!cacheKey) {
|
|
23308
|
-
setState(_temp$
|
|
23308
|
+
setState(_temp$3i);
|
|
23309
23309
|
return;
|
|
23310
23310
|
}
|
|
23311
23311
|
let entry_0 = requestCache.get(cacheKey);
|
|
@@ -23318,7 +23318,7 @@ function useImageObjectUrl(url) {
|
|
|
23318
23318
|
};
|
|
23319
23319
|
}, t3 = [cacheKey, token, url], $[5] = cacheKey, $[6] = token, $[7] = url, $[8] = t2, $[9] = t3) : (t2 = $[8], t3 = $[9]), useEffect(t2, t3), state;
|
|
23320
23320
|
}
|
|
23321
|
-
function _temp$
|
|
23321
|
+
function _temp$3i(prev) {
|
|
23322
23322
|
return prev.objectUrl || prev.isLoading || prev.error ? IDLE_RESULT : prev;
|
|
23323
23323
|
}
|
|
23324
23324
|
const noop$3 = () => {
|
|
@@ -24246,7 +24246,7 @@ function FormInputInner(props2) {
|
|
|
24246
24246
|
if ($[58] !== absolutePath || $[59] !== props2.members || $[60] !== props2.path || $[61] !== t) {
|
|
24247
24247
|
t6 = /* @__PURE__ */ Symbol.for("react.early_return_sentinel");
|
|
24248
24248
|
bb1: {
|
|
24249
|
-
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$
|
|
24249
|
+
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]);
|
|
24250
24250
|
if (member_3 = fieldMember || fieldSetMember, !member_3) {
|
|
24251
24251
|
const fieldName = typeof childPath_0[0] == "string" ? childPath_0[0] : JSON.stringify(childPath_0[0]);
|
|
24252
24252
|
t6 = /* @__PURE__ */ jsx("div", { children: t("form.error.field-not-found", {
|
|
@@ -24265,10 +24265,10 @@ function FormInputInner(props2) {
|
|
|
24265
24265
|
}
|
|
24266
24266
|
throw new Error("FormInput can only be used with arrays or objects");
|
|
24267
24267
|
}
|
|
24268
|
-
function _temp2$
|
|
24268
|
+
function _temp2$1m(member_2) {
|
|
24269
24269
|
return member_2.kind === "fieldSet" && member_2.fieldSet?.members || [];
|
|
24270
24270
|
}
|
|
24271
|
-
function _temp$
|
|
24271
|
+
function _temp$3h(member_1) {
|
|
24272
24272
|
return member_1.kind === "fieldSet";
|
|
24273
24273
|
}
|
|
24274
24274
|
function NullRender() {
|
|
@@ -24825,13 +24825,13 @@ function EnhancedObjectDialog(props2) {
|
|
|
24825
24825
|
return isKeySegment(segment) && isKeySegment(relativeSegment) ? segment._key === relativeSegment._key : segment === relativeSegment;
|
|
24826
24826
|
}))
|
|
24827
24827
|
return !1;
|
|
24828
|
-
if (fullscreenPath.some(_temp$
|
|
24828
|
+
if (fullscreenPath.some(_temp$3g))
|
|
24829
24829
|
return !0;
|
|
24830
24830
|
const nextSegment = treeState.relativePath[fullscreenPath.length];
|
|
24831
24831
|
return !isKeySegment(nextSegment);
|
|
24832
24832
|
});
|
|
24833
24833
|
if (ancestorPaths.length > 0) {
|
|
24834
|
-
const closestParentPath = ancestorPaths.reduce(_temp2$
|
|
24834
|
+
const closestParentPath = ancestorPaths.reduce(_temp2$1l);
|
|
24835
24835
|
onPathOpen(stringToPath(closestParentPath));
|
|
24836
24836
|
return;
|
|
24837
24837
|
}
|
|
@@ -24884,10 +24884,10 @@ function EnhancedObjectDialog(props2) {
|
|
|
24884
24884
|
let t10;
|
|
24885
24885
|
return $[40] !== documentScrollElement || $[41] !== t9 ? (t10 = /* @__PURE__ */ jsx(VirtualizerScrollInstanceProvider, { scrollElement: documentScrollElement, containerElement, children: t9 }), $[40] = documentScrollElement, $[41] = t9, $[42] = t10) : t10 = $[42], t10;
|
|
24886
24886
|
}
|
|
24887
|
-
function _temp2$
|
|
24887
|
+
function _temp2$1l(longest, current) {
|
|
24888
24888
|
return current.length > longest.length ? current : longest;
|
|
24889
24889
|
}
|
|
24890
|
-
function _temp$
|
|
24890
|
+
function _temp$3g(segment_0) {
|
|
24891
24891
|
return isKeySegment(segment_0);
|
|
24892
24892
|
}
|
|
24893
24893
|
const FlexWrapper$1 = styled(Flex)`
|
|
@@ -24927,14 +24927,14 @@ function PresenceTooltip(props2) {
|
|
|
24927
24927
|
items
|
|
24928
24928
|
} = props2;
|
|
24929
24929
|
let t0;
|
|
24930
|
-
$[0] !== items ? (t0 = items.map(_temp$
|
|
24930
|
+
$[0] !== items ? (t0 = items.map(_temp$3f), $[0] = items, $[1] = t0) : t0 = $[1];
|
|
24931
24931
|
let t1;
|
|
24932
24932
|
$[2] !== t0 ? (t1 = /* @__PURE__ */ jsx(Stack, { sizing: "border", children: t0 }), $[2] = t0, $[3] = t1) : t1 = $[3];
|
|
24933
24933
|
const content = t1;
|
|
24934
24934
|
let t2;
|
|
24935
24935
|
return $[4] !== children || $[5] !== content ? (t2 = /* @__PURE__ */ jsx(Tooltip, { content, placement: "top", portal: "documentScrollElement", children }), $[4] = children, $[5] = content, $[6] = t2) : t2 = $[6], t2;
|
|
24936
24936
|
}
|
|
24937
|
-
function _temp$
|
|
24937
|
+
function _temp$3f(item) {
|
|
24938
24938
|
return /* @__PURE__ */ jsxs(Flex, { align: "center", gap: 2, children: [
|
|
24939
24939
|
/* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(UserAvatar, { user: item.user, status: "online" }) }),
|
|
24940
24940
|
/* @__PURE__ */ jsx(Text$1, { size: 1, children: item.user.displayName })
|
|
@@ -24950,7 +24950,7 @@ const FieldPresenceInner = memo(function(t0) {
|
|
|
24950
24950
|
} = 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;
|
|
24951
24951
|
let t5;
|
|
24952
24952
|
if ($[0] !== animateArrowFrom || $[1] !== maxAvatars || $[2] !== position || $[3] !== presence || $[4] !== stack) {
|
|
24953
|
-
const uniquePresence = uniqBy(presence || [], _temp$
|
|
24953
|
+
const uniquePresence = uniqBy(presence || [], _temp$3e), sorted = sortBy(uniquePresence, _temp2$1k), [hidden, visible] = stack ? splitRight(sorted, maxAvatars) : [[], sorted];
|
|
24954
24954
|
let t62;
|
|
24955
24955
|
$[6] !== animateArrowFrom || $[7] !== position ? (t62 = (_visible) => ({
|
|
24956
24956
|
key: _visible.user.id,
|
|
@@ -24967,7 +24967,7 @@ const FieldPresenceInner = memo(function(t0) {
|
|
|
24967
24967
|
let t7;
|
|
24968
24968
|
return $[10] !== avatars ? (t7 = /* @__PURE__ */ jsxs(FlexWrapper$1, { children: [
|
|
24969
24969
|
t6,
|
|
24970
|
-
/* @__PURE__ */ jsx(InnerBox, { direction: "row-reverse", children: avatars.map(_temp3$
|
|
24970
|
+
/* @__PURE__ */ jsx(InnerBox, { direction: "row-reverse", children: avatars.map(_temp3$B) })
|
|
24971
24971
|
] }), $[10] = avatars, $[11] = t7) : t7 = $[11], t7;
|
|
24972
24972
|
});
|
|
24973
24973
|
function FieldPresence(props2) {
|
|
@@ -24998,13 +24998,13 @@ function _temp4$g(item) {
|
|
|
24998
24998
|
return item.user.id;
|
|
24999
24999
|
}
|
|
25000
25000
|
const FieldPresenceWithOverlay = FieldPresence;
|
|
25001
|
-
function _temp$
|
|
25001
|
+
function _temp$3e(item) {
|
|
25002
25002
|
return item.user.id;
|
|
25003
25003
|
}
|
|
25004
|
-
function _temp2$
|
|
25004
|
+
function _temp2$1k(_presence) {
|
|
25005
25005
|
return _presence.lastActiveAt;
|
|
25006
25006
|
}
|
|
25007
|
-
function _temp3$
|
|
25007
|
+
function _temp3$B(av, i) {
|
|
25008
25008
|
return av && /* @__PURE__ */ jsx("div", { style: {
|
|
25009
25009
|
position: "absolute",
|
|
25010
25010
|
transform: `translate3d(${-i * (AVATAR_SIZE + AVATAR_DISTANCE)}px, 0px, 0px)`,
|
|
@@ -25134,7 +25134,7 @@ const createIntersectionObserver = (options) => {
|
|
|
25134
25134
|
}, t8 = [], $[11] = t7, $[12] = t8) : (t7 = $[11], t8 = $[12]), useLayoutEffect(t7, t8);
|
|
25135
25135
|
const top = intersections["::top"], bottom2 = intersections["::bottom"];
|
|
25136
25136
|
let t9;
|
|
25137
|
-
$[13] !== bottom2 || $[14] !== intersections || $[15] !== regions || $[16] !== top ? (t9 = top && bottom2 ? regions.filter(_temp$
|
|
25137
|
+
$[13] !== bottom2 || $[14] !== intersections || $[15] !== regions || $[16] !== top ? (t9 = top && bottom2 ? regions.filter(_temp$3d).map((region_0) => {
|
|
25138
25138
|
const intersection2 = intersections[region_0.id];
|
|
25139
25139
|
if (!intersection2)
|
|
25140
25140
|
return null;
|
|
@@ -25183,7 +25183,7 @@ const createIntersectionObserver = (options) => {
|
|
|
25183
25183
|
t15
|
|
25184
25184
|
] }), $[36] = ref, $[37] = t10, $[38] = t11, $[39] = t13, $[40] = t14, $[41] = t15, $[42] = t16) : t16 = $[42], t16;
|
|
25185
25185
|
});
|
|
25186
|
-
function _temp$
|
|
25186
|
+
function _temp$3d(region) {
|
|
25187
25187
|
return region.presence?.length > 0;
|
|
25188
25188
|
}
|
|
25189
25189
|
const ITEM_TRANSITION = {
|
|
@@ -25269,7 +25269,7 @@ function StickyOverlay(props2) {
|
|
|
25269
25269
|
const regions = t1;
|
|
25270
25270
|
let t2;
|
|
25271
25271
|
$[3] !== margins ? (t2 = (regionsWithIntersectionDetails, containerWidth) => {
|
|
25272
|
-
const grouped = group(regionsWithIntersectionDetails.filter(_temp$
|
|
25272
|
+
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, {
|
|
25273
25273
|
nearTop: 0,
|
|
25274
25274
|
nearBottom: 0
|
|
25275
25275
|
});
|
|
@@ -25295,13 +25295,13 @@ function _temp4$f(_counts, withIntersection) {
|
|
|
25295
25295
|
nearBottom: _counts.nearBottom + (nearBottom ? withIntersection.region.presence.length : 0)
|
|
25296
25296
|
};
|
|
25297
25297
|
}
|
|
25298
|
-
function _temp3$
|
|
25298
|
+
function _temp3$A(n_0) {
|
|
25299
25299
|
return n_0.region.rect.height + n_0.spacerHeight;
|
|
25300
25300
|
}
|
|
25301
|
-
function _temp2$
|
|
25301
|
+
function _temp2$1j(n) {
|
|
25302
25302
|
return n.region.rect.height + n.spacerHeight;
|
|
25303
25303
|
}
|
|
25304
|
-
function _temp$
|
|
25304
|
+
function _temp$3c(item) {
|
|
25305
25305
|
return item.region.presence.length > 0;
|
|
25306
25306
|
}
|
|
25307
25307
|
const EMPTY_ARRAY$o = [], PresenceDock = memo(function(props2) {
|
|
@@ -25792,7 +25792,7 @@ function TreeEditingMenuItem(props2) {
|
|
|
25792
25792
|
$[13] !== item.path || $[14] !== onPathSelect ? (t6 = () => onPathSelect(item.path), $[13] = item.path, $[14] = onPathSelect, $[15] = t6) : t6 = $[15];
|
|
25793
25793
|
const handleClick = t6;
|
|
25794
25794
|
let t7;
|
|
25795
|
-
$[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = () => setOpen(_temp$
|
|
25795
|
+
$[16] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t7 = () => setOpen(_temp$3b), $[16] = t7) : t7 = $[16];
|
|
25796
25796
|
const handleExpandClick = t7;
|
|
25797
25797
|
let t8, t9;
|
|
25798
25798
|
$[17] !== item || $[18] !== selectedPath ? (t8 = () => {
|
|
@@ -25828,7 +25828,7 @@ function TreeEditingMenuItem(props2) {
|
|
|
25828
25828
|
t18
|
|
25829
25829
|
] }, stringPath), $[53] = open, $[54] = stringPath, $[55] = t17, $[56] = t18, $[57] = t19) : t19 = $[57], t19;
|
|
25830
25830
|
}
|
|
25831
|
-
function _temp$
|
|
25831
|
+
function _temp$3b(v) {
|
|
25832
25832
|
return !v;
|
|
25833
25833
|
}
|
|
25834
25834
|
const TreeEditingMenu = memo(function(props2) {
|
|
@@ -25919,7 +25919,7 @@ memo(function(props2) {
|
|
|
25919
25919
|
siblings
|
|
25920
25920
|
} = props2, [scrollElement, setScrollElement] = useState(null), containerElementRef = useRef(null), [open, setOpen] = useState(!1);
|
|
25921
25921
|
let t0;
|
|
25922
|
-
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setOpen(_temp$
|
|
25922
|
+
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => setOpen(_temp$3a), $[0] = t0) : t0 = $[0];
|
|
25923
25923
|
const toggleOpen = t0;
|
|
25924
25924
|
let t1;
|
|
25925
25925
|
$[1] !== setParentScrollElement ? (t1 = (el) => {
|
|
@@ -25946,7 +25946,7 @@ memo(function(props2) {
|
|
|
25946
25946
|
t6
|
|
25947
25947
|
] }), $[24] = t2, $[25] = t6, $[26] = t7) : t7 = $[26], t7;
|
|
25948
25948
|
});
|
|
25949
|
-
function _temp$
|
|
25949
|
+
function _temp$3a(v) {
|
|
25950
25950
|
return !v;
|
|
25951
25951
|
}
|
|
25952
25952
|
function SourceProvider(t0) {
|
|
@@ -26201,7 +26201,7 @@ function GridItem(props2) {
|
|
|
26201
26201
|
const presence = t7, childValidation = useChildValidation(path, !0);
|
|
26202
26202
|
let t8;
|
|
26203
26203
|
$[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];
|
|
26204
|
-
const validation2 = t8, hasErrors = childValidation.some(_temp$
|
|
26204
|
+
const validation2 = t8, hasErrors = childValidation.some(_temp$39), hasWarnings = childValidation.some(_temp2$1i), [contextMenuButtonElement, setContextMenuButtonElement] = useState(null), t9 = parentSchemaType.options?.insertMenu;
|
|
26205
26205
|
let t10;
|
|
26206
26206
|
$[16] !== contextMenuButtonElement || $[17] !== handleInsert || $[18] !== insertableTypes || $[19] !== t9 ? (t10 = {
|
|
26207
26207
|
schemaTypes: insertableTypes,
|
|
@@ -26278,10 +26278,10 @@ function GridItem(props2) {
|
|
|
26278
26278
|
t22 = $[87];
|
|
26279
26279
|
return t22;
|
|
26280
26280
|
}
|
|
26281
|
-
function _temp2$
|
|
26281
|
+
function _temp2$1i(v_0) {
|
|
26282
26282
|
return v_0.level === "warning";
|
|
26283
26283
|
}
|
|
26284
|
-
function _temp$
|
|
26284
|
+
function _temp$39(v) {
|
|
26285
26285
|
return v.level === "error";
|
|
26286
26286
|
}
|
|
26287
26287
|
const EMPTY$4 = [];
|
|
@@ -26307,9 +26307,9 @@ function GridArrayInput(props2) {
|
|
|
26307
26307
|
value: t1
|
|
26308
26308
|
} = props2, ArrayFunctions = t0 === void 0 ? ArrayOfObjectsFunctions : t0, value = t1 === void 0 ? EMPTY$4 : t1, {
|
|
26309
26309
|
t
|
|
26310
|
-
} = useTranslation(), sortable = schemaType.options?.sortable !== !1, renderItem2 = _temp$
|
|
26310
|
+
} = useTranslation(), sortable = schemaType.options?.sortable !== !1, renderItem2 = _temp$38;
|
|
26311
26311
|
let t2;
|
|
26312
|
-
$[0] !== members ? (t2 = members.map(_temp2$
|
|
26312
|
+
$[0] !== members ? (t2 = members.map(_temp2$1h), $[0] = members, $[1] = t2) : t2 = $[1];
|
|
26313
26313
|
const memberKeys = t2;
|
|
26314
26314
|
let t3;
|
|
26315
26315
|
$[2] !== members.length || $[3] !== schemaType.placeholder || $[4] !== t ? (t3 = members?.length === 0 && /* @__PURE__ */ jsx(Card, { padding: 3, border: !0, radius: 2, children: /* @__PURE__ */ jsx(Text$1, { align: "center", muted: !0, size: 1, children: schemaType.placeholder || /* @__PURE__ */ jsx(Fragment$1, { children: t("inputs.array.no-items-label") }) }) }), $[2] = members.length, $[3] = schemaType.placeholder, $[4] = t, $[5] = t3) : t3 = $[5];
|
|
@@ -26333,10 +26333,10 @@ function GridArrayInput(props2) {
|
|
|
26333
26333
|
t7
|
|
26334
26334
|
] }), $[37] = t6, $[38] = t7, $[39] = t8) : t8 = $[39], t8;
|
|
26335
26335
|
}
|
|
26336
|
-
function _temp2$
|
|
26336
|
+
function _temp2$1h(member) {
|
|
26337
26337
|
return member.key;
|
|
26338
26338
|
}
|
|
26339
|
-
function _temp$
|
|
26339
|
+
function _temp$38(itemProps) {
|
|
26340
26340
|
return /* @__PURE__ */ jsx(GridItem, { ...itemProps });
|
|
26341
26341
|
}
|
|
26342
26342
|
function useMemoCompare(next, compare2) {
|
|
@@ -26358,7 +26358,7 @@ function useVisibilityDetection(parentRef) {
|
|
|
26358
26358
|
if (wasVisible === isNowVisible)
|
|
26359
26359
|
return;
|
|
26360
26360
|
const becameVisible = !wasVisible && isNowVisible;
|
|
26361
|
-
prevVisible.current = isNowVisible, setIsVisible(isNowVisible), becameVisible && setMountKey(_temp$
|
|
26361
|
+
prevVisible.current = isNowVisible, setIsVisible(isNowVisible), becameVisible && setMountKey(_temp$37);
|
|
26362
26362
|
});
|
|
26363
26363
|
return parentRef.current && resizeObserver2.observe(parentRef.current), () => resizeObserver2.disconnect();
|
|
26364
26364
|
}, t1 = [parentRef], $[0] = parentRef, $[1] = t0, $[2] = t1) : (t0 = $[1], t1 = $[2]), useEffect(t0, t1);
|
|
@@ -26368,7 +26368,7 @@ function useVisibilityDetection(parentRef) {
|
|
|
26368
26368
|
mountKey
|
|
26369
26369
|
}, $[3] = isVisible2, $[4] = mountKey, $[5] = t2) : t2 = $[5], t2;
|
|
26370
26370
|
}
|
|
26371
|
-
function _temp$
|
|
26371
|
+
function _temp$37(prev) {
|
|
26372
26372
|
return prev + 1;
|
|
26373
26373
|
}
|
|
26374
26374
|
const Root$p = styled(Card)`
|
|
@@ -26466,7 +26466,7 @@ function IncompatibleItemType(props2) {
|
|
|
26466
26466
|
const handleKeyDown = t2;
|
|
26467
26467
|
let t3;
|
|
26468
26468
|
$[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = () => {
|
|
26469
|
-
setShowDetails(_temp$
|
|
26469
|
+
setShowDetails(_temp$36);
|
|
26470
26470
|
}, $[7] = t3) : t3 = $[7];
|
|
26471
26471
|
const handleShowDetails = t3;
|
|
26472
26472
|
let t4;
|
|
@@ -26528,7 +26528,7 @@ function IncompatibleItemType(props2) {
|
|
|
26528
26528
|
let t22;
|
|
26529
26529
|
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;
|
|
26530
26530
|
}
|
|
26531
|
-
function _temp$
|
|
26531
|
+
function _temp$36(v) {
|
|
26532
26532
|
return !v;
|
|
26533
26533
|
}
|
|
26534
26534
|
const MENU_POPOVER_PROPS$6 = {
|
|
@@ -26675,7 +26675,7 @@ function ListArrayInput(props2) {
|
|
|
26675
26675
|
t
|
|
26676
26676
|
} = useTranslation(), [activeDragItemIndex, setActiveDragItemIndex] = useState(null);
|
|
26677
26677
|
let t2;
|
|
26678
|
-
$[0] !== members ? (t2 = members.map(_temp$
|
|
26678
|
+
$[0] !== members ? (t2 = members.map(_temp$35), $[0] = members, $[1] = t2) : t2 = $[1];
|
|
26679
26679
|
const memberKeys = useMemoCompare(t2, shallowEquals), parentRef = useRef(null), {
|
|
26680
26680
|
isVisible: isVisible2,
|
|
26681
26681
|
mountKey
|
|
@@ -26721,7 +26721,7 @@ function ListArrayInput(props2) {
|
|
|
26721
26721
|
t9
|
|
26722
26722
|
] }), $[42] = t8, $[43] = t9, $[44] = t10) : t10 = $[44], t10;
|
|
26723
26723
|
}
|
|
26724
|
-
function _temp$
|
|
26724
|
+
function _temp$35(member) {
|
|
26725
26725
|
return member.key;
|
|
26726
26726
|
}
|
|
26727
26727
|
function ArrayOfObjectsInput(props2) {
|
|
@@ -26766,7 +26766,7 @@ function ArrayOfObjectOptionsInput(props2) {
|
|
|
26766
26766
|
$[0] !== t0 ? (t1 = t0 === void 0 ? [] : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
|
|
26767
26767
|
const value = t1, t2 = schemaType.options?.list || EMPTY_ARRAY$m;
|
|
26768
26768
|
let t3;
|
|
26769
|
-
$[2] !== t2 ? (t3 = t2.map(_temp$
|
|
26769
|
+
$[2] !== t2 ? (t3 = t2.map(_temp$34), $[2] = t2, $[3] = t3) : t3 = $[3];
|
|
26770
26770
|
const options = t3;
|
|
26771
26771
|
let t4;
|
|
26772
26772
|
$[4] !== onChange || $[5] !== options || $[6] !== value ? (t4 = (isChecked, changedOption) => {
|
|
@@ -26806,7 +26806,7 @@ function ArrayOfObjectOptionsInput(props2) {
|
|
|
26806
26806
|
let t9;
|
|
26807
26807
|
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;
|
|
26808
26808
|
}
|
|
26809
|
-
function _temp$
|
|
26809
|
+
function _temp$34(option, index) {
|
|
26810
26810
|
return isKeyedObject(option) ? option : {
|
|
26811
26811
|
...option,
|
|
26812
26812
|
_key: `auto-generated-${index}`
|
|
@@ -26848,7 +26848,7 @@ function ArrayOfPrimitiveOptionsInput(props2) {
|
|
|
26848
26848
|
const options = t3;
|
|
26849
26849
|
let t4;
|
|
26850
26850
|
$[6] !== onChange || $[7] !== options || $[8] !== value ? (t4 = (isChecked, changedValue) => {
|
|
26851
|
-
const nextValue = options.map(_temp$
|
|
26851
|
+
const nextValue = options.map(_temp$33).filter((optionValue) => optionValue === changedValue ? isChecked : value.includes(optionValue));
|
|
26852
26852
|
onChange(nextValue.length > 0 ? set(nextValue) : unset());
|
|
26853
26853
|
}, $[6] = onChange, $[7] = options, $[8] = value, $[9] = t4) : t4 = $[9];
|
|
26854
26854
|
const handleChange = t4, t5 = schemaType.options?.layout === "grid" ? Math.min(options.length, 4) : 1;
|
|
@@ -26870,7 +26870,7 @@ function ArrayOfPrimitiveOptionsInput(props2) {
|
|
|
26870
26870
|
let t8;
|
|
26871
26871
|
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;
|
|
26872
26872
|
}
|
|
26873
|
-
function _temp$
|
|
26873
|
+
function _temp$33(option) {
|
|
26874
26874
|
return option.value;
|
|
26875
26875
|
}
|
|
26876
26876
|
function ArrayOfOptionsInput(props2) {
|
|
@@ -26977,14 +26977,14 @@ function uploadTarget(Component2) {
|
|
|
26977
26977
|
const tasks2 = files.map((file_0) => ({
|
|
26978
26978
|
file: file_0,
|
|
26979
26979
|
uploaderCandidates: getUploadCandidates(types, resolveUploader2, file_0)
|
|
26980
|
-
})), ready = tasks2.filter(_temp$
|
|
26980
|
+
})), ready = tasks2.filter(_temp$32), rejected = tasks2.filter(_temp2$1g);
|
|
26981
26981
|
rejected.length > 0 && pushToast({
|
|
26982
26982
|
closable: !0,
|
|
26983
26983
|
status: "warning",
|
|
26984
26984
|
title: t("inputs.array.error.cannot-upload-unable-to-convert", {
|
|
26985
26985
|
count: rejected.length
|
|
26986
26986
|
}),
|
|
26987
|
-
description: rejected.map(_temp3$
|
|
26987
|
+
description: rejected.map(_temp3$z)
|
|
26988
26988
|
}), ready.forEach((task_2) => {
|
|
26989
26989
|
uploadFile2(task_2.file, sortBy(task_2.uploaderCandidates, _temp4$e)[0]);
|
|
26990
26990
|
});
|
|
@@ -27053,13 +27053,13 @@ function DropMessage(props2) {
|
|
|
27053
27053
|
let t2;
|
|
27054
27054
|
return $[3] !== t1 ? (t2 = /* @__PURE__ */ jsx(Fragment$1, { children: t1 }), $[3] = t1, $[4] = t2) : t2 = $[4], t2;
|
|
27055
27055
|
}
|
|
27056
|
-
function _temp$
|
|
27056
|
+
function _temp$32(task) {
|
|
27057
27057
|
return task.uploaderCandidates.length > 0;
|
|
27058
27058
|
}
|
|
27059
|
-
function _temp2$
|
|
27059
|
+
function _temp2$1g(task_0) {
|
|
27060
27060
|
return task_0.uploaderCandidates.length === 0;
|
|
27061
27061
|
}
|
|
27062
|
-
function _temp3$
|
|
27062
|
+
function _temp3$z(task_1, i) {
|
|
27063
27063
|
return /* @__PURE__ */ jsxs(Flex, { gap: 2, padding: 2, children: [
|
|
27064
27064
|
/* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$1, { weight: "medium", children: task_1.file.name }) }),
|
|
27065
27065
|
/* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$1, { size: 1, children: [
|
|
@@ -27136,7 +27136,7 @@ const MENU_BUTTON_POPOVER_PROPS$2 = {
|
|
|
27136
27136
|
children,
|
|
27137
27137
|
presence,
|
|
27138
27138
|
schemaType
|
|
27139
|
-
} = props2, hasError = validation2.filter(_temp$
|
|
27139
|
+
} = props2, hasError = validation2.filter(_temp$31).length > 0, hasWarning = validation2.filter(_temp2$1f).length > 0;
|
|
27140
27140
|
let t0;
|
|
27141
27141
|
$[0] !== onInsert ? (t0 = (pos, insertType) => {
|
|
27142
27142
|
onInsert({
|
|
@@ -27203,10 +27203,10 @@ const MENU_BUTTON_POPOVER_PROPS$2 = {
|
|
|
27203
27203
|
let t17;
|
|
27204
27204
|
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;
|
|
27205
27205
|
});
|
|
27206
|
-
function _temp$
|
|
27206
|
+
function _temp$31(item) {
|
|
27207
27207
|
return item.level === "error";
|
|
27208
27208
|
}
|
|
27209
|
-
function _temp2$
|
|
27209
|
+
function _temp2$1f(item_0) {
|
|
27210
27210
|
return item_0.level === "warning";
|
|
27211
27211
|
}
|
|
27212
27212
|
function NoItemsPlaceholder(t0) {
|
|
@@ -27572,7 +27572,7 @@ const TIME_ZONE_SCOPE_TYPE = {
|
|
|
27572
27572
|
let t6;
|
|
27573
27573
|
$[22] !== allTimeZones ? (t6 = () => {
|
|
27574
27574
|
const localTzName = Intl.DateTimeFormat().resolvedOptions().timeZone, foundLocal = allTimeZones.find((tz_3) => tz_3.name === localTzName);
|
|
27575
|
-
return foundLocal || allTimeZones.find(_temp$
|
|
27575
|
+
return foundLocal || allTimeZones.find(_temp$30) || allTimeZones[0];
|
|
27576
27576
|
}, $[22] = allTimeZones, $[23] = t6) : t6 = $[23];
|
|
27577
27577
|
const getLocalTimeZone = t6;
|
|
27578
27578
|
let t7;
|
|
@@ -27670,7 +27670,7 @@ function getErrorMessage$1(err) {
|
|
|
27670
27670
|
let message;
|
|
27671
27671
|
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;
|
|
27672
27672
|
}
|
|
27673
|
-
function _temp$
|
|
27673
|
+
function _temp$30(timeZone) {
|
|
27674
27674
|
return timeZone.abbreviation === "GMT";
|
|
27675
27675
|
}
|
|
27676
27676
|
const TimeZoneCitySpan = styled.span(({
|
|
@@ -27728,7 +27728,7 @@ const TimeZoneCitySpan = styled.span(({
|
|
|
27728
27728
|
const handleTimeZoneUpdate = t6, isDirty = selectedTz?.name !== timeZone.name;
|
|
27729
27729
|
let t7;
|
|
27730
27730
|
$[18] !== getLocalTimeZone ? (t7 = getLocalTimeZone(), $[18] = getLocalTimeZone, $[19] = t7) : t7 = $[19];
|
|
27731
|
-
const isLocalTzSelected = selectedTz?.name === t7.name, renderOption = _temp$
|
|
27731
|
+
const isLocalTzSelected = selectedTz?.name === t7.name, renderOption = _temp$2$, renderValue = _temp2$1e, t8 = !isDirty || !selectedTz;
|
|
27732
27732
|
let t9;
|
|
27733
27733
|
$[20] !== handleTimeZoneUpdate || $[21] !== t8 ? (t9 = {
|
|
27734
27734
|
confirmButton: {
|
|
@@ -27773,7 +27773,7 @@ const TimeZoneCitySpan = styled.span(({
|
|
|
27773
27773
|
}, $[46] = t19, $[47] = t20) : t20 = $[47];
|
|
27774
27774
|
const t21 = selectedTz?.value;
|
|
27775
27775
|
let t22;
|
|
27776
|
-
$[48] !== allTimeZones || $[49] !== handleTimeZoneChange || $[50] !== t18 || $[51] !== t20 || $[52] !== t21 ? (t22 = /* @__PURE__ */ jsx(Autocomplete, { fontSize: 2, icon: SearchIcon, id: "timezone", onChange: handleTimeZoneChange, openButton: !0, options: allTimeZones, padding: 4, filterOption: _temp3$
|
|
27776
|
+
$[48] !== allTimeZones || $[49] !== handleTimeZoneChange || $[50] !== t18 || $[51] !== t20 || $[52] !== t21 ? (t22 = /* @__PURE__ */ jsx(Autocomplete, { fontSize: 2, icon: SearchIcon, id: "timezone", onChange: handleTimeZoneChange, openButton: !0, options: allTimeZones, padding: 4, filterOption: _temp3$y, placeholder: t18, popover: t20, renderOption, renderValue, tabIndex: -1, value: t21 }), $[48] = allTimeZones, $[49] = handleTimeZoneChange, $[50] = t18, $[51] = t20, $[52] = t21, $[53] = t22) : t22 = $[53];
|
|
27777
27777
|
let t23;
|
|
27778
27778
|
$[54] !== t17 || $[55] !== t22 ? (t23 = /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
|
|
27779
27779
|
t17,
|
|
@@ -27787,7 +27787,7 @@ const TimeZoneCitySpan = styled.span(({
|
|
|
27787
27787
|
let t25;
|
|
27788
27788
|
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;
|
|
27789
27789
|
};
|
|
27790
|
-
function _temp$
|
|
27790
|
+
function _temp$2$(option) {
|
|
27791
27791
|
return /* @__PURE__ */ jsx(Card, { as: "button", padding: 3, children: /* @__PURE__ */ jsxs(Text$1, { size: 1, textOverflow: "ellipsis", children: [
|
|
27792
27792
|
/* @__PURE__ */ jsx(TimeZoneCitySpan, { children: option.city }),
|
|
27793
27793
|
/* @__PURE__ */ jsxs(TimeZoneOffsetSpan, { children: [
|
|
@@ -27800,10 +27800,10 @@ function _temp$2_(option) {
|
|
|
27800
27800
|
/* @__PURE__ */ jsx(TimeZoneAlternativeNameSpan, { children: option.alternativeName })
|
|
27801
27801
|
] }) });
|
|
27802
27802
|
}
|
|
27803
|
-
function _temp2$
|
|
27803
|
+
function _temp2$1e(_value, option_0) {
|
|
27804
27804
|
return option_0 ? `${option_0.alternativeName} (${option_0.namePretty})` : "";
|
|
27805
27805
|
}
|
|
27806
|
-
function _temp3$
|
|
27806
|
+
function _temp3$y(query, option_1) {
|
|
27807
27807
|
return query === "" ? !0 : `${option_1.city} (GMT
|
|
27808
27808
|
${option_1.offset}) ${option_1.alternativeName}`?.toLowerCase()?.includes(query?.toLowerCase());
|
|
27809
27809
|
}
|
|
@@ -27891,9 +27891,9 @@ const DEFAULT_MONTH_NAMES = ["January", "February", "March", "April", "May", "Ju
|
|
|
27891
27891
|
weekInfo
|
|
27892
27892
|
} = useCurrentLocale();
|
|
27893
27893
|
let t0;
|
|
27894
|
-
return $[0] !== date || $[1] !== weekInfo.firstDay ? (t0 = getWeekDaysFromWeekStarts$2(getWeekStartsOfMonth$2(date, weekInfo.firstDay)).map(_temp$
|
|
27894
|
+
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;
|
|
27895
27895
|
};
|
|
27896
|
-
function _temp$
|
|
27896
|
+
function _temp$2_(days) {
|
|
27897
27897
|
return {
|
|
27898
27898
|
number: getWeek(days[0]),
|
|
27899
27899
|
days
|
|
@@ -27919,7 +27919,7 @@ function CalendarMonth$3(props2) {
|
|
|
27919
27919
|
gridTemplateColumns: "repeat(7, minmax(44px, 46px))"
|
|
27920
27920
|
}, $[4] = t2) : t2 = $[4];
|
|
27921
27921
|
let t3;
|
|
27922
|
-
$[5] !== weekDayNames ? (t3 = weekDayNames.map(_temp$
|
|
27922
|
+
$[5] !== weekDayNames ? (t3 = weekDayNames.map(_temp$2Z), $[5] = weekDayNames, $[6] = t3) : t3 = $[6];
|
|
27923
27923
|
const t4 = useWeeksOfMonth$1(props2.date);
|
|
27924
27924
|
let t5;
|
|
27925
27925
|
if ($[7] !== props2.focused || $[8] !== props2.isPastDisabled || $[9] !== props2.onSelect || $[10] !== props2.selected || $[11] !== t4) {
|
|
@@ -27938,7 +27938,7 @@ function CalendarMonth$3(props2) {
|
|
|
27938
27938
|
let t7;
|
|
27939
27939
|
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;
|
|
27940
27940
|
}
|
|
27941
|
-
function _temp$
|
|
27941
|
+
function _temp$2Z(weekday) {
|
|
27942
27942
|
return /* @__PURE__ */ jsx(Box, { paddingY: 2, children: /* @__PURE__ */ jsx(Text$1, { size: 1, weight: "medium", style: {
|
|
27943
27943
|
textAlign: "center"
|
|
27944
27944
|
}, children: weekday }) }, weekday);
|
|
@@ -28254,11 +28254,11 @@ function CalendarMonthSelect$1(props2) {
|
|
|
28254
28254
|
monthNames
|
|
28255
28255
|
} = props2;
|
|
28256
28256
|
let t0;
|
|
28257
|
-
$[0] !== monthNames ? (t0 = monthNames.map(_temp$
|
|
28257
|
+
$[0] !== monthNames ? (t0 = monthNames.map(_temp$2Y), $[0] = monthNames, $[1] = t0) : t0 = $[1];
|
|
28258
28258
|
let t1;
|
|
28259
28259
|
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;
|
|
28260
28260
|
}
|
|
28261
|
-
function _temp$
|
|
28261
|
+
function _temp$2Y(monthName, i) {
|
|
28262
28262
|
return /* @__PURE__ */ jsx("option", { value: i, children: monthName }, i);
|
|
28263
28263
|
}
|
|
28264
28264
|
function CalendarYearSelect$1(props2) {
|
|
@@ -28840,7 +28840,7 @@ const GroupTab = forwardRef(function(props2, ref) {
|
|
|
28840
28840
|
} = useTranslation();
|
|
28841
28841
|
let t3;
|
|
28842
28842
|
$[2] !== t ? (t3 = t("inputs.object.field-group-tabs.aria-label"), $[2] = t, $[3] = t3) : t3 = $[3];
|
|
28843
|
-
const t4 = groups.find(_temp$
|
|
28843
|
+
const t4 = groups.find(_temp$2X)?.name;
|
|
28844
28844
|
let t5;
|
|
28845
28845
|
if ($[4] !== groups || $[5] !== inputId || $[6] !== t) {
|
|
28846
28846
|
let t62;
|
|
@@ -28874,7 +28874,7 @@ const GroupTab = forwardRef(function(props2, ref) {
|
|
|
28874
28874
|
/* @__PURE__ */ jsx(GroupSelect, { ...props2, disabled, onSelect: handleClick })
|
|
28875
28875
|
] }), $[6] = disabled, $[7] = handleClick, $[8] = props2, $[9] = t3) : t3 = $[9], t3;
|
|
28876
28876
|
});
|
|
28877
|
-
function _temp$
|
|
28877
|
+
function _temp$2X(g) {
|
|
28878
28878
|
return g.selected;
|
|
28879
28879
|
}
|
|
28880
28880
|
const FieldGroupTabsWrapper = styled(Card)`
|
|
@@ -29017,7 +29017,7 @@ const RootStack$2 = styled(Stack)`
|
|
|
29017
29017
|
}
|
|
29018
29018
|
let t42;
|
|
29019
29019
|
if ($[5] !== schemaType.fields || $[6] !== value) {
|
|
29020
|
-
const knownFieldNames = schemaType.fields.map(_temp$
|
|
29020
|
+
const knownFieldNames = schemaType.fields.map(_temp$2W);
|
|
29021
29021
|
t42 = Object.keys(value || {}).filter((key) => !key.startsWith("_") && !knownFieldNames.includes(key)), $[5] = schemaType.fields, $[6] = value, $[7] = t42;
|
|
29022
29022
|
} else
|
|
29023
29023
|
t42 = $[7];
|
|
@@ -29031,7 +29031,7 @@ const RootStack$2 = styled(Stack)`
|
|
|
29031
29031
|
}
|
|
29032
29032
|
const renderedUnknownFields = t3;
|
|
29033
29033
|
let t4;
|
|
29034
|
-
$[12] !== groups ? (t4 = groups.find(_temp2$
|
|
29034
|
+
$[12] !== groups ? (t4 = groups.find(_temp2$1d), $[12] = groups, $[13] = t4) : t4 = $[13];
|
|
29035
29035
|
const selectedGroup = t4;
|
|
29036
29036
|
let t5;
|
|
29037
29037
|
$[14] !== isFocusable || $[15] !== onPathFocus ? (t5 = (event) => {
|
|
@@ -29063,10 +29063,10 @@ const RootStack$2 = styled(Stack)`
|
|
|
29063
29063
|
t12
|
|
29064
29064
|
] }), $[43] = arrayEditingModal, $[44] = t12, $[45] = t13) : t13 = $[45], t13;
|
|
29065
29065
|
});
|
|
29066
|
-
function _temp$
|
|
29066
|
+
function _temp$2W(field) {
|
|
29067
29067
|
return field.name;
|
|
29068
29068
|
}
|
|
29069
|
-
function _temp2$
|
|
29069
|
+
function _temp2$1d(t0) {
|
|
29070
29070
|
const {
|
|
29071
29071
|
selected
|
|
29072
29072
|
} = t0;
|
|
@@ -29142,7 +29142,7 @@ function SlugInput(props2) {
|
|
|
29142
29142
|
focusPath
|
|
29143
29143
|
} = props2, sourceField = schemaType.options?.source;
|
|
29144
29144
|
let t0;
|
|
29145
|
-
$[0] !== validation2 ? (t0 = validation2.filter(_temp$
|
|
29145
|
+
$[0] !== validation2 ? (t0 = validation2.filter(_temp$2V), $[0] = validation2, $[1] = t0) : t0 = $[1];
|
|
29146
29146
|
const errors = t0, inputRef = useRef(null), slugContext = useSlugContext(), {
|
|
29147
29147
|
t
|
|
29148
29148
|
} = useTranslation();
|
|
@@ -29208,7 +29208,7 @@ function SlugInput(props2) {
|
|
|
29208
29208
|
t13
|
|
29209
29209
|
] }) }), $[38] = t12, $[39] = t13, $[40] = t14) : t14 = $[40], t14;
|
|
29210
29210
|
}
|
|
29211
|
-
function _temp$
|
|
29211
|
+
function _temp$2V(item) {
|
|
29212
29212
|
return item.level === "error";
|
|
29213
29213
|
}
|
|
29214
29214
|
function StringInputBasic(props2) {
|
|
@@ -29473,7 +29473,7 @@ const ScrollContainerComponent = forwardRef(function(props2, forwardedRef) {
|
|
|
29473
29473
|
const As = t0 === void 0 ? "div" : t0, ref = useRef(null);
|
|
29474
29474
|
let t1;
|
|
29475
29475
|
$[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = () => ref.current, $[4] = t1) : t1 = $[4], useImperativeHandle(forwardedRef, t1);
|
|
29476
|
-
const parentContext = useContext(ScrollContext), [childContext] = useState(_temp$
|
|
29476
|
+
const parentContext = useContext(ScrollContext), [childContext] = useState(_temp$2U);
|
|
29477
29477
|
let t2, t3;
|
|
29478
29478
|
$[5] !== childContext || $[6] !== onScroll ? (t2 = () => {
|
|
29479
29479
|
if (onScroll)
|
|
@@ -29503,7 +29503,7 @@ const ScrollContainerComponent = forwardRef(function(props2, forwardedRef) {
|
|
|
29503
29503
|
return $[19] !== childContext || $[20] !== t8 ? (t9 = /* @__PURE__ */ jsx(ScrollContext.Provider, { value: childContext, children: t8 }), $[19] = childContext, $[20] = t8, $[21] = t9) : t9 = $[21], t9;
|
|
29504
29504
|
}), ScrollContainer = memo(ScrollContainerComponent);
|
|
29505
29505
|
ScrollContainer.displayName = "Memo(Forwardref(ScrollContainer))";
|
|
29506
|
-
function _temp$
|
|
29506
|
+
function _temp$2U() {
|
|
29507
29507
|
return createPubSub();
|
|
29508
29508
|
}
|
|
29509
29509
|
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 = {
|
|
@@ -29893,7 +29893,7 @@ function BlockActions(props2) {
|
|
|
29893
29893
|
renderBlockActions
|
|
29894
29894
|
} = props2;
|
|
29895
29895
|
let t0;
|
|
29896
|
-
$[0] !== editor2.schemaTypes.decorators ? (t0 = editor2.schemaTypes.decorators.map(_temp$
|
|
29896
|
+
$[0] !== editor2.schemaTypes.decorators ? (t0 = editor2.schemaTypes.decorators.map(_temp$2T), $[0] = editor2.schemaTypes.decorators, $[1] = t0) : t0 = $[1];
|
|
29897
29897
|
const decoratorValues = t0;
|
|
29898
29898
|
let t1;
|
|
29899
29899
|
bb0: {
|
|
@@ -29932,7 +29932,7 @@ function BlockActions(props2) {
|
|
|
29932
29932
|
let t2;
|
|
29933
29933
|
return $[8] !== blockActions ? (t2 = /* @__PURE__ */ jsx(Root$j, { contentEditable: !1, children: blockActions }), $[8] = blockActions, $[9] = t2) : t2 = $[9], t2;
|
|
29934
29934
|
}
|
|
29935
|
-
function _temp$
|
|
29935
|
+
function _temp$2T(d) {
|
|
29936
29936
|
return d.value;
|
|
29937
29937
|
}
|
|
29938
29938
|
function textBlockStyle(props2) {
|
|
@@ -30661,13 +30661,13 @@ const MENU_BUTTON_POPOVER_PROPS$1 = {
|
|
|
30661
30661
|
onMenuClose
|
|
30662
30662
|
} = props2;
|
|
30663
30663
|
let t0;
|
|
30664
|
-
$[0] !== menuOptions ? (t0 = menuOptions.map(_temp$
|
|
30664
|
+
$[0] !== menuOptions ? (t0 = menuOptions.map(_temp$2S), $[0] = menuOptions, $[1] = t0) : t0 = $[1];
|
|
30665
30665
|
let t1;
|
|
30666
30666
|
$[2] !== t0 ? (t1 = /* @__PURE__ */ jsx(Menu, { children: t0 }), $[2] = t0, $[3] = t1) : t1 = $[3];
|
|
30667
30667
|
let t2;
|
|
30668
30668
|
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;
|
|
30669
30669
|
});
|
|
30670
|
-
function _temp$
|
|
30670
|
+
function _temp$2S(c2, index) {
|
|
30671
30671
|
const {
|
|
30672
30672
|
collapsedProps,
|
|
30673
30673
|
expandedProps,
|
|
@@ -30794,7 +30794,7 @@ const CollapseMenu = forwardRef(function(props2, ref) {
|
|
|
30794
30794
|
}, $[10] = rootEl, $[11] = t3) : t3 = $[11];
|
|
30795
30795
|
const intersectionOptions = t3;
|
|
30796
30796
|
let t4;
|
|
30797
|
-
$[12] !== menuOptions ? (t4 = menuOptions.map(_temp$
|
|
30797
|
+
$[12] !== menuOptions ? (t4 = menuOptions.map(_temp$2R), $[12] = menuOptions, $[13] = t4) : t4 = $[13];
|
|
30798
30798
|
const menuOptionKeys = t4;
|
|
30799
30799
|
let t5;
|
|
30800
30800
|
$[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];
|
|
@@ -30932,7 +30932,7 @@ const CollapseMenu = forwardRef(function(props2, ref) {
|
|
|
30932
30932
|
let t1;
|
|
30933
30933
|
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;
|
|
30934
30934
|
});
|
|
30935
|
-
function _temp$
|
|
30935
|
+
function _temp$2R(child) {
|
|
30936
30936
|
return child.key;
|
|
30937
30937
|
}
|
|
30938
30938
|
const CollapseMenuButton = forwardRef(function(props2, ref) {
|
|
@@ -31105,9 +31105,9 @@ function useActiveActionKeys(t0) {
|
|
|
31105
31105
|
actions
|
|
31106
31106
|
} = t0, editor2 = usePortableTextEditor(), selection = usePortableTextEditorSelection();
|
|
31107
31107
|
let t1;
|
|
31108
|
-
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$
|
|
31108
|
+
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);
|
|
31109
31109
|
}
|
|
31110
|
-
function _temp$
|
|
31110
|
+
function _temp$2Q(a_0) {
|
|
31111
31111
|
return a_0.key;
|
|
31112
31112
|
}
|
|
31113
31113
|
function useActiveStyleKeys(t0) {
|
|
@@ -31115,9 +31115,9 @@ function useActiveStyleKeys(t0) {
|
|
|
31115
31115
|
items
|
|
31116
31116
|
} = t0, editor2 = usePortableTextEditor(), focusBlock = useFocusBlock(), selection = usePortableTextEditorSelection();
|
|
31117
31117
|
let t1;
|
|
31118
|
-
return $[0] !== editor2 || $[1] !== focusBlock || $[2] !== items || $[3] !== selection ? (t1 = focusBlock && selection ? items.filter((i) => PortableTextEditor.hasBlockStyle(editor2, i.style)).map(_temp2$
|
|
31118
|
+
return $[0] !== editor2 || $[1] !== focusBlock || $[2] !== items || $[3] !== selection ? (t1 = focusBlock && selection ? items.filter((i) => PortableTextEditor.hasBlockStyle(editor2, i.style)).map(_temp2$1c) : [], $[0] = editor2, $[1] = focusBlock, $[2] = items, $[3] = selection, $[4] = t1) : t1 = $[4], useUnique(t1);
|
|
31119
31119
|
}
|
|
31120
|
-
function _temp2$
|
|
31120
|
+
function _temp2$1c(i_0) {
|
|
31121
31121
|
return i_0.style;
|
|
31122
31122
|
}
|
|
31123
31123
|
const CollapseMenuMemo$1 = memo(CollapseMenu), MENU_POPOVER_PROPS$4 = {
|
|
@@ -31136,7 +31136,7 @@ const CollapseMenuMemo$1 = memo(CollapseMenu), MENU_POPOVER_PROPS$4 = {
|
|
|
31136
31136
|
$[0] !== selection ? (t0 = selection && isKeySegment(selection.anchor.path[0]) && isKeySegment(selection.focus.path[0]) ? selection.anchor.path[0]._key !== selection?.focus.path[0]._key : selection?.anchor.path[0] !== selection?.focus.path[0], $[0] = selection, $[1] = t0) : t0 = $[1];
|
|
31137
31137
|
const isSelectingMultipleBlocks = t0, isVoidBlock = focusBlock?._type !== editor2.schemaTypes.block.name, isEmptyTextBlock = !isVoidBlock && Array.isArray(focusBlock.children) && focusBlock.children.length === 1 && focusBlock?.children[0].text === "", disabled = disabledProp || isVoidBlock;
|
|
31138
31138
|
let t1;
|
|
31139
|
-
$[2] !== groups ? (t1 = groups.reduce(_temp2$
|
|
31139
|
+
$[2] !== groups ? (t1 = groups.reduce(_temp2$1b, []), $[2] = groups, $[3] = t1) : t1 = $[3];
|
|
31140
31140
|
const actions = t1;
|
|
31141
31141
|
let t2;
|
|
31142
31142
|
$[4] !== actions ? (t2 = {
|
|
@@ -31181,14 +31181,14 @@ const CollapseMenuMemo$1 = memo(CollapseMenu), MENU_POPOVER_PROPS$4 = {
|
|
|
31181
31181
|
let t7;
|
|
31182
31182
|
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;
|
|
31183
31183
|
});
|
|
31184
|
-
function _temp$
|
|
31184
|
+
function _temp$2P(action, actionIndex) {
|
|
31185
31185
|
return actionIndex === 0 ? {
|
|
31186
31186
|
...action,
|
|
31187
31187
|
firstInGroup: !0
|
|
31188
31188
|
} : action;
|
|
31189
31189
|
}
|
|
31190
|
-
function _temp2$
|
|
31191
|
-
return acc.concat(group2.actions.map(_temp$
|
|
31190
|
+
function _temp2$1b(acc, group2) {
|
|
31191
|
+
return acc.concat(group2.actions.map(_temp$2P));
|
|
31192
31192
|
}
|
|
31193
31193
|
const MenuButtonMemo = memo(MenuButton), StyledMenuItem = styled(MenuItem$1)`
|
|
31194
31194
|
// Change the border color variable used by BlockQuote
|
|
@@ -31369,12 +31369,12 @@ const MenuButtonMemo = memo(MenuButton), StyledMenuItem = styled(MenuItem$1)`
|
|
|
31369
31369
|
onToggleFullscreen
|
|
31370
31370
|
} = t0, {
|
|
31371
31371
|
t
|
|
31372
|
-
} = useTranslation(), showActionMenu = actionGroups.reduce(_temp$
|
|
31372
|
+
} = 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;
|
|
31373
31373
|
let t1;
|
|
31374
31374
|
$[0] !== rootElement ? (t1 = {
|
|
31375
31375
|
rootElement
|
|
31376
31376
|
}, $[0] = rootElement, $[1] = t1) : t1 = $[1], useRovingFocus(t1);
|
|
31377
|
-
const preventEditorBlurOnToolbarMouseDown = _temp2$
|
|
31377
|
+
const preventEditorBlurOnToolbarMouseDown = _temp2$1a;
|
|
31378
31378
|
let t2;
|
|
31379
31379
|
$[2] !== blockStyles || $[3] !== collapsed || $[4] !== disabled || $[5] !== isFullscreen || $[6] !== rootElement || $[7] !== showBlockStyleSelect ? (t2 = showBlockStyleSelect && /* @__PURE__ */ jsx(StyleSelectFlex, { flex: collapsed ? 1 : void 0, children: /* @__PURE__ */ jsx(StyleSelectBox, { padding: isFullscreen ? 2 : 1, "data-testid": "block-style-select", children: /* @__PURE__ */ jsx(BlockStyleSelect, { disabled, items: blockStyles, boundaryElement: rootElement }) }) }), $[2] = blockStyles, $[3] = collapsed, $[4] = disabled, $[5] = isFullscreen, $[6] = rootElement, $[7] = showBlockStyleSelect, $[8] = t2) : t2 = $[8];
|
|
31380
31380
|
let t3;
|
|
@@ -31478,10 +31478,10 @@ function Toolbar(props2) {
|
|
|
31478
31478
|
let t6;
|
|
31479
31479
|
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;
|
|
31480
31480
|
}
|
|
31481
|
-
function _temp$
|
|
31481
|
+
function _temp$2O(acc, x) {
|
|
31482
31482
|
return acc + x.actions.length;
|
|
31483
31483
|
}
|
|
31484
|
-
function _temp2$
|
|
31484
|
+
function _temp2$1a(e) {
|
|
31485
31485
|
e.preventDefault();
|
|
31486
31486
|
}
|
|
31487
31487
|
const noOutlineStyle = {
|
|
@@ -31636,7 +31636,7 @@ function useTrackFocusPath(props2) {
|
|
|
31636
31636
|
$[0] !== boundaryElement || $[1] !== editor2 || $[2] !== elementRefs || $[3] !== focusPath || $[4] !== portableTextMemberItems || $[5] !== selection ? (t0 = () => {
|
|
31637
31637
|
if (focusPath.length === 0 || selection?.focus.path && isEqual$3(selection.focus.path, focusPath.slice(0, selection.focus.path.length)))
|
|
31638
31638
|
return;
|
|
31639
|
-
const focusedItem = portableTextMemberItems.find(_temp$
|
|
31639
|
+
const focusedItem = portableTextMemberItems.find(_temp$2N), openItem = portableTextMemberItems.find(_temp2$19), relatedEditorItem = focusedItem || openItem, elementRef = relatedEditorItem ? elementRefs[relatedEditorItem.member.key] : void 0;
|
|
31640
31640
|
if (relatedEditorItem && elementRef) {
|
|
31641
31641
|
boundaryElement && (scrollIntoView$1(boundaryElement, {
|
|
31642
31642
|
scrollMode: "if-needed",
|
|
@@ -31673,10 +31673,10 @@ function useTrackFocusPath(props2) {
|
|
|
31673
31673
|
let t2;
|
|
31674
31674
|
$[7] !== boundaryElement || $[8] !== editor2 || $[9] !== elementRefs || $[10] !== focusPath || $[11] !== onItemClose || $[12] !== portableTextMemberItems || $[13] !== t1 ? (t2 = [boundaryElement, editor2, elementRefs, focusPath, onItemClose, portableTextMemberItems, t1], $[7] = boundaryElement, $[8] = editor2, $[9] = elementRefs, $[10] = focusPath, $[11] = onItemClose, $[12] = portableTextMemberItems, $[13] = t1, $[14] = t2) : t2 = $[14], useLayoutEffect(t0, t2);
|
|
31675
31675
|
}
|
|
31676
|
-
function _temp2$
|
|
31676
|
+
function _temp2$19(m_0) {
|
|
31677
31677
|
return m_0.member.open;
|
|
31678
31678
|
}
|
|
31679
|
-
function _temp$
|
|
31679
|
+
function _temp$2N(m) {
|
|
31680
31680
|
return m.member.item.focused;
|
|
31681
31681
|
}
|
|
31682
31682
|
const Root$h = styled(Card)(rootStyle), PreviewSpan = styled.span`
|
|
@@ -32146,10 +32146,10 @@ const InlineObject = (props2) => {
|
|
|
32146
32146
|
t
|
|
32147
32147
|
} = useTranslation(), hasMarkers = markers.length > 0, popoverTitle = schemaType?.title || schemaType.name;
|
|
32148
32148
|
let t0;
|
|
32149
|
-
$[0] !== validation2 ? (t0 = validation2.filter(_temp$
|
|
32149
|
+
$[0] !== validation2 ? (t0 = validation2.filter(_temp$2M), $[0] = validation2, $[1] = t0) : t0 = $[1];
|
|
32150
32150
|
const hasError = t0.length > 0;
|
|
32151
32151
|
let t1;
|
|
32152
|
-
$[2] !== validation2 ? (t1 = validation2.filter(_temp2$
|
|
32152
|
+
$[2] !== validation2 ? (t1 = validation2.filter(_temp2$18), $[2] = validation2, $[3] = t1) : t1 = $[3];
|
|
32153
32153
|
const hasWarning = t1.length > 0, {
|
|
32154
32154
|
enabled: nestedObjectNavigationEnabled,
|
|
32155
32155
|
isDialogAvailable
|
|
@@ -32200,16 +32200,16 @@ const InlineObject = (props2) => {
|
|
|
32200
32200
|
t16
|
|
32201
32201
|
] }), $[44] = t14, $[45] = t15, $[46] = t16, $[47] = t17) : t17 = $[47], t17;
|
|
32202
32202
|
};
|
|
32203
|
-
function _temp$
|
|
32203
|
+
function _temp$2M(v) {
|
|
32204
32204
|
return v.level === "error";
|
|
32205
32205
|
}
|
|
32206
|
-
function _temp2$
|
|
32206
|
+
function _temp2$18(v_0) {
|
|
32207
32207
|
return v_0.level === "warning";
|
|
32208
32208
|
}
|
|
32209
32209
|
function AnnotationObjectEditModal(props2) {
|
|
32210
32210
|
const $ = c(14), editor2 = usePortableTextEditor(), boundaryElement = useBoundaryElement().element, portableTextMemberItems = usePortableTextMemberItems(), elementRefs = usePortableTextMemberItemElementRefs();
|
|
32211
32211
|
let t0;
|
|
32212
|
-
$[0] !== portableTextMemberItems ? (t0 = portableTextMemberItems.find(_temp$
|
|
32212
|
+
$[0] !== portableTextMemberItems ? (t0 = portableTextMemberItems.find(_temp$2L), $[0] = portableTextMemberItems, $[1] = t0) : t0 = $[1];
|
|
32213
32213
|
const openAnnotation = t0;
|
|
32214
32214
|
let t1;
|
|
32215
32215
|
$[2] !== editor2 || $[3] !== openAnnotation || $[4] !== props2 ? (t1 = () => {
|
|
@@ -32225,7 +32225,7 @@ function AnnotationObjectEditModal(props2) {
|
|
|
32225
32225
|
let t3;
|
|
32226
32226
|
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;
|
|
32227
32227
|
}
|
|
32228
|
-
function _temp$
|
|
32228
|
+
function _temp$2L(m) {
|
|
32229
32229
|
return m.kind === "annotation" && m.member.open;
|
|
32230
32230
|
}
|
|
32231
32231
|
function Compositor(props2) {
|
|
@@ -32620,7 +32620,7 @@ function useOptimisticPortableTextDiff(t0) {
|
|
|
32620
32620
|
t22 = Object.values(optimisticRangeDecorations).concat(Object.entries(definitiveRangeDecorations).filter((t32) => {
|
|
32621
32621
|
const [blockKey] = t32;
|
|
32622
32622
|
return typeof optimisticRangeDecorations[blockKey] > "u";
|
|
32623
|
-
}).map(_temp$
|
|
32623
|
+
}).map(_temp$2K)).flat(), $[2] = definitiveValue, $[3] = optimisticValue, $[4] = perspective, $[5] = upstreamValue, $[6] = t22;
|
|
32624
32624
|
} else
|
|
32625
32625
|
t22 = $[6];
|
|
32626
32626
|
t1 = t22;
|
|
@@ -32658,7 +32658,7 @@ function useOptimisticPortableTextDiff(t0) {
|
|
|
32658
32658
|
onOptimisticChange
|
|
32659
32659
|
}, $[14] = onOptimisticChange, $[15] = rangeDecorations, $[16] = t5) : t5 = $[16], t5;
|
|
32660
32660
|
}
|
|
32661
|
-
function _temp$
|
|
32661
|
+
function _temp$2K(t0) {
|
|
32662
32662
|
const [, blockRangeDecorations] = t0;
|
|
32663
32663
|
return blockRangeDecorations;
|
|
32664
32664
|
}
|
|
@@ -32787,7 +32787,7 @@ const markdownConfig = {
|
|
|
32787
32787
|
typography: {
|
|
32788
32788
|
enabled: !1,
|
|
32789
32789
|
guard: createDecoratorGuard({
|
|
32790
|
-
decorators: _temp2$
|
|
32790
|
+
decorators: _temp2$17
|
|
32791
32791
|
})
|
|
32792
32792
|
}
|
|
32793
32793
|
},
|
|
@@ -32879,14 +32879,14 @@ const RenderDefault = (props2) => {
|
|
|
32879
32879
|
let t1;
|
|
32880
32880
|
return $[1] !== RenderPlugins || $[2] !== props2 ? (t1 = /* @__PURE__ */ jsx(RenderPlugins, { ...props2 }), $[1] = RenderPlugins, $[2] = props2, $[3] = t1) : t1 = $[3], t1;
|
|
32881
32881
|
};
|
|
32882
|
-
function _temp$
|
|
32882
|
+
function _temp$2J(decorator) {
|
|
32883
32883
|
return decorator.name === "code" ? [] : [decorator.name];
|
|
32884
32884
|
}
|
|
32885
|
-
function _temp2$
|
|
32885
|
+
function _temp2$17(t0) {
|
|
32886
32886
|
const {
|
|
32887
32887
|
context
|
|
32888
32888
|
} = t0;
|
|
32889
|
-
return context.schema.decorators.flatMap(_temp$
|
|
32889
|
+
return context.schema.decorators.flatMap(_temp$2J);
|
|
32890
32890
|
}
|
|
32891
32891
|
const DOT_SIZE = 6, CONTENT_BOX_VARIANTS = {
|
|
32892
32892
|
animate: {
|
|
@@ -33043,7 +33043,7 @@ function usePresenceCursorDecorations(props2) {
|
|
|
33043
33043
|
const handleRangeDecorationMoved = t2;
|
|
33044
33044
|
let t3, t4;
|
|
33045
33045
|
$[3] !== fieldPresence || $[4] !== path ? (t3 = () => {
|
|
33046
|
-
const nextPresence = fieldPresence.filter((p_0) => startsWith(path, p_0.path) && !isEqual$2(path, p_0.path)), filteredNext = nextPresence.map(_temp$
|
|
33046
|
+
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);
|
|
33047
33047
|
if (!isEqual$2(filteredNext, filteredPrevious)) {
|
|
33048
33048
|
const value = nextPresence.length > 0 ? nextPresence : EMPTY_ARRAY$B;
|
|
33049
33049
|
setCurrentPresence(value), previousPresence.current = value;
|
|
@@ -33075,13 +33075,13 @@ function usePresenceCursorDecorations(props2) {
|
|
|
33075
33075
|
setPresenceCursorDecorations(decorations.filter(Boolean));
|
|
33076
33076
|
}, t6 = [currentPresence, handleRangeDecorationMoved], $[7] = currentPresence, $[8] = t5, $[9] = t6) : (t5 = $[8], t6 = $[9]), useEffect(t5, t6), presenceCursorDecorations;
|
|
33077
33077
|
}
|
|
33078
|
-
function _temp2$
|
|
33078
|
+
function _temp2$16(d_0) {
|
|
33079
33079
|
return {
|
|
33080
33080
|
...d_0.selection,
|
|
33081
33081
|
sessionId: d_0.sessionId
|
|
33082
33082
|
};
|
|
33083
33083
|
}
|
|
33084
|
-
function _temp$
|
|
33084
|
+
function _temp$2I(d) {
|
|
33085
33085
|
return {
|
|
33086
33086
|
...d.selection,
|
|
33087
33087
|
sessionId: d.sessionId
|
|
@@ -33962,12 +33962,12 @@ function useFeatureEnabled(featureKey) {
|
|
|
33962
33962
|
features: features2,
|
|
33963
33963
|
error: null
|
|
33964
33964
|
};
|
|
33965
|
-
}, $[6] = featureKey, $[7] = t2) : t2 = $[7], t1 = req.pipe(map(t2), startWith(INITIAL_LOADING_STATE$3), catchError(_temp$
|
|
33965
|
+
}, $[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;
|
|
33966
33966
|
} else
|
|
33967
33967
|
t1 = $[5];
|
|
33968
33968
|
return useObservable(t1, INITIAL_LOADING_STATE$3);
|
|
33969
33969
|
}
|
|
33970
|
-
function _temp$
|
|
33970
|
+
function _temp$2H(error) {
|
|
33971
33971
|
return of({
|
|
33972
33972
|
isLoading: !1,
|
|
33973
33973
|
enabled: !1,
|
|
@@ -33984,7 +33984,7 @@ function DisabledFeatureWarning(t0) {
|
|
|
33984
33984
|
} = useTranslation();
|
|
33985
33985
|
let t1;
|
|
33986
33986
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = {
|
|
33987
|
-
DocumentationLink: _temp$
|
|
33987
|
+
DocumentationLink: _temp$2G
|
|
33988
33988
|
}, $[0] = t1) : t1 = $[0];
|
|
33989
33989
|
let t2;
|
|
33990
33990
|
$[1] !== t ? (t2 = /* @__PURE__ */ jsx(Translate, { t, i18nKey: "inputs.reference.cross-dataset.feature-disabled-description", components: t1 }), $[1] = t, $[2] = t2) : t2 = $[2];
|
|
@@ -34021,7 +34021,7 @@ function DisabledFeatureWarning(t0) {
|
|
|
34021
34021
|
t11
|
|
34022
34022
|
] }), $[26] = t10, $[27] = t11, $[28] = t12) : t12 = $[28], t12;
|
|
34023
34023
|
}
|
|
34024
|
-
function _temp$
|
|
34024
|
+
function _temp$2G(t0) {
|
|
34025
34025
|
const {
|
|
34026
34026
|
children
|
|
34027
34027
|
} = t0;
|
|
@@ -34117,7 +34117,7 @@ function useReferenceInfo$1(doc, getReferenceInfo2) {
|
|
|
34117
34117
|
const $ = c(8), [retryAttempt, setRetryAttempt] = useState(0);
|
|
34118
34118
|
let t0;
|
|
34119
34119
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => {
|
|
34120
|
-
setRetryAttempt(_temp$
|
|
34120
|
+
setRetryAttempt(_temp$2F);
|
|
34121
34121
|
}, $[0] = t0) : t0 = $[0];
|
|
34122
34122
|
const retry2 = t0;
|
|
34123
34123
|
let t1;
|
|
@@ -34141,7 +34141,7 @@ function useReferenceInfo$1(doc, getReferenceInfo2) {
|
|
|
34141
34141
|
retryAttempt
|
|
34142
34142
|
})))) : of(EMPTY_STATE$1), $[4] = docInfo, $[5] = getReferenceInfo2, $[6] = retryAttempt, $[7] = t2) : t2 = $[7], useObservable(t2, INITIAL_LOADING_STATE$2);
|
|
34143
34143
|
}
|
|
34144
|
-
function _temp$
|
|
34144
|
+
function _temp$2F(current) {
|
|
34145
34145
|
return current + 1;
|
|
34146
34146
|
}
|
|
34147
34147
|
function useProjectId$1() {
|
|
@@ -34381,7 +34381,7 @@ function CrossDatasetReferenceInput(props2) {
|
|
|
34381
34381
|
push
|
|
34382
34382
|
} = useToast();
|
|
34383
34383
|
let t12;
|
|
34384
|
-
$[29] !== validation2 ? (t12 = validation2.filter(_temp$
|
|
34384
|
+
$[29] !== validation2 ? (t12 = validation2.filter(_temp$2E), $[29] = validation2, $[30] = t12) : t12 = $[30];
|
|
34385
34385
|
const errors = t12;
|
|
34386
34386
|
let t13;
|
|
34387
34387
|
$[31] !== onPathFocus ? (t13 = (event_0) => {
|
|
@@ -34412,7 +34412,7 @@ function CrossDatasetReferenceInput(props2) {
|
|
|
34412
34412
|
id: `reference-search-fail-${inputId}`
|
|
34413
34413
|
}), console.error(error), of({
|
|
34414
34414
|
hits: []
|
|
34415
|
-
})))))), scan(_temp2$
|
|
34415
|
+
})))))), scan(_temp2$15, INITIAL_SEARCH_STATE$2), tap(setSearchState)), $[37] = inputId, $[38] = onSearch, $[39] = push, $[40] = t16) : t16 = $[40];
|
|
34416
34416
|
const handleQueryChange = useObservableEvent(t16);
|
|
34417
34417
|
let t17;
|
|
34418
34418
|
$[41] !== handleQueryChange ? (t17 = () => {
|
|
@@ -34435,7 +34435,7 @@ function CrossDatasetReferenceInput(props2) {
|
|
|
34435
34435
|
let t22;
|
|
34436
34436
|
$[54] !== featureInfo.enabled || $[55] !== featureInfo.isLoading || $[56] !== handleClear || $[57] !== value ? (t22 = !featureInfo.isLoading && !featureInfo.enabled && /* @__PURE__ */ jsx(DisabledFeatureWarning, { value, onClearValue: handleClear }), $[54] = featureInfo.enabled, $[55] = featureInfo.isLoading, $[56] = handleClear, $[57] = value, $[58] = t22) : t22 = $[58];
|
|
34437
34437
|
let t23;
|
|
34438
|
-
$[59] !== actualStrength || $[60] !== autocompletePopoverReferenceElement || $[61] !== changed || $[62] !== elementProps || $[63] !== errors || $[64] !== featureInfo.enabled || $[65] !== featureInfo.isLoading || $[66] !== focused || $[67] !== handleAutocompleteFocus || $[68] !== handleAutocompleteKeyDown || $[69] !== handleAutocompleteOpenButtonClick || $[70] !== handleChange || $[71] !== handleClear || $[72] !== handleFixStrengthMismatch || $[73] !== handleFocus || $[74] !== handleQueryChange || $[75] !== handleReplace || $[76] !== inputId || $[77] !== isEditing || $[78] !== loadableReferenceInfo || $[79] !== path || $[80] !== readOnly || $[81] !== renderOption || $[82] !== schemaType || $[83] !== searchState.hits || $[84] !== searchState.isLoading || $[85] !== searchState.searchString || $[86] !== showWeakRefMismatch || $[87] !== studioUrl || $[88] !== t || $[89] !== value ? (t23 = (featureInfo.isLoading || featureInfo.enabled) && /* @__PURE__ */ jsx(Stack, { space: 1, children: isEditing ? /* @__PURE__ */ jsx(Stack, { space: 2, ref: clickOutsideBoundaryRef, children: /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !!focused, children: /* @__PURE__ */ jsx("div", { ref: setAutocompletePopoverReferenceElement, children: /* @__PURE__ */ jsx(ReferenceAutocomplete$2, { ...elementProps, "data-testid": "autocomplete", loading: searchState.isLoading, referenceElement: autocompletePopoverReferenceElement, portalRef: autocompletePortalRef, id: inputId || "", options: searchState.hits.map(_temp3$
|
|
34438
|
+
$[59] !== actualStrength || $[60] !== autocompletePopoverReferenceElement || $[61] !== changed || $[62] !== elementProps || $[63] !== errors || $[64] !== featureInfo.enabled || $[65] !== featureInfo.isLoading || $[66] !== focused || $[67] !== handleAutocompleteFocus || $[68] !== handleAutocompleteKeyDown || $[69] !== handleAutocompleteOpenButtonClick || $[70] !== handleChange || $[71] !== handleClear || $[72] !== handleFixStrengthMismatch || $[73] !== handleFocus || $[74] !== handleQueryChange || $[75] !== handleReplace || $[76] !== inputId || $[77] !== isEditing || $[78] !== loadableReferenceInfo || $[79] !== path || $[80] !== readOnly || $[81] !== renderOption || $[82] !== schemaType || $[83] !== searchState.hits || $[84] !== searchState.isLoading || $[85] !== searchState.searchString || $[86] !== showWeakRefMismatch || $[87] !== studioUrl || $[88] !== t || $[89] !== value ? (t23 = (featureInfo.isLoading || featureInfo.enabled) && /* @__PURE__ */ jsx(Stack, { space: 1, children: isEditing ? /* @__PURE__ */ jsx(Stack, { space: 2, ref: clickOutsideBoundaryRef, children: /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !!focused, children: /* @__PURE__ */ jsx("div", { ref: setAutocompletePopoverReferenceElement, children: /* @__PURE__ */ jsx(ReferenceAutocomplete$2, { ...elementProps, "data-testid": "autocomplete", loading: searchState.isLoading, referenceElement: autocompletePopoverReferenceElement, portalRef: autocompletePortalRef, id: inputId || "", options: searchState.hits.map(_temp3$x), onFocus: handleAutocompleteFocus, radius: 2, placeholder: t("inputs.reference.search-placeholder"), onKeyDown: handleAutocompleteKeyDown, readOnly, disabled: loadableReferenceInfo.isLoading, onQueryChange: handleQueryChange, searchString: searchState.searchString, onChange: handleChange, filterOption: NO_FILTER$2, renderOption, openButton: {
|
|
34439
34439
|
onClick: handleAutocompleteOpenButtonClick
|
|
34440
34440
|
}, ref: focusElementRef }) }) }) }) : /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !!focused, children: /* @__PURE__ */ jsxs(Card, { padding: 0, border: !0, flex: 1, radius: 2, tone: readOnly ? "transparent" : loadableReferenceInfo.error || errors.length > 0 ? "critical" : "default", children: [
|
|
34441
34441
|
/* @__PURE__ */ jsxs(Flex, { align: "center", padding: 1, children: [
|
|
@@ -34457,19 +34457,19 @@ function CrossDatasetReferenceInput(props2) {
|
|
|
34457
34457
|
t23
|
|
34458
34458
|
] }), $[91] = t22, $[92] = t23, $[93] = t24) : t24 = $[93], t24;
|
|
34459
34459
|
}
|
|
34460
|
-
function _temp3$
|
|
34460
|
+
function _temp3$x(hit_0) {
|
|
34461
34461
|
return {
|
|
34462
34462
|
value: hit_0.id,
|
|
34463
34463
|
hit: hit_0
|
|
34464
34464
|
};
|
|
34465
34465
|
}
|
|
34466
|
-
function _temp2$
|
|
34466
|
+
function _temp2$15(prevState, nextState) {
|
|
34467
34467
|
return {
|
|
34468
34468
|
...prevState,
|
|
34469
34469
|
...nextState
|
|
34470
34470
|
};
|
|
34471
34471
|
}
|
|
34472
|
-
function _temp$
|
|
34472
|
+
function _temp$2E(item) {
|
|
34473
34473
|
return item.level === "error";
|
|
34474
34474
|
}
|
|
34475
34475
|
const REQUEST_TAG_BASE$1 = "cross-dataset-refs", AVAILABILITY_READABLE$2 = {
|
|
@@ -34715,7 +34715,7 @@ function useReferenceInfo(doc, getReferenceInfo2) {
|
|
|
34715
34715
|
const $ = c(10), [retryAttempt, setRetryAttempt] = useState(0);
|
|
34716
34716
|
let t0;
|
|
34717
34717
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = () => {
|
|
34718
|
-
setRetryAttempt(_temp$
|
|
34718
|
+
setRetryAttempt(_temp$2D);
|
|
34719
34719
|
}, $[0] = t0) : t0 = $[0];
|
|
34720
34720
|
const retry2 = t0;
|
|
34721
34721
|
let t1;
|
|
@@ -34749,7 +34749,7 @@ function useReferenceInfo(doc, getReferenceInfo2) {
|
|
|
34749
34749
|
}
|
|
34750
34750
|
return useObservable(t1, INITIAL_LOADING_STATE$1);
|
|
34751
34751
|
}
|
|
34752
|
-
function _temp$
|
|
34752
|
+
function _temp$2D(current) {
|
|
34753
34753
|
return current + 1;
|
|
34754
34754
|
}
|
|
34755
34755
|
function OptionPreview(props2) {
|
|
@@ -34992,7 +34992,7 @@ function GlobalDocumentReferenceInput(props2) {
|
|
|
34992
34992
|
push
|
|
34993
34993
|
} = useToast();
|
|
34994
34994
|
let t11;
|
|
34995
|
-
$[31] !== validation2 ? (t11 = validation2.filter(_temp$
|
|
34995
|
+
$[31] !== validation2 ? (t11 = validation2.filter(_temp$2C), $[31] = validation2, $[32] = t11) : t11 = $[32];
|
|
34996
34996
|
const errors = t11;
|
|
34997
34997
|
let t12;
|
|
34998
34998
|
$[33] !== onPathFocus ? (t12 = (event_0) => {
|
|
@@ -35023,7 +35023,7 @@ function GlobalDocumentReferenceInput(props2) {
|
|
|
35023
35023
|
id: `reference-search-fail-${inputId}`
|
|
35024
35024
|
}), console.error(error), of({
|
|
35025
35025
|
hits: []
|
|
35026
|
-
})))))), scan(_temp2$
|
|
35026
|
+
})))))), scan(_temp2$14, INITIAL_SEARCH_STATE$1), tap(setSearchState)), $[39] = inputId, $[40] = onSearch, $[41] = push, $[42] = t15) : t15 = $[42];
|
|
35027
35027
|
const handleQueryChange = useObservableEvent(t15);
|
|
35028
35028
|
let t16;
|
|
35029
35029
|
$[43] !== handleQueryChange ? (t16 = () => {
|
|
@@ -35067,7 +35067,7 @@ function GlobalDocumentReferenceInput(props2) {
|
|
|
35067
35067
|
let t20;
|
|
35068
35068
|
$[55] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t20 = () => [clickOutsideBoundaryRef.current, autocompletePortalRef.current], $[55] = t20) : t20 = $[55], useClickOutsideEvent(t19, t20);
|
|
35069
35069
|
let t21;
|
|
35070
|
-
return $[56] !== actualStrength || $[57] !== autocompletePopoverReferenceElement || $[58] !== changed || $[59] !== elementProps || $[60] !== errors || $[61] !== focused || $[62] !== handleAutocompleteFocus || $[63] !== handleAutocompleteKeyDown || $[64] !== handleAutocompleteOpenButtonClick || $[65] !== handleChange || $[66] !== handleClear || $[67] !== handleFixStrengthMismatch || $[68] !== handleFocus || $[69] !== handleQueryChange || $[70] !== handleReplace || $[71] !== inputId || $[72] !== isEditing || $[73] !== loadableReferenceInfo || $[74] !== path || $[75] !== readOnly || $[76] !== renderOption || $[77] !== schemaType || $[78] !== searchState.hits || $[79] !== searchState.isLoading || $[80] !== searchState.searchString || $[81] !== showWeakRefMismatch || $[82] !== studioUrl || $[83] !== t || $[84] !== value ? (t21 = /* @__PURE__ */ jsx(Stack, { space: 1, children: isEditing ? /* @__PURE__ */ jsx(Stack, { space: 2, ref: clickOutsideBoundaryRef, children: /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !!focused, children: /* @__PURE__ */ jsx("div", { ref: setAutocompletePopoverReferenceElement, children: /* @__PURE__ */ jsx(ReferenceAutocomplete$1, { ...elementProps, "data-testid": "autocomplete", loading: searchState.isLoading, referenceElement: autocompletePopoverReferenceElement, portalRef: autocompletePortalRef, id: inputId || "", options: searchState.hits.map(_temp3$
|
|
35070
|
+
return $[56] !== actualStrength || $[57] !== autocompletePopoverReferenceElement || $[58] !== changed || $[59] !== elementProps || $[60] !== errors || $[61] !== focused || $[62] !== handleAutocompleteFocus || $[63] !== handleAutocompleteKeyDown || $[64] !== handleAutocompleteOpenButtonClick || $[65] !== handleChange || $[66] !== handleClear || $[67] !== handleFixStrengthMismatch || $[68] !== handleFocus || $[69] !== handleQueryChange || $[70] !== handleReplace || $[71] !== inputId || $[72] !== isEditing || $[73] !== loadableReferenceInfo || $[74] !== path || $[75] !== readOnly || $[76] !== renderOption || $[77] !== schemaType || $[78] !== searchState.hits || $[79] !== searchState.isLoading || $[80] !== searchState.searchString || $[81] !== showWeakRefMismatch || $[82] !== studioUrl || $[83] !== t || $[84] !== value ? (t21 = /* @__PURE__ */ jsx(Stack, { space: 1, children: isEditing ? /* @__PURE__ */ jsx(Stack, { space: 2, ref: clickOutsideBoundaryRef, children: /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !!focused, children: /* @__PURE__ */ jsx("div", { ref: setAutocompletePopoverReferenceElement, children: /* @__PURE__ */ jsx(ReferenceAutocomplete$1, { ...elementProps, "data-testid": "autocomplete", loading: searchState.isLoading, referenceElement: autocompletePopoverReferenceElement, portalRef: autocompletePortalRef, id: inputId || "", options: searchState.hits.map(_temp3$w), onFocus: handleAutocompleteFocus, radius: 2, placeholder: t("inputs.reference.search-placeholder"), onKeyDown: handleAutocompleteKeyDown, readOnly, disabled: loadableReferenceInfo.isLoading, onQueryChange: handleQueryChange, searchString: searchState.searchString, onChange: handleChange, filterOption: NO_FILTER$1, renderOption, openButton: {
|
|
35071
35071
|
onClick: handleAutocompleteOpenButtonClick
|
|
35072
35072
|
}, ref: focusElementRef }) }) }) }) : /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !!focused, children: /* @__PURE__ */ jsxs(Card, { padding: 0, border: !0, flex: 1, radius: 1, tone: readOnly ? "transparent" : loadableReferenceInfo.error || errors.length > 0 ? "critical" : "default", children: [
|
|
35073
35073
|
/* @__PURE__ */ jsxs(Flex, { align: "center", padding: 1, children: [
|
|
@@ -35084,19 +35084,19 @@ function GlobalDocumentReferenceInput(props2) {
|
|
|
35084
35084
|
loadableReferenceInfo.error && /* @__PURE__ */ jsx(ReferenceMetadataLoadErrorAlertStrip, { errorMessage: loadableReferenceInfo.error.message, onHandleRetry: loadableReferenceInfo.retry })
|
|
35085
35085
|
] }) }) }), $[56] = actualStrength, $[57] = autocompletePopoverReferenceElement, $[58] = changed, $[59] = elementProps, $[60] = errors, $[61] = focused, $[62] = handleAutocompleteFocus, $[63] = handleAutocompleteKeyDown, $[64] = handleAutocompleteOpenButtonClick, $[65] = handleChange, $[66] = handleClear, $[67] = handleFixStrengthMismatch, $[68] = handleFocus, $[69] = handleQueryChange, $[70] = handleReplace, $[71] = inputId, $[72] = isEditing, $[73] = loadableReferenceInfo, $[74] = path, $[75] = readOnly, $[76] = renderOption, $[77] = schemaType, $[78] = searchState.hits, $[79] = searchState.isLoading, $[80] = searchState.searchString, $[81] = showWeakRefMismatch, $[82] = studioUrl, $[83] = t, $[84] = value, $[85] = t21) : t21 = $[85], t21;
|
|
35086
35086
|
}
|
|
35087
|
-
function _temp3$
|
|
35087
|
+
function _temp3$w(hit_0) {
|
|
35088
35088
|
return {
|
|
35089
35089
|
value: hit_0.id,
|
|
35090
35090
|
hit: hit_0
|
|
35091
35091
|
};
|
|
35092
35092
|
}
|
|
35093
|
-
function _temp2$
|
|
35093
|
+
function _temp2$14(prevState, nextState) {
|
|
35094
35094
|
return {
|
|
35095
35095
|
...prevState,
|
|
35096
35096
|
...nextState
|
|
35097
35097
|
};
|
|
35098
35098
|
}
|
|
35099
|
-
function _temp$
|
|
35099
|
+
function _temp$2C(item) {
|
|
35100
35100
|
return item.level === "error";
|
|
35101
35101
|
}
|
|
35102
35102
|
function getReferenceClient(client, schemaType) {
|
|
@@ -35604,7 +35604,7 @@ const TRANSFORMATIONS = {
|
|
|
35604
35604
|
const controller = new AbortController(), signal = controller.signal;
|
|
35605
35605
|
return fetch(props2.icon.url, {
|
|
35606
35606
|
signal
|
|
35607
|
-
}).then(_temp$
|
|
35607
|
+
}).then(_temp$2B).then((data) => setHtml(data)).catch(_temp2$13), () => {
|
|
35608
35608
|
controller.abort();
|
|
35609
35609
|
};
|
|
35610
35610
|
}, t1 = [props2.icon.url], $[0] = props2.icon.url, $[1] = t0, $[2] = t1) : (t0 = $[1], t1 = $[2]), useEffect(t0, t1);
|
|
@@ -35755,12 +35755,12 @@ function UpsellDescriptionSerializer(props2) {
|
|
|
35755
35755
|
let t2;
|
|
35756
35756
|
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;
|
|
35757
35757
|
}
|
|
35758
|
-
function _temp$
|
|
35758
|
+
function _temp$2B(response) {
|
|
35759
35759
|
if (!response.ok)
|
|
35760
35760
|
throw new Error(`HTTP error! status: ${response.status}`);
|
|
35761
35761
|
return response.text();
|
|
35762
35762
|
}
|
|
35763
|
-
function _temp2$
|
|
35763
|
+
function _temp2$13(error) {
|
|
35764
35764
|
error.name !== "AbortError" && console.error(error);
|
|
35765
35765
|
}
|
|
35766
35766
|
const StyledButton$3 = styled(Button)(({
|
|
@@ -35890,9 +35890,9 @@ function useReferringDocuments(id2, t0) {
|
|
|
35890
35890
|
docId: id2
|
|
35891
35891
|
}, {
|
|
35892
35892
|
tag: "use-referring-documents"
|
|
35893
|
-
}).pipe(map(_temp$
|
|
35893
|
+
}).pipe(map(_temp$2A), startWith(INITIAL_STATE$8)), $[2] = documentStore, $[3] = id2, $[4] = projection, $[5] = t2) : t2 = $[5], useObservable(t2, INITIAL_STATE$8);
|
|
35894
35894
|
}
|
|
35895
|
-
function _temp$
|
|
35895
|
+
function _temp$2A(docs) {
|
|
35896
35896
|
return {
|
|
35897
35897
|
referringDocuments: docs,
|
|
35898
35898
|
isLoading: !1
|
|
@@ -35920,7 +35920,7 @@ const AssetUsageList = (t0) => {
|
|
|
35920
35920
|
let t6;
|
|
35921
35921
|
$[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];
|
|
35922
35922
|
let t7;
|
|
35923
|
-
$[11] !== referringDocuments ? (t7 = referringDocuments.map(_temp$
|
|
35923
|
+
$[11] !== referringDocuments ? (t7 = referringDocuments.map(_temp$2z), $[11] = referringDocuments, $[12] = t7) : t7 = $[12];
|
|
35924
35924
|
let t8;
|
|
35925
35925
|
return $[13] !== t6 || $[14] !== t7 ? (t8 = /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
35926
35926
|
t6,
|
|
@@ -35948,7 +35948,7 @@ const AssetUsageList = (t0) => {
|
|
|
35948
35948
|
let t6;
|
|
35949
35949
|
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;
|
|
35950
35950
|
};
|
|
35951
|
-
function _temp$
|
|
35951
|
+
function _temp$2z(document2) {
|
|
35952
35952
|
return /* @__PURE__ */ jsx(DocumentLink, { document: document2 }, document2._id);
|
|
35953
35953
|
}
|
|
35954
35954
|
const STYLE_ASSET_IMAGE = {
|
|
@@ -36044,7 +36044,7 @@ function AssetDeleteDialog(t0) {
|
|
|
36044
36044
|
} = useLegacyReferringDocuments(asset._id);
|
|
36045
36045
|
let t2;
|
|
36046
36046
|
if ($[0] !== referringDocuments) {
|
|
36047
|
-
const drafts = referringDocuments.reduce(_temp$
|
|
36047
|
+
const drafts = referringDocuments.reduce(_temp$2y, []);
|
|
36048
36048
|
t2 = referringDocuments.filter((doc_0) => !drafts.includes(doc_0._id)), $[0] = referringDocuments, $[1] = t2;
|
|
36049
36049
|
} else
|
|
36050
36050
|
t2 = $[1];
|
|
@@ -36085,7 +36085,7 @@ function AssetDeleteDialog(t0) {
|
|
|
36085
36085
|
let t10;
|
|
36086
36086
|
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;
|
|
36087
36087
|
}
|
|
36088
|
-
function _temp$
|
|
36088
|
+
function _temp$2y(acc, doc) {
|
|
36089
36089
|
return doc._id.startsWith("drafts.") ? acc.concat(doc._id.slice(7)) : acc;
|
|
36090
36090
|
}
|
|
36091
36091
|
const MENU_POPOVER_PROPS$2 = {
|
|
@@ -36141,7 +36141,7 @@ function AssetUsageDialog(t0) {
|
|
|
36141
36141
|
} = useLegacyReferringDocuments(asset._id);
|
|
36142
36142
|
let t1;
|
|
36143
36143
|
if ($[0] !== referringDocuments) {
|
|
36144
|
-
const drafts = referringDocuments.reduce(_temp$
|
|
36144
|
+
const drafts = referringDocuments.reduce(_temp$2x, []);
|
|
36145
36145
|
t1 = referringDocuments.filter((doc_0) => !drafts.includes(doc_0._id)), $[0] = referringDocuments, $[1] = t1;
|
|
36146
36146
|
} else
|
|
36147
36147
|
t1 = $[1];
|
|
@@ -36157,7 +36157,7 @@ function AssetUsageDialog(t0) {
|
|
|
36157
36157
|
let t4;
|
|
36158
36158
|
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;
|
|
36159
36159
|
}
|
|
36160
|
-
function _temp$
|
|
36160
|
+
function _temp$2x(acc, doc) {
|
|
36161
36161
|
return doc._id.startsWith("drafts.") ? acc.concat(doc._id.slice(7)) : acc;
|
|
36162
36162
|
}
|
|
36163
36163
|
const MIME_TYPES = {
|
|
@@ -36436,7 +36436,7 @@ const CardIconWrapper = styled.span`
|
|
|
36436
36436
|
const handleToggleUsageDialog = t9;
|
|
36437
36437
|
let t10;
|
|
36438
36438
|
$[22] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t10 = () => {
|
|
36439
|
-
setIsOpen(_temp$
|
|
36439
|
+
setIsOpen(_temp$2w);
|
|
36440
36440
|
}, $[22] = t10) : t10 = $[22];
|
|
36441
36441
|
const handleToggleOpen = t10;
|
|
36442
36442
|
let t11;
|
|
@@ -36552,7 +36552,7 @@ const CardIconWrapper = styled.span`
|
|
|
36552
36552
|
t27
|
|
36553
36553
|
] }), $[100] = asset, $[101] = isSelected, $[102] = t26, $[103] = t27, $[104] = t28) : t28 = $[104], t28;
|
|
36554
36554
|
};
|
|
36555
|
-
function _temp$
|
|
36555
|
+
function _temp$2w(prev) {
|
|
36556
36556
|
return !prev;
|
|
36557
36557
|
}
|
|
36558
36558
|
const STYLES_FILENAME = {
|
|
@@ -36822,7 +36822,7 @@ const PER_PAGE = 200, ASSET_TYPE_IMAGE = "sanity.imageAsset", ASSET_TYPE_FILE =
|
|
|
36822
36822
|
$[0] !== client ? (t0 = client.withConfig({
|
|
36823
36823
|
apiVersion: "2023-02-14"
|
|
36824
36824
|
}), $[0] = client, $[1] = t0) : t0 = $[1];
|
|
36825
|
-
const versionedClient2 = t0, [_elementId] = useState(_temp$
|
|
36825
|
+
const versionedClient2 = t0, [_elementId] = useState(_temp$2v), currentPageNumber = useRef(0), {
|
|
36826
36826
|
t
|
|
36827
36827
|
} = useTranslation(), fetch$ = useRef(void 0);
|
|
36828
36828
|
let t1;
|
|
@@ -36909,7 +36909,7 @@ const PER_PAGE = 200, ASSET_TYPE_IMAGE = "sanity.imageAsset", ASSET_TYPE_FILE =
|
|
|
36909
36909
|
$[30] !== accept || $[31] !== isImageOnlyWildCard || $[32] !== isLoading || $[33] !== listFormat || $[34] !== t ? (t16 = !isImageOnlyWildCard && !isLoading && accept?.length > 0 && /* @__PURE__ */ jsx(Card, { tone: "primary", padding: 3, border: !0, radius: 2, children: /* @__PURE__ */ jsxs(Flex, { gap: 3, align: "center", children: [
|
|
36910
36910
|
/* @__PURE__ */ jsx(Text$1, { size: 1, children: /* @__PURE__ */ jsx(InfoOutlineIcon, {}) }),
|
|
36911
36911
|
/* @__PURE__ */ jsx(Text$1, { size: 1, children: /* @__PURE__ */ jsx(Translate, { t, i18nKey: "asset-source.dialog.accept-message", values: {
|
|
36912
|
-
acceptTypes: listFormat.format(accept.split(",").map(_temp2$
|
|
36912
|
+
acceptTypes: listFormat.format(accept.split(",").map(_temp2$12))
|
|
36913
36913
|
} }) })
|
|
36914
36914
|
] }) }), $[30] = accept, $[31] = isImageOnlyWildCard, $[32] = isLoading, $[33] = listFormat, $[34] = t, $[35] = t16) : t16 = $[35];
|
|
36915
36915
|
let t17;
|
|
@@ -36928,10 +36928,10 @@ const PER_PAGE = 200, ASSET_TYPE_IMAGE = "sanity.imageAsset", ASSET_TYPE_FILE =
|
|
|
36928
36928
|
let t21;
|
|
36929
36929
|
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;
|
|
36930
36930
|
}, SelectAssetsDialog$1 = memo(forwardRef(SelectAssetsComponent));
|
|
36931
|
-
function _temp$
|
|
36931
|
+
function _temp$2v() {
|
|
36932
36932
|
return `default-asset-source-${uniqueId()}`;
|
|
36933
36933
|
}
|
|
36934
|
-
function _temp2$
|
|
36934
|
+
function _temp2$12(type) {
|
|
36935
36935
|
return type.trim();
|
|
36936
36936
|
}
|
|
36937
36937
|
const DatasetAssetSourceComponent = function(props2, ref) {
|
|
@@ -37387,7 +37387,7 @@ function UploadPlaceholderComponent(props2) {
|
|
|
37387
37387
|
} = useTranslation(), client = useClient(DEFAULT_STUDIO_CLIENT_OPTIONS), source = useSource();
|
|
37388
37388
|
let result;
|
|
37389
37389
|
if ($[0] !== assetSources || $[1] !== client || $[2] !== source || $[3] !== type) {
|
|
37390
|
-
if (result = assetSources.filter(_temp$
|
|
37390
|
+
if (result = assetSources.filter(_temp$2u), result.length === 0) {
|
|
37391
37391
|
const options = {
|
|
37392
37392
|
client,
|
|
37393
37393
|
title: source.title || source.name
|
|
@@ -37439,7 +37439,7 @@ function UploadPlaceholderComponent(props2) {
|
|
|
37439
37439
|
] })
|
|
37440
37440
|
] }), $[26] = assetSourcesWithUpload.length, $[27] = browse, $[28] = collapsed, $[29] = directUploads, $[30] = hoveringFiles, $[31] = readOnly, $[32] = type, $[33] = uploadButton, $[34] = t3) : t3 = $[34], t3;
|
|
37441
37441
|
}
|
|
37442
|
-
function _temp$
|
|
37442
|
+
function _temp$2u(s) {
|
|
37443
37443
|
return !!s.Uploader;
|
|
37444
37444
|
}
|
|
37445
37445
|
const UploadPlaceholder = memo(UploadPlaceholderComponent), STALE_UPLOAD_MS = 12e4, RatioBox$2 = styled(Card)`
|
|
@@ -37837,7 +37837,7 @@ function FilePreview$1(props2) {
|
|
|
37837
37837
|
$[0] !== schemaType ? (t0 = get(schemaType, "options.accept", ""), $[0] = schemaType, $[1] = t0) : t0 = $[1];
|
|
37838
37838
|
const accept = t0;
|
|
37839
37839
|
let t1;
|
|
37840
|
-
$[2] !== assetSources ? (t1 = assetSources.filter(_temp$
|
|
37840
|
+
$[2] !== assetSources ? (t1 = assetSources.filter(_temp$2t), $[2] = assetSources, $[3] = t1) : t1 = $[3];
|
|
37841
37841
|
const assetSourcesWithUpload = t1;
|
|
37842
37842
|
let t2;
|
|
37843
37843
|
$[4] !== assetSources || $[5] !== setSelectedAssetSource ? (t2 = (event) => {
|
|
@@ -37922,7 +37922,7 @@ function FilePreview$1(props2) {
|
|
|
37922
37922
|
let t9;
|
|
37923
37923
|
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;
|
|
37924
37924
|
}
|
|
37925
|
-
function _temp$
|
|
37925
|
+
function _temp$2t(s) {
|
|
37926
37926
|
return !!s.Uploader;
|
|
37927
37927
|
}
|
|
37928
37928
|
function InvalidFileWarning(t0) {
|
|
@@ -38183,7 +38183,7 @@ function BaseFileInput(props2) {
|
|
|
38183
38183
|
break bb68;
|
|
38184
38184
|
}
|
|
38185
38185
|
case "error": {
|
|
38186
|
-
event.files.forEach(_temp$
|
|
38186
|
+
event.files.forEach(_temp$2s), push({
|
|
38187
38187
|
status: "error",
|
|
38188
38188
|
description: t("asset-sources.common.uploader.upload-failed.description"),
|
|
38189
38189
|
title: t("asset-sources.common.uploader.upload-failed.title")
|
|
@@ -38191,7 +38191,7 @@ function BaseFileInput(props2) {
|
|
|
38191
38191
|
break bb68;
|
|
38192
38192
|
}
|
|
38193
38193
|
case "all-complete": {
|
|
38194
|
-
event.files.some(_temp2$
|
|
38194
|
+
event.files.some(_temp2$11) && handleAssetLimitUpsellDialog("field_action"), onChange(PatchEvent.from([unset([UPLOAD_STATUS_KEY])]));
|
|
38195
38195
|
break bb68;
|
|
38196
38196
|
}
|
|
38197
38197
|
default:
|
|
@@ -38241,10 +38241,10 @@ function BaseFileInput(props2) {
|
|
|
38241
38241
|
t14
|
|
38242
38242
|
] }), $[79] = t13, $[80] = t14, $[81] = t15) : t15 = $[81], t15;
|
|
38243
38243
|
}
|
|
38244
|
-
function _temp2$
|
|
38244
|
+
function _temp2$11(file_0) {
|
|
38245
38245
|
return file_0.status === "error" && isAssetLimitError(file_0.error);
|
|
38246
38246
|
}
|
|
38247
|
-
function _temp$
|
|
38247
|
+
function _temp$2s(file_1) {
|
|
38248
38248
|
console.error(file_1.error);
|
|
38249
38249
|
}
|
|
38250
38250
|
function StudioFileInput(props2) {
|
|
@@ -38464,7 +38464,7 @@ function ImageInputAssetMenuWithReferenceAssetComponent(props2) {
|
|
|
38464
38464
|
$[0] !== documentId || $[1] !== observeAsset ? (t0 = observeAsset(documentId), $[0] = documentId, $[1] = observeAsset, $[2] = t0) : t0 = $[2];
|
|
38465
38465
|
const asset = useObservable(t0);
|
|
38466
38466
|
let t1;
|
|
38467
|
-
$[3] !== assetSources ? (t1 = assetSources.filter(_temp$
|
|
38467
|
+
$[3] !== assetSources ? (t1 = assetSources.filter(_temp$2r), $[3] = assetSources, $[4] = t1) : t1 = $[4];
|
|
38468
38468
|
const assetSourcesWithUpload = t1;
|
|
38469
38469
|
let t2;
|
|
38470
38470
|
$[5] !== onSelectFile ? (t2 = (assetSource, files) => {
|
|
@@ -38519,7 +38519,7 @@ function ImageInputAssetMenuWithReferenceAssetComponent(props2) {
|
|
|
38519
38519
|
let t6;
|
|
38520
38520
|
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;
|
|
38521
38521
|
}
|
|
38522
|
-
function _temp$
|
|
38522
|
+
function _temp$2r(s) {
|
|
38523
38523
|
return !!s.Uploader;
|
|
38524
38524
|
}
|
|
38525
38525
|
const ImageInputAssetMenuWithReferenceAsset = memo(ImageInputAssetMenuWithReferenceAssetComponent);
|
|
@@ -39695,7 +39695,7 @@ function ToolSVGComponent(props2) {
|
|
|
39695
39695
|
const svgElement = svgRef.current;
|
|
39696
39696
|
if (!svgElement)
|
|
39697
39697
|
return;
|
|
39698
|
-
const handleTouchMove = _temp$
|
|
39698
|
+
const handleTouchMove = _temp$2q;
|
|
39699
39699
|
return svgElement.addEventListener("touchmove", handleTouchMove, {
|
|
39700
39700
|
passive: !1
|
|
39701
39701
|
}), () => {
|
|
@@ -39946,7 +39946,7 @@ function ToolSVGComponent(props2) {
|
|
|
39946
39946
|
t83
|
|
39947
39947
|
] }) }), $[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;
|
|
39948
39948
|
}
|
|
39949
|
-
function _temp$
|
|
39949
|
+
function _temp$2q(e) {
|
|
39950
39950
|
e.preventDefault();
|
|
39951
39951
|
}
|
|
39952
39952
|
const ToolSVG = memo(ToolSVGComponent);
|
|
@@ -40093,7 +40093,7 @@ function ImageToolInput(props2) {
|
|
|
40093
40093
|
$[8] !== onChange || $[9] !== readOnly || $[10] !== schemaType.fields ? (t7 = (finalValue) => {
|
|
40094
40094
|
if (readOnly)
|
|
40095
40095
|
return;
|
|
40096
|
-
const cropField = schemaType.fields.find(_temp$
|
|
40096
|
+
const cropField = schemaType.fields.find(_temp$2p), hotspotField = schemaType.fields.find(_temp2$10), crop = cropField ? {
|
|
40097
40097
|
_type: cropField.type.name,
|
|
40098
40098
|
...finalValue.crop || DEFAULT_CROP
|
|
40099
40099
|
} : finalValue.crop, hotspot = hotspotField ? {
|
|
@@ -40117,7 +40117,7 @@ function ImageToolInput(props2) {
|
|
|
40117
40117
|
$[18] !== isSvg || $[19] !== t ? (t12 = isSvg ? /* @__PURE__ */ jsx(Fragment$1, { children: /* @__PURE__ */ jsx(Card, { padding: 3, marginY: 3, tone: "caution", radius: 2, children: /* @__PURE__ */ jsxs(Stack, { space: 4, children: [
|
|
40118
40118
|
/* @__PURE__ */ jsx(Text$1, { size: 1, children: t("inputs.imagetool.vector-warning.title") }),
|
|
40119
40119
|
/* @__PURE__ */ jsx(Details, { title: t("inputs.imagetool.vector-warning.expand-developer-info"), children: /* @__PURE__ */ jsx(Text$1, { size: 1, children: /* @__PURE__ */ jsx(Translate, { t, i18nKey: "inputs.imagetool.vector-warning.developer-info", components: {
|
|
40120
|
-
ImageUrlDocumentationLink: _temp3$
|
|
40120
|
+
ImageUrlDocumentationLink: _temp3$v,
|
|
40121
40121
|
ImageUrlPackageDocumentationLink: _temp4$d
|
|
40122
40122
|
} }) }) })
|
|
40123
40123
|
] }) }) }) : null, $[18] = isSvg, $[19] = t, $[20] = t12) : t12 = $[20];
|
|
@@ -40167,16 +40167,16 @@ function _temp4$d(t0) {
|
|
|
40167
40167
|
} = t0;
|
|
40168
40168
|
return /* @__PURE__ */ jsx("a", { href: "https://www.sanity.io/docs/image-urls#fm-048ba39d9e88", children: /* @__PURE__ */ jsx("code", { children: children_0 }) });
|
|
40169
40169
|
}
|
|
40170
|
-
function _temp3$
|
|
40170
|
+
function _temp3$v(t0) {
|
|
40171
40171
|
const {
|
|
40172
40172
|
children
|
|
40173
40173
|
} = t0;
|
|
40174
40174
|
return /* @__PURE__ */ jsx("a", { href: "https://www.sanity.io/docs/image-urls#fm-048ba39d9e88", children });
|
|
40175
40175
|
}
|
|
40176
|
-
function _temp2
|
|
40176
|
+
function _temp2$10(field_0) {
|
|
40177
40177
|
return field_0.type.name !== "object" && field_0.name === "hotspot";
|
|
40178
40178
|
}
|
|
40179
|
-
function _temp$
|
|
40179
|
+
function _temp$2p(field) {
|
|
40180
40180
|
return field.name === "crop" && field.type.name !== "object";
|
|
40181
40181
|
}
|
|
40182
40182
|
function ImageInputHotspotInput(props2) {
|
|
@@ -40439,7 +40439,7 @@ function BaseImageInputComponent(props2) {
|
|
|
40439
40439
|
const handleClearField = t5;
|
|
40440
40440
|
let t6;
|
|
40441
40441
|
$[19] !== onChange || $[20] !== value || $[21] !== valueIsArrayElement ? (t6 = () => {
|
|
40442
|
-
const allKeys = Object.keys(value || {}), isEmpty2 = allKeys.filter(_temp$
|
|
40442
|
+
const allKeys = Object.keys(value || {}), isEmpty2 = allKeys.filter(_temp$2o).length === 0, removeKeys = ["asset", "media"].concat(allKeys.filter(_temp2$$)).map(_temp3$u);
|
|
40443
40443
|
onChange(isEmpty2 && !valueIsArrayElement() ? unset() : removeKeys);
|
|
40444
40444
|
}, $[19] = onChange, $[20] = value, $[21] = valueIsArrayElement, $[22] = t6) : t6 = $[22];
|
|
40445
40445
|
const handleRemoveButtonClick = t6;
|
|
@@ -40593,13 +40593,13 @@ function _temp5$8(eventFile) {
|
|
|
40593
40593
|
function _temp4$c(eventFile_0) {
|
|
40594
40594
|
console.error(eventFile_0.error);
|
|
40595
40595
|
}
|
|
40596
|
-
function _temp3$
|
|
40596
|
+
function _temp3$u(key_1) {
|
|
40597
40597
|
return unset([key_1]);
|
|
40598
40598
|
}
|
|
40599
|
-
function _temp2
|
|
40599
|
+
function _temp2$$(key_0) {
|
|
40600
40600
|
return ["crop", "hotspot", "_upload"].includes(key_0);
|
|
40601
40601
|
}
|
|
40602
|
-
function _temp$
|
|
40602
|
+
function _temp$2o(key) {
|
|
40603
40603
|
return !["_type", "_key", "_upload", "asset", "crop", "hotspot", "media"].includes(key);
|
|
40604
40604
|
}
|
|
40605
40605
|
const BaseImageInput = memo(BaseImageInputComponent);
|
|
@@ -40884,11 +40884,11 @@ function TagsArrayInput(props2) {
|
|
|
40884
40884
|
$[0] !== t0 ? (t1 = t0 === void 0 ? [] : t0, $[0] = t0, $[1] = t1) : t1 = $[1];
|
|
40885
40885
|
const value = t1;
|
|
40886
40886
|
let t2;
|
|
40887
|
-
$[2] !== value ? (t2 = value?.map(_temp$
|
|
40887
|
+
$[2] !== value ? (t2 = value?.map(_temp$2n), $[2] = value, $[3] = t2) : t2 = $[3];
|
|
40888
40888
|
const tagInputValue = t2;
|
|
40889
40889
|
let t3;
|
|
40890
40890
|
$[4] !== onChange ? (t3 = (nextValue) => {
|
|
40891
|
-
onChange(nextValue.length === 0 ? unset() : set(nextValue.map(_temp2$
|
|
40891
|
+
onChange(nextValue.length === 0 ? unset() : set(nextValue.map(_temp2$_)));
|
|
40892
40892
|
}, $[4] = onChange, $[5] = t3) : t3 = $[5];
|
|
40893
40893
|
const handleChange = t3;
|
|
40894
40894
|
let t4;
|
|
@@ -40896,10 +40896,10 @@ function TagsArrayInput(props2) {
|
|
|
40896
40896
|
let t5;
|
|
40897
40897
|
return $[11] !== changed || $[12] !== path || $[13] !== t4 ? (t5 = /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: !1, children: t4 }), $[11] = changed, $[12] = path, $[13] = t4, $[14] = t5) : t5 = $[14], t5;
|
|
40898
40898
|
}
|
|
40899
|
-
function _temp2$
|
|
40899
|
+
function _temp2$_(v_0) {
|
|
40900
40900
|
return v_0.value;
|
|
40901
40901
|
}
|
|
40902
|
-
function _temp$
|
|
40902
|
+
function _temp$2n(v) {
|
|
40903
40903
|
return {
|
|
40904
40904
|
value: v
|
|
40905
40905
|
};
|
|
@@ -40976,11 +40976,11 @@ function SelectInput(props2) {
|
|
|
40976
40976
|
}
|
|
40977
40977
|
handleChange(nextItem_0);
|
|
40978
40978
|
}, $[12] = handleChange, $[13] = itemFromOptionValue, $[14] = t6) : t6 = $[14];
|
|
40979
|
-
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$
|
|
40979
|
+
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;
|
|
40980
40980
|
let t8;
|
|
40981
40981
|
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;
|
|
40982
40982
|
}
|
|
40983
|
-
function _temp$
|
|
40983
|
+
function _temp$2m(item_1, i) {
|
|
40984
40984
|
return /* @__PURE__ */ jsx("option", { value: i - 1, children: item_1.title }, `${i - 1}`);
|
|
40985
40985
|
}
|
|
40986
40986
|
const RadioSelect = forwardRef(function(props2, ref) {
|
|
@@ -41132,7 +41132,7 @@ function PreviewItem(props2) {
|
|
|
41132
41132
|
const presence = t7, childValidation = useChildValidation(path, !0);
|
|
41133
41133
|
let t8;
|
|
41134
41134
|
$[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];
|
|
41135
|
-
const validation2 = t8, hasErrors = childValidation.some(_temp$
|
|
41135
|
+
const validation2 = t8, hasErrors = childValidation.some(_temp$2l), hasWarnings = childValidation.some(_temp2$Z), [contextMenuButtonElement, setContextMenuButtonElement] = useState(null), t9 = parentSchemaType.options?.insertMenu;
|
|
41136
41136
|
let t10;
|
|
41137
41137
|
$[16] !== contextMenuButtonElement || $[17] !== handleInsert || $[18] !== insertableTypes || $[19] !== t9 ? (t10 = {
|
|
41138
41138
|
schemaTypes: insertableTypes,
|
|
@@ -41210,10 +41210,10 @@ function PreviewItem(props2) {
|
|
|
41210
41210
|
t23 = $[88];
|
|
41211
41211
|
return t23;
|
|
41212
41212
|
}
|
|
41213
|
-
function _temp2$
|
|
41213
|
+
function _temp2$Z(v_0) {
|
|
41214
41214
|
return v_0.level === "warning";
|
|
41215
41215
|
}
|
|
41216
|
-
function _temp$
|
|
41216
|
+
function _temp$2l(v) {
|
|
41217
41217
|
return v.level === "error";
|
|
41218
41218
|
}
|
|
41219
41219
|
function ReferenceItemRefProvider(props2) {
|
|
@@ -41285,7 +41285,7 @@ function ReferenceItem(props2) {
|
|
|
41285
41285
|
$[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = (hadFocus, hasFocus) => {
|
|
41286
41286
|
!hadFocus && hasFocus && elementRef.current && elementRef.current?.focus();
|
|
41287
41287
|
}, $[4] = t2) : t2 = $[4], useDidUpdate(focused, t2);
|
|
41288
|
-
const hasErrors = props2.validation.some(_temp$
|
|
41288
|
+
const hasErrors = props2.validation.some(_temp$2k), hasWarnings = props2.validation.some(_temp2$Y), resolvingInitialValue = value._resolvingInitialValue;
|
|
41289
41289
|
let t3;
|
|
41290
41290
|
$[5] !== onInsert || $[6] !== value ? (t3 = () => {
|
|
41291
41291
|
onInsert({
|
|
@@ -41419,10 +41419,10 @@ function ReferenceItem(props2) {
|
|
|
41419
41419
|
let t27;
|
|
41420
41420
|
return $[98] !== changed || $[99] !== path || $[100] !== t25 || $[101] !== t26 ? (t27 = /* @__PURE__ */ jsx(ChangeIndicator, { path, isChanged: changed, hasFocus: t25, children: t26 }), $[98] = changed, $[99] = path, $[100] = t25, $[101] = t26, $[102] = t27) : t27 = $[102], t27;
|
|
41421
41421
|
}
|
|
41422
|
-
function _temp2$
|
|
41422
|
+
function _temp2$Y(v_0) {
|
|
41423
41423
|
return v_0.level === "warning";
|
|
41424
41424
|
}
|
|
41425
|
-
function _temp$
|
|
41425
|
+
function _temp$2k(v) {
|
|
41426
41426
|
return v.level === "error";
|
|
41427
41427
|
}
|
|
41428
41428
|
function defaultResolveItemComponent(schemaType) {
|
|
@@ -42473,14 +42473,14 @@ function useVisibility(props2) {
|
|
|
42473
42473
|
if (!element || disabled)
|
|
42474
42474
|
return;
|
|
42475
42475
|
element && "checkVisibility" in element && setVisible(element.checkVisibility());
|
|
42476
|
-
const isDocumentVisible$ = concat(of(!document.hidden), visibilityChange$.pipe(map(_temp$
|
|
42476
|
+
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);
|
|
42477
42477
|
return () => sub2.unsubscribe();
|
|
42478
42478
|
}, t2 = [element, hideDelay, disabled], $[0] = disabled, $[1] = element, $[2] = hideDelay, $[3] = t1, $[4] = t2) : (t1 = $[3], t2 = $[4]), useLayoutEffect(t1, t2), disabled ? !1 : visible;
|
|
42479
42479
|
}
|
|
42480
|
-
function _temp2$
|
|
42480
|
+
function _temp2$X(event_0) {
|
|
42481
42481
|
return event_0.isIntersecting;
|
|
42482
42482
|
}
|
|
42483
|
-
function _temp$
|
|
42483
|
+
function _temp$2j(event) {
|
|
42484
42484
|
return event.target instanceof Document ? !event?.target?.hidden : !1;
|
|
42485
42485
|
}
|
|
42486
42486
|
const _HIDE_DELAY = 2e3;
|
|
@@ -42634,7 +42634,7 @@ function FormBuilderProvider(props2) {
|
|
|
42634
42634
|
assetSources: file.assetSources,
|
|
42635
42635
|
directUploads: t6
|
|
42636
42636
|
}, $[5] = file.assetSources, $[6] = t6, $[7] = t7) : t7 = $[7];
|
|
42637
|
-
const t8 = filterField || _temp$
|
|
42637
|
+
const t8 = filterField || _temp$2i, t9 = image?.directUploads !== !1;
|
|
42638
42638
|
let t10;
|
|
42639
42639
|
$[8] !== image.assetSources || $[9] !== t9 ? (t10 = {
|
|
42640
42640
|
assetSources: image.assetSources,
|
|
@@ -42686,7 +42686,7 @@ function FormBuilderProvider(props2) {
|
|
|
42686
42686
|
let t18;
|
|
42687
42687
|
return $[58] !== formBuilder || $[59] !== t17 ? (t18 = /* @__PURE__ */ jsx(FormBuilderContext.Provider, { value: formBuilder, children: t17 }), $[58] = formBuilder, $[59] = t17, $[60] = t18) : t18 = $[60], t18;
|
|
42688
42688
|
}
|
|
42689
|
-
function _temp$
|
|
42689
|
+
function _temp$2i() {
|
|
42690
42690
|
return !0;
|
|
42691
42691
|
}
|
|
42692
42692
|
function FormProvider(props2) {
|
|
@@ -42841,7 +42841,7 @@ function FormBuilder(props2) {
|
|
|
42841
42841
|
}, $[40] = handleBlur, $[41] = handleFocus, $[42] = id2, $[43] = t19) : t19 = $[43];
|
|
42842
42842
|
const t20 = diffProps.__unstable_computeDiff;
|
|
42843
42843
|
let t21;
|
|
42844
|
-
$[44] !== members ? (t21 = members.some(_temp$
|
|
42844
|
+
$[44] !== members ? (t21 = members.some(_temp$2h), $[44] = members, $[45] = t21) : t21 = $[45];
|
|
42845
42845
|
let t22;
|
|
42846
42846
|
$[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 = {
|
|
42847
42847
|
focusPath,
|
|
@@ -42893,7 +42893,7 @@ function FormBuilder(props2) {
|
|
|
42893
42893
|
let t29;
|
|
42894
42894
|
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;
|
|
42895
42895
|
}
|
|
42896
|
-
function _temp$
|
|
42896
|
+
function _temp$2h(m) {
|
|
42897
42897
|
return m.kind === "field" && m.field.changed;
|
|
42898
42898
|
}
|
|
42899
42899
|
function RootInput(props2) {
|
|
@@ -43328,7 +43328,7 @@ const DefaultBlockObjectComponent = (props2) => {
|
|
|
43328
43328
|
validation: validation2
|
|
43329
43329
|
} = props2, {
|
|
43330
43330
|
t
|
|
43331
|
-
} = useTranslation(), isImagePreview = isImage(value), hasError = validation2.filter(_temp$
|
|
43331
|
+
} = 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;
|
|
43332
43332
|
let t0;
|
|
43333
43333
|
$[0] !== onOpen ? (t0 = (e) => {
|
|
43334
43334
|
e.preventDefault(), e.stopPropagation(), onOpen();
|
|
@@ -43359,10 +43359,10 @@ const DefaultBlockObjectComponent = (props2) => {
|
|
|
43359
43359
|
t14
|
|
43360
43360
|
] }), $[40] = t13, $[41] = t14, $[42] = t15) : t15 = $[42], t15;
|
|
43361
43361
|
};
|
|
43362
|
-
function _temp$
|
|
43362
|
+
function _temp$2g(v) {
|
|
43363
43363
|
return v.level === "error";
|
|
43364
43364
|
}
|
|
43365
|
-
function _temp2$
|
|
43365
|
+
function _temp2$W(v_0) {
|
|
43366
43366
|
return v_0.level === "warning";
|
|
43367
43367
|
}
|
|
43368
43368
|
function defaultResolveBlockComponent(schemaType) {
|
|
@@ -44299,9 +44299,9 @@ const INITIAL_STATE$6 = {
|
|
|
44299
44299
|
function useObserveDocument(documentId, apiConfig) {
|
|
44300
44300
|
const $ = c(4), documentPreviewStore = useDocumentPreviewStore();
|
|
44301
44301
|
let t0;
|
|
44302
|
-
return $[0] !== apiConfig || $[1] !== documentId || $[2] !== documentPreviewStore ? (t0 = documentPreviewStore.unstable_observeDocument(documentId, apiConfig).pipe(map(_temp$
|
|
44302
|
+
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);
|
|
44303
44303
|
}
|
|
44304
|
-
function _temp$
|
|
44304
|
+
function _temp$2f(document2) {
|
|
44305
44305
|
return {
|
|
44306
44306
|
loading: !1,
|
|
44307
44307
|
document: document2
|
|
@@ -44345,14 +44345,14 @@ function getPreviewValueWithFallback({
|
|
|
44345
44345
|
function useReleasesIds(releases2) {
|
|
44346
44346
|
const $ = c(4);
|
|
44347
44347
|
let t0;
|
|
44348
|
-
$[0] !== releases2 ? (t0 = releases2.map(_temp$
|
|
44348
|
+
$[0] !== releases2 ? (t0 = releases2.map(_temp$2e), $[0] = releases2, $[1] = t0) : t0 = $[1];
|
|
44349
44349
|
const releasesIds = t0;
|
|
44350
44350
|
let t1;
|
|
44351
44351
|
return $[2] !== releasesIds ? (t1 = {
|
|
44352
44352
|
releasesIds
|
|
44353
44353
|
}, $[2] = releasesIds, $[3] = t1) : t1 = $[3], t1;
|
|
44354
44354
|
}
|
|
44355
|
-
function _temp$
|
|
44355
|
+
function _temp$2e(release) {
|
|
44356
44356
|
return getReleaseIdFromReleaseDocumentId(release._id);
|
|
44357
44357
|
}
|
|
44358
44358
|
function exists(value) {
|
|
@@ -44372,15 +44372,15 @@ function useDocumentVersionInfo(documentId) {
|
|
|
44372
44372
|
if ($[7] !== documentPreviewStore || $[8] !== draftId || $[9] !== publishedId || $[10] !== releaseIds) {
|
|
44373
44373
|
const releaseVersions = releaseIds.length > 0 ? combineLatest(Object.fromEntries(releaseIds.map((releaseId) => [releaseId, documentPreviewStore.observePaths({
|
|
44374
44374
|
_id: getVersionId(publishedId, releaseId)
|
|
44375
|
-
}, DOCUMENT_STUB_PATHS).pipe(map(_temp$
|
|
44375
|
+
}, DOCUMENT_STUB_PATHS).pipe(map(_temp$2d))]))) : of(NO_VERSIONS);
|
|
44376
44376
|
t3 = combineLatest({
|
|
44377
44377
|
isLoading: of(!1),
|
|
44378
44378
|
draft: documentPreviewStore.observePaths({
|
|
44379
44379
|
_id: draftId
|
|
44380
|
-
}, DOCUMENT_STUB_PATHS).pipe(map(_temp2$
|
|
44380
|
+
}, DOCUMENT_STUB_PATHS).pipe(map(_temp2$V)),
|
|
44381
44381
|
published: documentPreviewStore.observePaths({
|
|
44382
44382
|
_id: publishedId
|
|
44383
|
-
}, DOCUMENT_STUB_PATHS).pipe(map(_temp3$
|
|
44383
|
+
}, DOCUMENT_STUB_PATHS).pipe(map(_temp3$t)),
|
|
44384
44384
|
versions: releaseVersions
|
|
44385
44385
|
}), $[7] = documentPreviewStore, $[8] = draftId, $[9] = publishedId, $[10] = releaseIds, $[11] = t3;
|
|
44386
44386
|
} else
|
|
@@ -44394,13 +44394,13 @@ function useDocumentVersionInfo(documentId) {
|
|
|
44394
44394
|
published: void 0
|
|
44395
44395
|
}, $[12] = t4) : t4 = $[12], useObservable(observable, t4);
|
|
44396
44396
|
}
|
|
44397
|
-
function _temp3$
|
|
44397
|
+
function _temp3$t(value_1) {
|
|
44398
44398
|
return exists(value_1) ? value_1 : void 0;
|
|
44399
44399
|
}
|
|
44400
|
-
function _temp2$
|
|
44400
|
+
function _temp2$V(value_0) {
|
|
44401
44401
|
return exists(value_0) ? value_0 : void 0;
|
|
44402
44402
|
}
|
|
44403
|
-
function _temp$
|
|
44403
|
+
function _temp$2d(value) {
|
|
44404
44404
|
return exists(value) ? value : void 0;
|
|
44405
44405
|
}
|
|
44406
44406
|
function useCopyToDrafts(options) {
|
|
@@ -44537,7 +44537,7 @@ const orderedReleaseTypes$1 = ["asap", "scheduled", "undecided"], useDocumentVer
|
|
|
44537
44537
|
_id
|
|
44538
44538
|
} = t4;
|
|
44539
44539
|
return documentVersions.some((id2) => getVersionFromId(id2) === getReleaseIdFromReleaseDocumentId(_id));
|
|
44540
|
-
}, $[5] = documentVersions, $[6] = t32) : t32 = $[6], t2 = releases2.filter(t32).sort(_temp$
|
|
44540
|
+
}, $[5] = documentVersions, $[6] = t32) : t32 = $[6], t2 = releases2.filter(t32).sort(_temp$2c), $[2] = documentVersions, $[3] = releases2, $[4] = t2;
|
|
44541
44541
|
} else
|
|
44542
44542
|
t2 = $[4];
|
|
44543
44543
|
const sortedDocumentList = t2;
|
|
@@ -44546,7 +44546,7 @@ const orderedReleaseTypes$1 = ["asap", "scheduled", "undecided"], useDocumentVer
|
|
|
44546
44546
|
sortedDocumentList
|
|
44547
44547
|
}, $[7] = sortedDocumentList, $[8] = t3) : t3 = $[8], t3;
|
|
44548
44548
|
};
|
|
44549
|
-
function _temp$
|
|
44549
|
+
function _temp$2c(releasesList, compareReleasesList) {
|
|
44550
44550
|
if (releasesList.metadata.releaseType === "scheduled" && compareReleasesList.metadata.releaseType === "scheduled") {
|
|
44551
44551
|
const aPublishAt = releasesList.publishAt || releasesList.metadata.intendedPublishAt;
|
|
44552
44552
|
if (!aPublishAt)
|
|
@@ -44574,9 +44574,9 @@ const useIsReleaseActive = () => {
|
|
|
44574
44574
|
data: documentVersions
|
|
44575
44575
|
} = useDocumentVersions(t1);
|
|
44576
44576
|
let t2;
|
|
44577
|
-
return $[2] !== documentVersions ? (t2 = documentVersions && documentVersions.length > 0 && !documentVersions.some(_temp$
|
|
44577
|
+
return $[2] !== documentVersions ? (t2 = documentVersions && documentVersions.length > 0 && !documentVersions.some(_temp$2b), $[2] = documentVersions, $[3] = t2) : t2 = $[3], t2;
|
|
44578
44578
|
};
|
|
44579
|
-
function _temp$
|
|
44579
|
+
function _temp$2b(version2) {
|
|
44580
44580
|
return !isVersionId(version2);
|
|
44581
44581
|
}
|
|
44582
44582
|
function useGetDefaultPerspective() {
|
|
@@ -44875,7 +44875,7 @@ const Z_OFFSET$1 = {
|
|
|
44875
44875
|
type: "contentReleases"
|
|
44876
44876
|
}, RELEASE_FORM_STORAGE_KEY = "studio.release-form.recovery";
|
|
44877
44877
|
function useReleaseFormStorage() {
|
|
44878
|
-
const $ = c(1), getStoredReleaseData = _temp$
|
|
44878
|
+
const $ = c(1), getStoredReleaseData = _temp$2a, saveReleaseDataToStorage = _temp2$U, clearReleaseDataFromStorage = _temp3$s;
|
|
44879
44879
|
let t0;
|
|
44880
44880
|
return $[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
|
|
44881
44881
|
getStoredReleaseData,
|
|
@@ -44883,13 +44883,13 @@ function useReleaseFormStorage() {
|
|
|
44883
44883
|
clearReleaseDataFromStorage
|
|
44884
44884
|
}, $[0] = t0) : t0 = $[0], t0;
|
|
44885
44885
|
}
|
|
44886
|
-
function _temp3$
|
|
44886
|
+
function _temp3$s() {
|
|
44887
44887
|
localStorage.removeItem(RELEASE_FORM_STORAGE_KEY);
|
|
44888
44888
|
}
|
|
44889
|
-
function _temp2$
|
|
44889
|
+
function _temp2$U(data) {
|
|
44890
44890
|
localStorage.setItem(RELEASE_FORM_STORAGE_KEY, JSON.stringify(data));
|
|
44891
44891
|
}
|
|
44892
|
-
function _temp$
|
|
44892
|
+
function _temp$2a() {
|
|
44893
44893
|
const stored = localStorage.getItem(RELEASE_FORM_STORAGE_KEY);
|
|
44894
44894
|
return stored ? JSON.parse(stored) : void 0;
|
|
44895
44895
|
}
|
|
@@ -45110,7 +45110,7 @@ function TitleDescriptionForm(t0) {
|
|
|
45110
45110
|
$[2] !== release ? (t2 = {
|
|
45111
45111
|
externalValue: release,
|
|
45112
45112
|
id: release._id,
|
|
45113
|
-
extractData: _temp$
|
|
45113
|
+
extractData: _temp$29
|
|
45114
45114
|
}, $[2] = release, $[3] = t2) : t2 = $[3];
|
|
45115
45115
|
const {
|
|
45116
45116
|
localData,
|
|
@@ -45172,7 +45172,7 @@ function TitleDescriptionForm(t0) {
|
|
|
45172
45172
|
t12
|
|
45173
45173
|
] }), $[38] = t11, $[39] = t12, $[40] = t13) : t13 = $[40], t13;
|
|
45174
45174
|
}
|
|
45175
|
-
function _temp$
|
|
45175
|
+
function _temp$29(t0) {
|
|
45176
45176
|
const {
|
|
45177
45177
|
metadata
|
|
45178
45178
|
} = t0;
|
|
@@ -45451,7 +45451,7 @@ function InsufficientPermissionsMessage(t0) {
|
|
|
45451
45451
|
}, $[0] = t1) : t1 = $[0];
|
|
45452
45452
|
const list = useListFormat(t1), roles = currentUser?.roles || EMPTY_ARRAY$i;
|
|
45453
45453
|
let t2;
|
|
45454
|
-
$[1] !== list || $[2] !== roles ? (t2 = () => /* @__PURE__ */ jsx(Fragment$1, { children: list.formatToParts(roles.map(_temp$
|
|
45454
|
+
$[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];
|
|
45455
45455
|
const Roles = t2;
|
|
45456
45456
|
let t3;
|
|
45457
45457
|
$[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t3 = /* @__PURE__ */ jsx(Text$1, { size: 0, children: /* @__PURE__ */ jsx(AccessDeniedIcon, {}) }), $[4] = t3) : t3 = $[4];
|
|
@@ -45477,10 +45477,10 @@ function InsufficientPermissionsMessage(t0) {
|
|
|
45477
45477
|
t8
|
|
45478
45478
|
] }), $[17] = t5, $[18] = t6, $[19] = t8, $[20] = t9) : t9 = $[20], t9;
|
|
45479
45479
|
}
|
|
45480
|
-
function _temp2$
|
|
45480
|
+
function _temp2$T(i, index) {
|
|
45481
45481
|
return i.type === "element" ? /* @__PURE__ */ jsx("code", { children: i.value }, `${i.value}-${index}`) : /* @__PURE__ */ jsx(Fragment, { children: i.value }, `${i.value}-${index}`);
|
|
45482
45482
|
}
|
|
45483
|
-
function _temp$
|
|
45483
|
+
function _temp$28(role) {
|
|
45484
45484
|
return role.title || startCase(role.name);
|
|
45485
45485
|
}
|
|
45486
45486
|
const useDiscardVersionAction = (props2) => {
|
|
@@ -45570,7 +45570,7 @@ function useArchivedReleases() {
|
|
|
45570
45570
|
loading
|
|
45571
45571
|
} = useAllReleases();
|
|
45572
45572
|
let t0;
|
|
45573
|
-
$[0] !== releases2 ? (t0 = Array.from(releases2.values()).filter(_temp$
|
|
45573
|
+
$[0] !== releases2 ? (t0 = Array.from(releases2.values()).filter(_temp$27), $[0] = releases2, $[1] = t0) : t0 = $[1];
|
|
45574
45574
|
const archivedReleases = t0;
|
|
45575
45575
|
let t1;
|
|
45576
45576
|
return $[2] !== archivedReleases || $[3] !== error || $[4] !== loading ? (t1 = {
|
|
@@ -45579,7 +45579,7 @@ function useArchivedReleases() {
|
|
|
45579
45579
|
loading
|
|
45580
45580
|
}, $[2] = archivedReleases, $[3] = error, $[4] = loading, $[5] = t1) : t1 = $[5], t1;
|
|
45581
45581
|
}
|
|
45582
|
-
function _temp$
|
|
45582
|
+
function _temp$27(release) {
|
|
45583
45583
|
return ARCHIVED_RELEASE_STATES.includes(release.state);
|
|
45584
45584
|
}
|
|
45585
45585
|
function UnpublishVersionDialog(props2) {
|
|
@@ -45809,7 +45809,7 @@ const RELEASES_NAME = "sanity/releases", RELEASES_INTENT = "release", releases =
|
|
|
45809
45809
|
getMetadataStateForSlugs$
|
|
45810
45810
|
} = useReleasesStore(), [releasesMetadata, setReleasesMetadata] = useState(null);
|
|
45811
45811
|
let t2;
|
|
45812
|
-
$[1] !== getMetadataStateForSlugs$ || $[2] !== listenerReleaseIds ? (t2 = getMetadataStateForSlugs$(listenerReleaseIds.map(_temp$
|
|
45812
|
+
$[1] !== getMetadataStateForSlugs$ || $[2] !== listenerReleaseIds ? (t2 = getMetadataStateForSlugs$(listenerReleaseIds.map(_temp$26)), $[1] = getMetadataStateForSlugs$, $[2] = listenerReleaseIds, $[3] = t2) : t2 = $[3];
|
|
45813
45813
|
const observedResult = useObservable(t2) || DEFAULT_METADATA_STATE;
|
|
45814
45814
|
let t3, t4;
|
|
45815
45815
|
$[4] !== observedResult.data ? (t3 = () => setReleasesMetadata((prevReleaseMetadata) => observedResult.data ? {
|
|
@@ -45818,7 +45818,7 @@ const RELEASES_NAME = "sanity/releases", RELEASES_INTENT = "release", releases =
|
|
|
45818
45818
|
} : prevReleaseMetadata), t4 = [observedResult.data], $[4] = observedResult.data, $[5] = t3, $[6] = t4) : (t3 = $[5], t4 = $[6]), useEffect(t3, t4);
|
|
45819
45819
|
let t5;
|
|
45820
45820
|
$[7] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t5 = (addReleaseIds) => {
|
|
45821
|
-
setListenerReleaseIds((prevSlugs) => [...prevSlugs, ...addReleaseIds.filter(_temp2$
|
|
45821
|
+
setListenerReleaseIds((prevSlugs) => [...prevSlugs, ...addReleaseIds.filter(_temp2$S)]);
|
|
45822
45822
|
}, $[7] = t5) : t5 = $[7];
|
|
45823
45823
|
const addReleaseIdsToListener = t5;
|
|
45824
45824
|
let t6;
|
|
@@ -45871,17 +45871,17 @@ const RELEASES_NAME = "sanity/releases", RELEASES_INTENT = "release", releases =
|
|
|
45871
45871
|
let t0;
|
|
45872
45872
|
return $[0] !== contextValue ? (t0 = contextValue || {
|
|
45873
45873
|
state: DEFAULT_METADATA_STATE,
|
|
45874
|
-
addReleaseIdsToListener: _temp3$
|
|
45874
|
+
addReleaseIdsToListener: _temp3$r,
|
|
45875
45875
|
removeReleaseIdsFromListener: _temp4$b
|
|
45876
45876
|
}, $[0] = contextValue, $[1] = t0) : t0 = $[1], t0;
|
|
45877
45877
|
};
|
|
45878
|
-
function _temp$
|
|
45878
|
+
function _temp$26(slug) {
|
|
45879
45879
|
return slug;
|
|
45880
45880
|
}
|
|
45881
|
-
function _temp2$
|
|
45881
|
+
function _temp2$S(releaseId) {
|
|
45882
45882
|
return typeof releaseId == "string";
|
|
45883
45883
|
}
|
|
45884
|
-
function _temp3$
|
|
45884
|
+
function _temp3$r() {
|
|
45885
45885
|
return null;
|
|
45886
45886
|
}
|
|
45887
45887
|
function _temp4$b() {
|
|
@@ -46034,7 +46034,7 @@ function ReleasesUpsellProvider(props2) {
|
|
|
46034
46034
|
t
|
|
46035
46035
|
} = useTranslation();
|
|
46036
46036
|
let t1;
|
|
46037
|
-
$[1] !== allActiveReleases ? (t1 = allActiveReleases.filter(_temp$
|
|
46037
|
+
$[1] !== allActiveReleases ? (t1 = allActiveReleases.filter(_temp$25), $[1] = allActiveReleases, $[2] = t1) : t1 = $[2];
|
|
46038
46038
|
const meteredActiveReleases = t1;
|
|
46039
46039
|
let t2;
|
|
46040
46040
|
bb0: {
|
|
@@ -46153,7 +46153,7 @@ function ReleasesUpsellProvider(props2) {
|
|
|
46153
46153
|
t12
|
|
46154
46154
|
] }), $[43] = ctxValue, $[44] = props2.children, $[45] = t12, $[46] = t13) : t13 = $[46], t13;
|
|
46155
46155
|
}
|
|
46156
|
-
function _temp$
|
|
46156
|
+
function _temp$25(release) {
|
|
46157
46157
|
return !isCardinalityOneRelease(release);
|
|
46158
46158
|
}
|
|
46159
46159
|
function ReleasesStudioLayout(props2) {
|
|
@@ -46955,21 +46955,21 @@ function useProjectSubscriptions() {
|
|
|
46955
46955
|
}), $[2] = t1) : t1 = $[2], t0 = t1;
|
|
46956
46956
|
break bb0;
|
|
46957
46957
|
}
|
|
46958
|
-
t0 = projectSubscriptions$.pipe(map(_temp$
|
|
46958
|
+
t0 = projectSubscriptions$.pipe(map(_temp$24), startWith(INITIAL_LOADING_STATE), catchError(_temp2$R));
|
|
46959
46959
|
}
|
|
46960
46960
|
$[0] = projectId, $[1] = t0;
|
|
46961
46961
|
} else
|
|
46962
46962
|
t0 = $[1];
|
|
46963
46963
|
return useObservable(t0, INITIAL_LOADING_STATE);
|
|
46964
46964
|
}
|
|
46965
|
-
function _temp2$
|
|
46965
|
+
function _temp2$R(error) {
|
|
46966
46966
|
return of({
|
|
46967
46967
|
isLoading: !1,
|
|
46968
46968
|
projectSubscriptions: null,
|
|
46969
46969
|
error
|
|
46970
46970
|
});
|
|
46971
46971
|
}
|
|
46972
|
-
function _temp$
|
|
46972
|
+
function _temp$24(cachedSubscriptions) {
|
|
46973
46973
|
return {
|
|
46974
46974
|
isLoading: !1,
|
|
46975
46975
|
projectSubscriptions: cachedSubscriptions,
|
|
@@ -47014,7 +47014,7 @@ function ArchivedReleaseBanner(t0) {
|
|
|
47014
47014
|
retentionDays,
|
|
47015
47015
|
removalDate: removalDate || ""
|
|
47016
47016
|
}, components: {
|
|
47017
|
-
Link: _temp$
|
|
47017
|
+
Link: _temp$23
|
|
47018
47018
|
} }) }), $[10] = removalDate, $[11] = retentionDays, $[12] = tRelease, $[13] = t5) : t5 = $[13];
|
|
47019
47019
|
let t6;
|
|
47020
47020
|
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: [
|
|
@@ -47025,7 +47025,7 @@ function ArchivedReleaseBanner(t0) {
|
|
|
47025
47025
|
] })
|
|
47026
47026
|
] }) }), $[14] = t4, $[15] = t5, $[16] = t6) : t6 = $[16], t6;
|
|
47027
47027
|
}
|
|
47028
|
-
function _temp$
|
|
47028
|
+
function _temp$23(t0) {
|
|
47029
47029
|
const {
|
|
47030
47030
|
children
|
|
47031
47031
|
} = t0;
|
|
@@ -47308,7 +47308,7 @@ function ProgressIcon(props2) {
|
|
|
47308
47308
|
let t0;
|
|
47309
47309
|
if ($[3] !== progress) {
|
|
47310
47310
|
const circlePath = partialCircle(12.5, 12.5, 4.5, degreesToRadians(-90), degreesToRadians(progress * 360 - 90));
|
|
47311
|
-
t0 = circlePath.length > 0 ? `${circlePath.map(_temp$
|
|
47311
|
+
t0 = circlePath.length > 0 ? `${circlePath.map(_temp$22).join(" ")} L 12.5 12.5 Z` : void 0, $[3] = progress, $[4] = t0;
|
|
47312
47312
|
} else
|
|
47313
47313
|
t0 = $[4];
|
|
47314
47314
|
const d = t0;
|
|
@@ -47322,7 +47322,7 @@ function ProgressIcon(props2) {
|
|
|
47322
47322
|
t2
|
|
47323
47323
|
] }), $[8] = rest, $[9] = t1, $[10] = t3) : t3 = $[10], t3;
|
|
47324
47324
|
}
|
|
47325
|
-
function _temp$
|
|
47325
|
+
function _temp$22(vs) {
|
|
47326
47326
|
return vs.join(" ");
|
|
47327
47327
|
}
|
|
47328
47328
|
function partialCircle(cx, cy, r, start, end) {
|
|
@@ -47512,10 +47512,10 @@ const ReleasePublishAllButton = (t0) => {
|
|
|
47512
47512
|
enabled: isDraftModelEnabled
|
|
47513
47513
|
} = t2, [publishBundleStatus, setPublishBundleStatus] = useState("idle"), [publishPermission, setPublishPermission] = useState(!1);
|
|
47514
47514
|
let t3;
|
|
47515
|
-
$[0] !== documents ? (t3 = documents.some(_temp$
|
|
47515
|
+
$[0] !== documents ? (t3 = documents.some(_temp$21), $[0] = documents, $[1] = t3) : t3 = $[1];
|
|
47516
47516
|
const isValidatingDocuments = t3;
|
|
47517
47517
|
let t4;
|
|
47518
|
-
$[2] !== documents ? (t4 = documents.some(_temp2$
|
|
47518
|
+
$[2] !== documents ? (t4 = documents.some(_temp2$Q), $[2] = documents, $[3] = t4) : t4 = $[3];
|
|
47519
47519
|
const hasDocumentValidationErrors = t4, isPublishButtonDisabled = disabled || isValidatingDocuments || hasDocumentValidationErrors || !publishPermission, isMounted = useRef(!1);
|
|
47520
47520
|
let t5;
|
|
47521
47521
|
$[4] !== checkWithPermissionGuard || $[5] !== publishRelease || $[6] !== release._id ? (t5 = () => (isMounted.current = !0, checkWithPermissionGuard(publishRelease, release._id).then((hasPermission) => {
|
|
@@ -47638,13 +47638,13 @@ const ReleasePublishAllButton = (t0) => {
|
|
|
47638
47638
|
confirmPublishDialog
|
|
47639
47639
|
] }), $[82] = confirmPublishDialog, $[83] = t17, $[84] = t18) : t18 = $[84], t18;
|
|
47640
47640
|
};
|
|
47641
|
-
function _temp$
|
|
47641
|
+
function _temp$21(t0) {
|
|
47642
47642
|
const {
|
|
47643
47643
|
validation: validation2
|
|
47644
47644
|
} = t0;
|
|
47645
47645
|
return validation2.isValidating;
|
|
47646
47646
|
}
|
|
47647
|
-
function _temp2$
|
|
47647
|
+
function _temp2$Q(t0) {
|
|
47648
47648
|
const {
|
|
47649
47649
|
validation: validation_0
|
|
47650
47650
|
} = t0;
|
|
@@ -47694,8 +47694,8 @@ const useIsReleasesPlus = () => {
|
|
|
47694
47694
|
}
|
|
47695
47695
|
let t42;
|
|
47696
47696
|
if ($[5] !== client || $[6] !== dataset || $[7] !== observableClient || $[8] !== releaseDocuments || $[9] !== transactionId) {
|
|
47697
|
-
const publishedDocuments = releaseDocuments.map(_temp$
|
|
47698
|
-
t42 = from(getTransactionsLogs(client, publishedDocuments.map(_temp2$
|
|
47697
|
+
const publishedDocuments = releaseDocuments.map(_temp$20);
|
|
47698
|
+
t42 = from(getTransactionsLogs(client, publishedDocuments.map(_temp2$P), {
|
|
47699
47699
|
toTransaction: transactionId,
|
|
47700
47700
|
reverse: !0
|
|
47701
47701
|
})).pipe(map$1((transactions) => {
|
|
@@ -47728,7 +47728,7 @@ const useIsReleasesPlus = () => {
|
|
|
47728
47728
|
}
|
|
47729
47729
|
return observableClient.request({
|
|
47730
47730
|
url: `/data/history/${dataset}/documents/${docId_0}?revision=${revisionId}`
|
|
47731
|
-
}).pipe(map$1(_temp3$
|
|
47731
|
+
}).pipe(map$1(_temp3$q), catchError$1((err) => (console.error(`Error fetching document ${docId_0}:`, err), of(void 0))));
|
|
47732
47732
|
})) : of(void 0)), map$1(_temp5$7), catchError$1(_temp6$3)), $[5] = client, $[6] = dataset, $[7] = observableClient, $[8] = releaseDocuments, $[9] = transactionId, $[10] = t42;
|
|
47733
47733
|
} else
|
|
47734
47734
|
t42 = $[10];
|
|
@@ -47742,7 +47742,7 @@ const useIsReleasesPlus = () => {
|
|
|
47742
47742
|
let t6;
|
|
47743
47743
|
return $[14] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t6 = () => resolvedDocumentRevertStatesResultRef.current ? Promise.resolve(resolvedDocumentRevertStatesResultRef.current) : resultPromiseRef.current, $[14] = t6) : t6 = $[14], t6;
|
|
47744
47744
|
};
|
|
47745
|
-
function _temp$
|
|
47745
|
+
function _temp$20(t0) {
|
|
47746
47746
|
const {
|
|
47747
47747
|
document: document2
|
|
47748
47748
|
} = t0;
|
|
@@ -47751,10 +47751,10 @@ function _temp$1$(t0) {
|
|
|
47751
47751
|
_id: getPublishedId(document2._id)
|
|
47752
47752
|
};
|
|
47753
47753
|
}
|
|
47754
|
-
function _temp2$
|
|
47754
|
+
function _temp2$P(document_0) {
|
|
47755
47755
|
return document_0._id;
|
|
47756
47756
|
}
|
|
47757
|
-
function _temp3$
|
|
47757
|
+
function _temp3$q(t0) {
|
|
47758
47758
|
const {
|
|
47759
47759
|
documents: t1
|
|
47760
47760
|
} = t0, [revertDocument] = t1;
|
|
@@ -47779,23 +47779,23 @@ const usePostPublishTransactions = (documents) => {
|
|
|
47779
47779
|
break bb0;
|
|
47780
47780
|
}
|
|
47781
47781
|
let t1;
|
|
47782
|
-
$[1] !== client || $[2] !== documents || $[3] !== transactionId ? (t1 = from(getTransactionsLogs(client, documents.map(_temp$
|
|
47782
|
+
$[1] !== client || $[2] !== documents || $[3] !== transactionId ? (t1 = from(getTransactionsLogs(client, documents.map(_temp$1$), {
|
|
47783
47783
|
fromTransaction: transactionId,
|
|
47784
47784
|
limit: 2
|
|
47785
|
-
})).pipe(map$1(_temp2$
|
|
47785
|
+
})).pipe(map$1(_temp2$O), catchError$1(_temp3$p)), $[1] = client, $[2] = documents, $[3] = transactionId, $[4] = t1) : t1 = $[4], t0 = t1;
|
|
47786
47786
|
}
|
|
47787
47787
|
return useObservable(t0, null);
|
|
47788
47788
|
};
|
|
47789
|
-
function _temp$
|
|
47789
|
+
function _temp$1$(t0) {
|
|
47790
47790
|
const {
|
|
47791
47791
|
document: document2
|
|
47792
47792
|
} = t0;
|
|
47793
47793
|
return getPublishedId(document2._id);
|
|
47794
47794
|
}
|
|
47795
|
-
function _temp2$
|
|
47795
|
+
function _temp2$O(transactions) {
|
|
47796
47796
|
return transactions.length > 1;
|
|
47797
47797
|
}
|
|
47798
|
-
function _temp3$
|
|
47798
|
+
function _temp3$p() {
|
|
47799
47799
|
return of(null);
|
|
47800
47800
|
}
|
|
47801
47801
|
const ConfirmReleaseDialog = (t0) => {
|
|
@@ -47893,7 +47893,7 @@ const ConfirmReleaseDialog = (t0) => {
|
|
|
47893
47893
|
let t11;
|
|
47894
47894
|
$[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];
|
|
47895
47895
|
let t12;
|
|
47896
|
-
$[33] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t12 = () => setStageNewRevertRelease(_temp$
|
|
47896
|
+
$[33] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t12 = () => setStageNewRevertRelease(_temp$1_), $[33] = t12) : t12 = $[33];
|
|
47897
47897
|
let t13;
|
|
47898
47898
|
$[34] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t13 = {
|
|
47899
47899
|
display: "block"
|
|
@@ -47967,7 +47967,7 @@ const ConfirmReleaseDialog = (t0) => {
|
|
|
47967
47967
|
t10
|
|
47968
47968
|
] }), $[22] = t10, $[23] = t9, $[24] = t11) : t11 = $[24], t11;
|
|
47969
47969
|
};
|
|
47970
|
-
function _temp$
|
|
47970
|
+
function _temp$1_(current) {
|
|
47971
47971
|
return !current;
|
|
47972
47972
|
}
|
|
47973
47973
|
const ReleaseScheduleButton = (t0) => {
|
|
@@ -47996,10 +47996,10 @@ const ReleaseScheduleButton = (t0) => {
|
|
|
47996
47996
|
$[0] !== publishAt || $[1] !== utcToCurrentZoneDate ? (t2 = publishAt ? utcToCurrentZoneDate(publishAt) : void 0, $[0] = publishAt, $[1] = utcToCurrentZoneDate, $[2] = t2) : t2 = $[2];
|
|
47997
47997
|
const timeZoneAdjustedPublishAt = t2;
|
|
47998
47998
|
let t3;
|
|
47999
|
-
$[3] !== documents ? (t3 = documents.some(_temp$
|
|
47999
|
+
$[3] !== documents ? (t3 = documents.some(_temp$1Z), $[3] = documents, $[4] = t3) : t3 = $[4];
|
|
48000
48000
|
const isValidatingDocuments = t3;
|
|
48001
48001
|
let t4;
|
|
48002
|
-
$[5] !== documents ? (t4 = documents.some(_temp2$
|
|
48002
|
+
$[5] !== documents ? (t4 = documents.some(_temp2$N), $[5] = documents, $[6] = t4) : t4 = $[6];
|
|
48003
48003
|
const hasDocumentValidationErrors = t4, isScheduleButtonDisabled = disabled || isValidatingDocuments || !schedulePermission || hasDocumentValidationErrors, isMounted = useRef(!1);
|
|
48004
48004
|
let t5;
|
|
48005
48005
|
$[7] !== checkWithPermissionGuard || $[8] !== release._id || $[9] !== schedule ? (t5 = () => (isMounted.current = !0, checkWithPermissionGuard(schedule, release._id, /* @__PURE__ */ new Date()).then((hasPermission) => {
|
|
@@ -48028,7 +48028,7 @@ const ReleaseScheduleButton = (t0) => {
|
|
|
48028
48028
|
isEqual$2(newRelease, release) || updateRelease(newRelease);
|
|
48029
48029
|
}
|
|
48030
48030
|
if (isScheduledDateInPast()) {
|
|
48031
|
-
setRerenderDialog(_temp3$
|
|
48031
|
+
setRerenderDialog(_temp3$o);
|
|
48032
48032
|
return;
|
|
48033
48033
|
}
|
|
48034
48034
|
const run = async () => {
|
|
@@ -48228,19 +48228,19 @@ const ReleaseScheduleButton = (t0) => {
|
|
|
48228
48228
|
confirmScheduleDialog
|
|
48229
48229
|
] }), $[140] = confirmScheduleDialog, $[141] = t25, $[142] = t26) : t26 = $[142], t26;
|
|
48230
48230
|
};
|
|
48231
|
-
function _temp$
|
|
48231
|
+
function _temp$1Z(t0) {
|
|
48232
48232
|
const {
|
|
48233
48233
|
validation: validation2
|
|
48234
48234
|
} = t0;
|
|
48235
48235
|
return validation2.isValidating;
|
|
48236
48236
|
}
|
|
48237
|
-
function _temp2$
|
|
48237
|
+
function _temp2$N(t0) {
|
|
48238
48238
|
const {
|
|
48239
48239
|
validation: validation_0
|
|
48240
48240
|
} = t0;
|
|
48241
48241
|
return validation_0.hasError;
|
|
48242
48242
|
}
|
|
48243
|
-
function _temp3$
|
|
48243
|
+
function _temp3$o(cur) {
|
|
48244
48244
|
return cur + 1;
|
|
48245
48245
|
}
|
|
48246
48246
|
const ReleaseUnscheduleButton = (t0) => {
|
|
@@ -48411,7 +48411,7 @@ function mapHooksToStates(states, {
|
|
|
48411
48411
|
function useHookCollectionStates(t0) {
|
|
48412
48412
|
const $ = c(12), {
|
|
48413
48413
|
hooks
|
|
48414
|
-
} = t0, [states] = useState(_temp$
|
|
48414
|
+
} = t0, [states] = useState(_temp$1Y);
|
|
48415
48415
|
let t1;
|
|
48416
48416
|
$[0] !== hooks || $[1] !== states ? (t1 = () => mapHooksToStates(states, {
|
|
48417
48417
|
hooks
|
|
@@ -48425,7 +48425,7 @@ function useHookCollectionStates(t0) {
|
|
|
48425
48425
|
}));
|
|
48426
48426
|
}, {
|
|
48427
48427
|
signal: abortControllerRef.current.signal
|
|
48428
|
-
})?.catch(_temp2$
|
|
48428
|
+
})?.catch(_temp2$M);
|
|
48429
48429
|
}, $[3] = hooks, $[4] = states, $[5] = t2) : t2 = $[5];
|
|
48430
48430
|
const requestUpdateSnapshot = useThrottledCallback(t2, 60, throttleOptions);
|
|
48431
48431
|
let t3;
|
|
@@ -48449,11 +48449,11 @@ function useHookCollectionStates(t0) {
|
|
|
48449
48449
|
handleNext
|
|
48450
48450
|
}, $[9] = handleNext, $[10] = snapshot2, $[11] = t4) : t4 = $[11], t4;
|
|
48451
48451
|
}
|
|
48452
|
-
function _temp2$
|
|
48452
|
+
function _temp2$M(error) {
|
|
48453
48453
|
if (error.name !== "AbortError")
|
|
48454
48454
|
throw error;
|
|
48455
48455
|
}
|
|
48456
|
-
function _temp$
|
|
48456
|
+
function _temp$1Y() {
|
|
48457
48457
|
return /* @__PURE__ */ new Map();
|
|
48458
48458
|
}
|
|
48459
48459
|
function GetHookCollectionState(props2) {
|
|
@@ -48477,7 +48477,7 @@ function GetHookCollectionState(props2) {
|
|
|
48477
48477
|
}), $[2] = children, $[3] = states, $[4] = t1) : t1 = $[4];
|
|
48478
48478
|
const result = t1, [forceReset, setForceReset] = useState(0);
|
|
48479
48479
|
let t2, t3;
|
|
48480
|
-
$[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = () => () => setForceReset(_temp$
|
|
48480
|
+
$[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);
|
|
48481
48481
|
const t4 = `render-${forceReset}`;
|
|
48482
48482
|
let t5;
|
|
48483
48483
|
$[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];
|
|
@@ -48487,7 +48487,7 @@ function GetHookCollectionState(props2) {
|
|
|
48487
48487
|
result
|
|
48488
48488
|
] }), $[12] = result, $[13] = t5, $[14] = t6) : t6 = $[14], t6;
|
|
48489
48489
|
}
|
|
48490
|
-
function _temp$
|
|
48490
|
+
function _temp$1X(n) {
|
|
48491
48491
|
return n + 1;
|
|
48492
48492
|
}
|
|
48493
48493
|
const ReleaseActionsStateHandler = memo(function(t0) {
|
|
@@ -48871,7 +48871,7 @@ const toastActionComponents = {
|
|
|
48871
48871
|
$[15] !== documents || $[16] !== duplicateRelease || $[17] !== guardWithReleaseLimitUpsell || $[18] !== release.metadata || $[19] !== t ? (t8 = async () => {
|
|
48872
48872
|
const duplicateReleaseId = createReleaseId();
|
|
48873
48873
|
return await guardWithReleaseLimitUpsell(async () => {
|
|
48874
|
-
const releaseDocuments = documents?.map(_temp$
|
|
48874
|
+
const releaseDocuments = documents?.map(_temp$1W), duplicatedMetadata = {
|
|
48875
48875
|
...release.metadata,
|
|
48876
48876
|
title: `${release.metadata.title} (${t("copy-suffix")})`
|
|
48877
48877
|
};
|
|
@@ -49051,7 +49051,7 @@ const toastActionComponents = {
|
|
|
49051
49051
|
confirmActionDialog
|
|
49052
49052
|
] }), $[130] = confirmActionDialog, $[131] = t20, $[132] = t32, $[133] = t33) : t33 = $[133], t33;
|
|
49053
49053
|
};
|
|
49054
|
-
function _temp$
|
|
49054
|
+
function _temp$1W(doc) {
|
|
49055
49055
|
return doc.document;
|
|
49056
49056
|
}
|
|
49057
49057
|
function StatusItem(props2) {
|
|
@@ -49092,7 +49092,7 @@ function ReleaseStatusItems(t0) {
|
|
|
49092
49092
|
} = useTranslation(releasesLocaleNamespace);
|
|
49093
49093
|
let t1;
|
|
49094
49094
|
if ($[0] !== events2) {
|
|
49095
|
-
const createEvent = events2.find(isCreateReleaseEvent), extraEvent = events2.find(_temp$
|
|
49095
|
+
const createEvent = events2.find(isCreateReleaseEvent), extraEvent = events2.find(_temp$1V);
|
|
49096
49096
|
t1 = [createEvent, extraEvent].filter(isNonNullable$3), $[0] = events2, $[1] = t1;
|
|
49097
49097
|
} else
|
|
49098
49098
|
t1 = $[1];
|
|
@@ -49118,7 +49118,7 @@ function ReleaseStatusItems(t0) {
|
|
|
49118
49118
|
/* @__PURE__ */ jsx(RelativeTime, { time: event_0.timestamp, useTemporalPhrase: !0, minimal: !0 })
|
|
49119
49119
|
] }) }, event_0.id)) }), $[10] = footerEvents, $[11] = t, $[12] = t2) : t2 = $[12], t2;
|
|
49120
49120
|
}
|
|
49121
|
-
function _temp$
|
|
49121
|
+
function _temp$1V(event) {
|
|
49122
49122
|
return isPublishReleaseEvent(event) || isArchiveReleaseEvent(event) || isUnarchiveReleaseEvent(event);
|
|
49123
49123
|
}
|
|
49124
49124
|
function ReleaseDashboardFooter(props2) {
|
|
@@ -49219,7 +49219,7 @@ function ReleaseDashboardHeader(props2) {
|
|
|
49219
49219
|
const handleNavigateToReleasesList = t1;
|
|
49220
49220
|
let t2;
|
|
49221
49221
|
$[6] !== setInspector ? (t2 = () => {
|
|
49222
|
-
setInspector(_temp$
|
|
49222
|
+
setInspector(_temp$1U);
|
|
49223
49223
|
}, $[6] = setInspector, $[7] = t2) : t2 = $[7];
|
|
49224
49224
|
const handleActivityClick = t2;
|
|
49225
49225
|
let t3;
|
|
@@ -49252,7 +49252,7 @@ function ReleaseDashboardHeader(props2) {
|
|
|
49252
49252
|
t12
|
|
49253
49253
|
] }), $[31] = t12, $[32] = t9, $[33] = t13) : t13 = $[33], t13;
|
|
49254
49254
|
}
|
|
49255
|
-
function _temp$
|
|
49255
|
+
function _temp$1U(prev) {
|
|
49256
49256
|
return prev === "activity" ? void 0 : "activity";
|
|
49257
49257
|
}
|
|
49258
49258
|
const emptyCellStyle = {
|
|
@@ -50556,7 +50556,7 @@ function DocumentTypesPopoverContent() {
|
|
|
50556
50556
|
return index;
|
|
50557
50557
|
}
|
|
50558
50558
|
}, $[4] = documentTypeItems, $[5] = t5) : t5 = $[5];
|
|
50559
|
-
const getItemKey2 = t5, renderItem2 = _temp$
|
|
50559
|
+
const getItemKey2 = t5, renderItem2 = _temp$1T;
|
|
50560
50560
|
let t6;
|
|
50561
50561
|
$[6] !== documentTypeItems ? (t6 = (index_0) => documentTypeItems[index_0].type !== "item", $[6] = documentTypeItems, $[7] = t6) : t6 = $[7];
|
|
50562
50562
|
const getItemDisabled = t6;
|
|
@@ -50590,7 +50590,7 @@ function DocumentTypesPopoverContent() {
|
|
|
50590
50590
|
t13
|
|
50591
50591
|
] }), $[33] = t12, $[34] = t13, $[35] = t9, $[36] = t14) : t14 = $[36], t14;
|
|
50592
50592
|
}
|
|
50593
|
-
function _temp$
|
|
50593
|
+
function _temp$1T(item) {
|
|
50594
50594
|
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;
|
|
50595
50595
|
}
|
|
50596
50596
|
function ClearButton(t0) {
|
|
@@ -51256,7 +51256,7 @@ function useRecentSearchesStore() {
|
|
|
51256
51256
|
let t5;
|
|
51257
51257
|
return $[11] !== fieldDefinitions || $[12] !== filterDefinitions2 || $[13] !== operatorDefinitions2 || $[14] !== schema2 || $[15] !== setStoredSearch || $[16] !== storedSearch ? (t5 = {
|
|
51258
51258
|
addSearch: (searchTerm, searchFilters) => {
|
|
51259
|
-
const validStoredFilters = (searchFilters || []).map(_temp$
|
|
51259
|
+
const validStoredFilters = (searchFilters || []).map(_temp$1S).filter((filter_0) => validateFilter({
|
|
51260
51260
|
fieldDefinitions,
|
|
51261
51261
|
filter: filter_0,
|
|
51262
51262
|
filterDefinitions: filterDefinitions2,
|
|
@@ -51266,7 +51266,7 @@ function useRecentSearchesStore() {
|
|
|
51266
51266
|
filters: validStoredFilters,
|
|
51267
51267
|
terms: {
|
|
51268
51268
|
query: searchTerm.query.trim(),
|
|
51269
|
-
typeNames: searchTerm.types.map(_temp2$
|
|
51269
|
+
typeNames: searchTerm.types.map(_temp2$L)
|
|
51270
51270
|
}
|
|
51271
51271
|
}, newRecent = {
|
|
51272
51272
|
version: RECENT_SEARCH_VERSION,
|
|
@@ -51328,10 +51328,10 @@ function useRecentSearchesStore() {
|
|
|
51328
51328
|
}
|
|
51329
51329
|
}, $[11] = fieldDefinitions, $[12] = filterDefinitions2, $[13] = operatorDefinitions2, $[14] = schema2, $[15] = setStoredSearch, $[16] = storedSearch, $[17] = t5) : t5 = $[17], t5;
|
|
51330
51330
|
}
|
|
51331
|
-
function _temp2$
|
|
51331
|
+
function _temp2$L(s) {
|
|
51332
51332
|
return s.name;
|
|
51333
51333
|
}
|
|
51334
|
-
function _temp$
|
|
51334
|
+
function _temp$1S(filter2) {
|
|
51335
51335
|
return {
|
|
51336
51336
|
fieldId: filter2.fieldId,
|
|
51337
51337
|
filterName: filter2.filterName,
|
|
@@ -51392,12 +51392,12 @@ function Instructions() {
|
|
|
51392
51392
|
} = useTranslation();
|
|
51393
51393
|
let t0;
|
|
51394
51394
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t0 = {
|
|
51395
|
-
ControlsIcon: _temp$
|
|
51395
|
+
ControlsIcon: _temp$1R
|
|
51396
51396
|
}, $[0] = t0) : t0 = $[0];
|
|
51397
51397
|
let t1;
|
|
51398
51398
|
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;
|
|
51399
51399
|
}
|
|
51400
|
-
function _temp$
|
|
51400
|
+
function _temp$1R() {
|
|
51401
51401
|
return /* @__PURE__ */ jsx(ControlsIcon, { style: {
|
|
51402
51402
|
padding: "0 0.25rem"
|
|
51403
51403
|
} }, 0);
|
|
@@ -51488,7 +51488,7 @@ function RecentSearchItem(t0) {
|
|
|
51488
51488
|
let t6;
|
|
51489
51489
|
$[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];
|
|
51490
51490
|
let t7;
|
|
51491
|
-
$[18] !== value.filters ? (t7 = value?.filters?.map(_temp$
|
|
51491
|
+
$[18] !== value.filters ? (t7 = value?.filters?.map(_temp$1Q), $[18] = value.filters, $[19] = t7) : t7 = $[19];
|
|
51492
51492
|
let t8;
|
|
51493
51493
|
$[20] !== t5 || $[21] !== t6 || $[22] !== t7 ? (t8 = /* @__PURE__ */ jsxs(Flex, { align: "stretch", flex: 1, gap: 2, justify: "flex-start", marginLeft: 3, wrap: "wrap", children: [
|
|
51494
51494
|
t5,
|
|
@@ -51510,7 +51510,7 @@ function RecentSearchItem(t0) {
|
|
|
51510
51510
|
let t13;
|
|
51511
51511
|
return $[33] !== rest || $[34] !== t12 ? (t13 = /* @__PURE__ */ jsx(Box, { ...rest, children: t12 }), $[33] = rest, $[34] = t12, $[35] = t13) : t13 = $[35], t13;
|
|
51512
51512
|
}
|
|
51513
|
-
function _temp$
|
|
51513
|
+
function _temp$1Q(filter2, i) {
|
|
51514
51514
|
return /* @__PURE__ */ jsx(FilterPill, { filter: filter2 }, i);
|
|
51515
51515
|
}
|
|
51516
51516
|
const VIRTUAL_LIST_RECENT_SEARCH_ITEM_HEIGHT = 36, MAX_COMBINED_TYPE_COUNT_SMALL = 20, MAX_COMBINED_TYPE_COUNT_LARGE = 40, RecentSearchesBox = styled(Card)`
|
|
@@ -51817,7 +51817,7 @@ function SortMenu() {
|
|
|
51817
51817
|
$[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];
|
|
51818
51818
|
const t14 = menuButtonId || "";
|
|
51819
51819
|
let t15;
|
|
51820
|
-
$[30] !== menuOrderings ? (t15 = /* @__PURE__ */ jsx(Menu, { children: menuOrderings.map(_temp$
|
|
51820
|
+
$[30] !== menuOrderings ? (t15 = /* @__PURE__ */ jsx(Menu, { children: menuOrderings.map(_temp$1P) }), $[30] = menuOrderings, $[31] = t15) : t15 = $[31];
|
|
51821
51821
|
let t16;
|
|
51822
51822
|
$[32] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t16 = {
|
|
51823
51823
|
portal: !0,
|
|
@@ -51830,7 +51830,7 @@ function SortMenu() {
|
|
|
51830
51830
|
let t19;
|
|
51831
51831
|
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;
|
|
51832
51832
|
}
|
|
51833
|
-
function _temp$
|
|
51833
|
+
function _temp$1P(item_0, index) {
|
|
51834
51834
|
return isSearchDivider(item_0) ? /* @__PURE__ */ jsx(MenuDivider, {}, index) : /* @__PURE__ */ jsx(CustomMenuItem$1, { ordering: item_0 }, index);
|
|
51835
51835
|
}
|
|
51836
51836
|
const DebugScoreCard = styled(Card)`
|
|
@@ -51849,8 +51849,8 @@ function DebugOverlay(t0) {
|
|
|
51849
51849
|
score <= 0.1 ? tone = "critical" : score >= 0.5 && (tone = "primary");
|
|
51850
51850
|
let T0, T1, t1, t2;
|
|
51851
51851
|
if ($[0] !== data.stories) {
|
|
51852
|
-
const matchingStories = data.stories.filter(_temp$
|
|
51853
|
-
T1 = Tooltip, T0 = Stack, t1 = 2, t2 = matchingStories.length ? /* @__PURE__ */ jsx(Fragment$1, { children: matchingStories.map(_temp2$
|
|
51852
|
+
const matchingStories = data.stories.filter(_temp$1O);
|
|
51853
|
+
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;
|
|
51854
51854
|
} else
|
|
51855
51855
|
T0 = $[1], T1 = $[2], t1 = $[3], t2 = $[4];
|
|
51856
51856
|
let t3;
|
|
@@ -51865,13 +51865,13 @@ function DebugOverlay(t0) {
|
|
|
51865
51865
|
let t6;
|
|
51866
51866
|
return $[14] !== T1 || $[15] !== t3 || $[16] !== t5 ? (t6 = /* @__PURE__ */ jsx(Fragment$1, { children: /* @__PURE__ */ jsx(T1, { content: t3, placement: "bottom-start", portal: !0, children: t5 }) }), $[14] = T1, $[15] = t3, $[16] = t5, $[17] = t6) : t6 = $[17], t6;
|
|
51867
51867
|
}
|
|
51868
|
-
function _temp2$
|
|
51868
|
+
function _temp2$K(story_0) {
|
|
51869
51869
|
return /* @__PURE__ */ jsxs(Inline, { space: 3, children: [
|
|
51870
51870
|
/* @__PURE__ */ jsx(Code, { size: 0, weight: "medium", children: story_0.path }),
|
|
51871
51871
|
/* @__PURE__ */ jsx(Code, { size: 0, children: story_0.why })
|
|
51872
51872
|
] }, story_0.path);
|
|
51873
51873
|
}
|
|
51874
|
-
function _temp$
|
|
51874
|
+
function _temp$1O(story) {
|
|
51875
51875
|
return story.score > 0;
|
|
51876
51876
|
}
|
|
51877
51877
|
const SearchResultItemPreviewBox = styled(Box)`
|
|
@@ -52230,7 +52230,7 @@ function useSearch(t0) {
|
|
|
52230
52230
|
}), $[0] = client, $[1] = maxFieldDepth, $[2] = schema2, $[3] = strategy, $[4] = t1) : t1 = $[4];
|
|
52231
52231
|
const search2 = t1;
|
|
52232
52232
|
let t2;
|
|
52233
|
-
$[5] !== allowEmptyQueries || $[6] !== onComplete || $[7] !== onError || $[8] !== onStart || $[9] !== search2 ? (t2 = (inputValue$) => inputValue$.pipe(filter(nonNullable), map(sanitizeRequest), distinctUntilChanged(isEqual$2), debounce$1(_temp$
|
|
52233
|
+
$[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({
|
|
52234
52234
|
...INITIAL_SEARCH_STATE,
|
|
52235
52235
|
loading: !0,
|
|
52236
52236
|
options: request_0.options,
|
|
@@ -52258,7 +52258,7 @@ function useSearch(t0) {
|
|
|
52258
52258
|
nextCursor: void 0
|
|
52259
52259
|
})))), of({
|
|
52260
52260
|
loading: !1
|
|
52261
|
-
}))), scan(_temp2$
|
|
52261
|
+
}))), scan(_temp2$J, INITIAL_SEARCH_STATE), tap(setSearchState)), $[5] = allowEmptyQueries, $[6] = onComplete, $[7] = onError, $[8] = onStart, $[9] = search2, $[10] = t2) : t2 = $[10];
|
|
52262
52262
|
const handleQueryChange = useObservableEvent(t2);
|
|
52263
52263
|
let t3;
|
|
52264
52264
|
$[11] !== handleQueryChange ? (t3 = (searchRequest) => handleQueryChange(searchRequest), $[11] = handleQueryChange, $[12] = t3) : t3 = $[12];
|
|
@@ -52269,13 +52269,13 @@ function useSearch(t0) {
|
|
|
52269
52269
|
searchState
|
|
52270
52270
|
}, $[13] = handleSearch, $[14] = searchState, $[15] = t4) : t4 = $[15], t4;
|
|
52271
52271
|
}
|
|
52272
|
-
function _temp2$
|
|
52272
|
+
function _temp2$J(prevState, nextState) {
|
|
52273
52273
|
return {
|
|
52274
52274
|
...prevState,
|
|
52275
52275
|
...nextState
|
|
52276
52276
|
};
|
|
52277
52277
|
}
|
|
52278
|
-
function _temp$
|
|
52278
|
+
function _temp$1N(request) {
|
|
52279
52279
|
return timer(request?.debounceTime || DEFAULT_DEBOUNCE_TIME);
|
|
52280
52280
|
}
|
|
52281
52281
|
function isRecentSearchTerms(terms) {
|
|
@@ -52915,7 +52915,7 @@ function ReleaseActionBadges(t0) {
|
|
|
52915
52915
|
t
|
|
52916
52916
|
} = useTranslation(releasesLocaleNamespace);
|
|
52917
52917
|
let t2;
|
|
52918
|
-
$[0] !== documents ? (t2 = documents.reduce(_temp$
|
|
52918
|
+
$[0] !== documents ? (t2 = documents.reduce(_temp$1M, {
|
|
52919
52919
|
added: 0,
|
|
52920
52920
|
changed: 0,
|
|
52921
52921
|
unpublished: 0
|
|
@@ -52952,7 +52952,7 @@ function ReleaseActionBadges(t0) {
|
|
|
52952
52952
|
t4
|
|
52953
52953
|
] }), $[8] = t3, $[9] = t4, $[10] = t5) : t5 = $[10], t5;
|
|
52954
52954
|
}
|
|
52955
|
-
function _temp$
|
|
52955
|
+
function _temp$1M(acc, doc) {
|
|
52956
52956
|
const actionType = getDocumentActionType(doc);
|
|
52957
52957
|
return actionType && (acc[actionType] = acc[actionType] + 1), acc;
|
|
52958
52958
|
}
|
|
@@ -53125,7 +53125,7 @@ function useReleaseHistory(releaseDocumentId, releaseId, documentRevision) {
|
|
|
53125
53125
|
});
|
|
53126
53126
|
})().catch((error) => {
|
|
53127
53127
|
console.error("Failed to fetch or parse document history:", error), cancelledRef.current || setHistory([]);
|
|
53128
|
-
}).finally(_temp$
|
|
53128
|
+
}).finally(_temp$1L);
|
|
53129
53129
|
}, $[3] = client, $[4] = documentRevision, $[5] = releaseDocumentId, $[6] = versionId, $[7] = t1) : t1 = $[7];
|
|
53130
53130
|
const fetchAndParse = t1;
|
|
53131
53131
|
let t2, t3;
|
|
@@ -53152,7 +53152,7 @@ function useReleaseHistory(releaseDocumentId, releaseId, documentRevision) {
|
|
|
53152
53152
|
};
|
|
53153
53153
|
history2.forEach((item) => {
|
|
53154
53154
|
const author = item.author;
|
|
53155
|
-
collaborators.includes(author) || collaborators.push(author), aggregated.history.length === 0 && (aggregated.createdBy = author), item.mutations?.some(_temp2$
|
|
53155
|
+
collaborators.includes(author) || collaborators.push(author), aggregated.history.length === 0 && (aggregated.createdBy = author), item.mutations?.some(_temp2$I) && (aggregated.createdBy = author), aggregated.editors.includes(author) || aggregated.editors.push(author), aggregated.lastEditedBy = author, aggregated.history.push(item);
|
|
53156
53156
|
});
|
|
53157
53157
|
let t5;
|
|
53158
53158
|
$[13] !== aggregated || $[14] !== collaborators ? (t5 = {
|
|
@@ -53166,10 +53166,10 @@ function useReleaseHistory(releaseDocumentId, releaseId, documentRevision) {
|
|
|
53166
53166
|
t4 = $[12];
|
|
53167
53167
|
return t4;
|
|
53168
53168
|
}
|
|
53169
|
-
function _temp2$
|
|
53169
|
+
function _temp2$I(mutation) {
|
|
53170
53170
|
return "create" in mutation;
|
|
53171
53171
|
}
|
|
53172
|
-
function _temp$
|
|
53172
|
+
function _temp$1L() {
|
|
53173
53173
|
releaseHistorySlot();
|
|
53174
53174
|
}
|
|
53175
53175
|
const MemoReleaseDocumentPreview = memo(function(t0) {
|
|
@@ -53348,7 +53348,7 @@ function ReleaseSummary(props2) {
|
|
|
53348
53348
|
const documentTableColumnDefs = t4;
|
|
53349
53349
|
let t5;
|
|
53350
53350
|
$[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t5 = () => setAddDocumentDialog(!0), $[10] = t5) : t5 = $[10];
|
|
53351
|
-
const handleAddDocumentClick = t5, filterRows = _temp$
|
|
53351
|
+
const handleAddDocumentClick = t5, filterRows = _temp$1K;
|
|
53352
53352
|
let t6;
|
|
53353
53353
|
$[11] !== createVersion || $[12] !== releaseId || $[13] !== t || $[14] !== telemetry || $[15] !== toast ? (t6 = async (documentToAdd) => {
|
|
53354
53354
|
if (setAddDocumentDialog(!1), !documentToAdd)
|
|
@@ -53440,7 +53440,7 @@ function ReleaseSummary(props2) {
|
|
|
53440
53440
|
let t16;
|
|
53441
53441
|
$[46] !== isLoading || $[47] !== release.state || $[48] !== t ? (t16 = release.state === "active" && /* @__PURE__ */ jsx(Container$2, { width: 3, children: /* @__PURE__ */ jsx(Card, { padding: 3, children: /* @__PURE__ */ jsx(Button, { icon: AddIcon, disabled: isLoading, mode: "bleed", onClick: handleAddDocumentClick, text: t("action.add-document") }) }) }), $[46] = isLoading, $[47] = release.state, $[48] = t, $[49] = t16) : t16 = $[49];
|
|
53442
53442
|
let t17;
|
|
53443
|
-
$[50] !== documents ? (t17 = documents.map(_temp2$
|
|
53443
|
+
$[50] !== documents ? (t17 = documents.map(_temp2$H), $[50] = documents, $[51] = t17) : t17 = $[51];
|
|
53444
53444
|
let t18;
|
|
53445
53445
|
$[52] !== closeAddDialog || $[53] !== openAddDocumentDialog || $[54] !== releaseId || $[55] !== t17 ? (t18 = /* @__PURE__ */ jsx(AddDocumentSearch, { open: openAddDocumentDialog, onClose: closeAddDialog, releaseId, idsInRelease: t17 }), $[52] = closeAddDialog, $[53] = openAddDocumentDialog, $[54] = releaseId, $[55] = t17, $[56] = t18) : t18 = $[56];
|
|
53446
53446
|
let t19;
|
|
@@ -53450,13 +53450,13 @@ function ReleaseSummary(props2) {
|
|
|
53450
53450
|
t18
|
|
53451
53451
|
] }), $[57] = t15, $[58] = t16, $[59] = t18, $[60] = t19) : t19 = $[60], t19;
|
|
53452
53452
|
}
|
|
53453
|
-
function _temp2$
|
|
53453
|
+
function _temp2$H(t0) {
|
|
53454
53454
|
const {
|
|
53455
53455
|
document: document_3
|
|
53456
53456
|
} = t0;
|
|
53457
53457
|
return document_3._id;
|
|
53458
53458
|
}
|
|
53459
|
-
function _temp$
|
|
53459
|
+
function _temp$1K(data, searchTerm) {
|
|
53460
53460
|
return data.filter((t0) => {
|
|
53461
53461
|
const {
|
|
53462
53462
|
document: document2
|
|
@@ -53797,7 +53797,7 @@ function CalendarMonth$2(props2) {
|
|
|
53797
53797
|
$[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t1 = {
|
|
53798
53798
|
gridGap: "1px",
|
|
53799
53799
|
gridTemplateColumns: "repeat(7, 1fr)"
|
|
53800
|
-
}, t2 = DEFAULT_WEEK_DAY_NAMES.map(_temp$
|
|
53800
|
+
}, t2 = DEFAULT_WEEK_DAY_NAMES.map(_temp$1J), $[0] = t1, $[1] = t2) : (t1 = $[0], t2 = $[1]);
|
|
53801
53801
|
let t3;
|
|
53802
53802
|
if ($[2] !== CalendarDay2 || $[3] !== date || $[4] !== disabled || $[5] !== getCurrentZoneDate || $[6] !== props2.focused || $[7] !== props2.onSelect || $[8] !== props2.selected || $[9] !== weeksOfMonth) {
|
|
53803
53803
|
let t42;
|
|
@@ -53815,7 +53815,7 @@ function CalendarMonth$2(props2) {
|
|
|
53815
53815
|
let t5;
|
|
53816
53816
|
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;
|
|
53817
53817
|
}
|
|
53818
|
-
function _temp$
|
|
53818
|
+
function _temp$1J(weekday) {
|
|
53819
53819
|
return /* @__PURE__ */ jsx(Card, { paddingY: 3, children: /* @__PURE__ */ jsx(Label, { size: 1, style: {
|
|
53820
53820
|
textAlign: "center"
|
|
53821
53821
|
}, children: weekday.slice(0, 1) }) }, weekday);
|
|
@@ -54073,7 +54073,7 @@ function CreateReleaseDialog(props2) {
|
|
|
54073
54073
|
const releaseValue = createReleaseMetadata(release);
|
|
54074
54074
|
await createRelease(releaseValue), onCancel(), telemetry.log(CreatedRelease, {
|
|
54075
54075
|
origin
|
|
54076
|
-
}), await new Promise(_temp$
|
|
54076
|
+
}), await new Promise(_temp$1I), setPerspective(getReleaseIdFromReleaseDocumentId(release._id)), onSubmit(getReleaseIdFromReleaseDocumentId(release._id));
|
|
54077
54077
|
} catch (t22) {
|
|
54078
54078
|
const err = t22;
|
|
54079
54079
|
isReleaseLimitError(err) ? (onCancel(), clearReleaseDataFromStorage()) : (console.error(err), toast.push({
|
|
@@ -54114,7 +54114,7 @@ function CreateReleaseDialog(props2) {
|
|
|
54114
54114
|
let t10;
|
|
54115
54115
|
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;
|
|
54116
54116
|
}
|
|
54117
|
-
function _temp$
|
|
54117
|
+
function _temp$1I(resolve) {
|
|
54118
54118
|
return setTimeout(resolve, 1e3);
|
|
54119
54119
|
}
|
|
54120
54120
|
const useReleasesMetadata = (releaseIds) => {
|
|
@@ -54157,7 +54157,7 @@ function CalendarPopover(t0) {
|
|
|
54157
54157
|
let t3;
|
|
54158
54158
|
$[2] !== t ? (t3 = t("overview.calendar.tooltip"), $[2] = t, $[3] = t3) : t3 = $[3];
|
|
54159
54159
|
let t4;
|
|
54160
|
-
$[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t4 = () => setIsCalendarOpen(_temp$
|
|
54160
|
+
$[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t4 = () => setIsCalendarOpen(_temp$1H), $[4] = t4) : t4 = $[4];
|
|
54161
54161
|
let t5;
|
|
54162
54162
|
$[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];
|
|
54163
54163
|
let t6;
|
|
@@ -54165,7 +54165,7 @@ function CalendarPopover(t0) {
|
|
|
54165
54165
|
let t7;
|
|
54166
54166
|
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;
|
|
54167
54167
|
}
|
|
54168
|
-
function _temp$
|
|
54168
|
+
function _temp$1H(prev) {
|
|
54169
54169
|
return !prev;
|
|
54170
54170
|
}
|
|
54171
54171
|
const getPickerView = ({
|
|
@@ -54299,7 +54299,7 @@ const ScheduledDraftDocumentPreview = (t0) => {
|
|
|
54299
54299
|
}
|
|
54300
54300
|
let T0, T1, T2, t1, t10, t11, t12, t2, t3, t4, t5, t6, t7, t8, t9;
|
|
54301
54301
|
if ($[3] !== cellProps || $[4] !== firstDocument._id || $[5] !== firstDocument._rev || $[6] !== firstDocument._type || $[7] !== firstDocumentValidation || $[8] !== release._id || $[9] !== release.state || $[10] !== t) {
|
|
54302
|
-
const validationErrorCount = firstDocumentValidation?.filter(_temp$
|
|
54302
|
+
const validationErrorCount = firstDocumentValidation?.filter(_temp$1G).length || 0;
|
|
54303
54303
|
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: [
|
|
54304
54304
|
/* @__PURE__ */ jsx(ToneIcon, { icon: ErrorOutlineIcon, tone: "critical" }),
|
|
54305
54305
|
t("document-validation.error", {
|
|
@@ -54318,7 +54318,7 @@ const ScheduledDraftDocumentPreview = (t0) => {
|
|
|
54318
54318
|
let t15;
|
|
54319
54319
|
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;
|
|
54320
54320
|
};
|
|
54321
|
-
function _temp$
|
|
54321
|
+
function _temp$1G(validation2) {
|
|
54322
54322
|
return validation2.level === "error";
|
|
54323
54323
|
}
|
|
54324
54324
|
function useReleaseCreator(releaseDocumentId, t0) {
|
|
@@ -54404,7 +54404,7 @@ function useScheduleActiveDrafts() {
|
|
|
54404
54404
|
const $ = c(4), client = useClient(RELEASES_STUDIO_CLIENT_OPTIONS);
|
|
54405
54405
|
let t0;
|
|
54406
54406
|
$[0] !== client ? (t0 = async (releases2) => {
|
|
54407
|
-
const scheduleActions = releases2.flatMap(_temp$
|
|
54407
|
+
const scheduleActions = releases2.flatMap(_temp$1F);
|
|
54408
54408
|
await client.action(scheduleActions);
|
|
54409
54409
|
}, $[0] = client, $[1] = t0) : t0 = $[1];
|
|
54410
54410
|
const scheduleActiveDrafts = t0;
|
|
@@ -54413,7 +54413,7 @@ function useScheduleActiveDrafts() {
|
|
|
54413
54413
|
scheduleActiveDrafts
|
|
54414
54414
|
}, $[2] = scheduleActiveDrafts, $[3] = t1) : t1 = $[3], t1;
|
|
54415
54415
|
}
|
|
54416
|
-
function _temp$
|
|
54416
|
+
function _temp$1F(release) {
|
|
54417
54417
|
return release.metadata.intendedPublishAt ? [{
|
|
54418
54418
|
actionType: "sanity.action.release.schedule",
|
|
54419
54419
|
releaseId: getReleaseIdFromReleaseDocumentId(release._id),
|
|
@@ -54430,13 +54430,13 @@ function ConfirmScheduledDraftsDialog(t0) {
|
|
|
54430
54430
|
scheduleActiveDrafts
|
|
54431
54431
|
} = useScheduleActiveDrafts(), [isScheduling, setIsScheduling] = useState(!1), [scrollContainerRef, setScrollContainerRef] = useState(null);
|
|
54432
54432
|
let t1;
|
|
54433
|
-
$[0] !== activeScheduledDrafts ? (t1 = activeScheduledDrafts.map(_temp2$
|
|
54433
|
+
$[0] !== activeScheduledDrafts ? (t1 = activeScheduledDrafts.map(_temp2$G), $[0] = activeScheduledDrafts, $[1] = t1) : t1 = $[1];
|
|
54434
54434
|
const tableData = t1;
|
|
54435
54435
|
let t2;
|
|
54436
54436
|
$[2] !== t ? (t2 = confirmScheduledDraftsColumnDefs(t), $[2] = t, $[3] = t2) : t2 = $[3];
|
|
54437
54437
|
const columnDefs = t2;
|
|
54438
54438
|
let t3;
|
|
54439
|
-
$[4] !== activeScheduledDrafts ? (t3 = activeScheduledDrafts.some(_temp3$
|
|
54439
|
+
$[4] !== activeScheduledDrafts ? (t3 = activeScheduledDrafts.some(_temp3$n), $[4] = activeScheduledDrafts, $[5] = t3) : t3 = $[5];
|
|
54440
54440
|
const hasPastDates = t3;
|
|
54441
54441
|
let t4;
|
|
54442
54442
|
$[6] !== activeScheduledDrafts || $[7] !== onClose || $[8] !== scheduleActiveDrafts || $[9] !== t || $[10] !== toast ? (t4 = async () => {
|
|
@@ -54498,10 +54498,10 @@ function ConfirmScheduledDraftsDialog(t0) {
|
|
|
54498
54498
|
let t16;
|
|
54499
54499
|
return $[41] !== onClose || $[42] !== t15 || $[43] !== t5 || $[44] !== t7 ? (t16 = /* @__PURE__ */ jsx(Dialog, { id: "confirm-active-scheduled-drafts-dialog", header: t5, onClose, width: 2, padding: !1, footer: t7, children: t15 }), $[41] = onClose, $[42] = t15, $[43] = t5, $[44] = t7, $[45] = t16) : t16 = $[45], t16;
|
|
54500
54500
|
}
|
|
54501
|
-
function _temp3$
|
|
54501
|
+
function _temp3$n(release_0) {
|
|
54502
54502
|
return release_0.metadata.intendedPublishAt && isPast(new Date(release_0.metadata.intendedPublishAt));
|
|
54503
54503
|
}
|
|
54504
|
-
function _temp2$
|
|
54504
|
+
function _temp2$G(release) {
|
|
54505
54505
|
return {
|
|
54506
54506
|
...release,
|
|
54507
54507
|
publishAt: release.metadata.intendedPublishAt
|
|
@@ -54514,7 +54514,7 @@ function ConfirmActiveScheduledDraftsBanner(t0) {
|
|
|
54514
54514
|
t
|
|
54515
54515
|
} = useTranslation(releasesLocaleNamespace), [isDialogOpen, setIsDialogOpen] = useState(!1);
|
|
54516
54516
|
let t1;
|
|
54517
|
-
$[0] !== releases2 ? (t1 = releases2.filter(_temp$
|
|
54517
|
+
$[0] !== releases2 ? (t1 = releases2.filter(_temp$1E), $[0] = releases2, $[1] = t1) : t1 = $[1];
|
|
54518
54518
|
const activeScheduledDrafts = t1;
|
|
54519
54519
|
let t2;
|
|
54520
54520
|
$[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t2 = () => {
|
|
@@ -54554,7 +54554,7 @@ function ConfirmActiveScheduledDraftsBanner(t0) {
|
|
|
54554
54554
|
t10
|
|
54555
54555
|
] }), $[20] = t10, $[21] = t9, $[22] = t11) : t11 = $[22], t11;
|
|
54556
54556
|
}
|
|
54557
|
-
function _temp$
|
|
54557
|
+
function _temp$1E(release) {
|
|
54558
54558
|
return release.state === "active" && isCardinalityOneRelease(release);
|
|
54559
54559
|
}
|
|
54560
54560
|
const DraftsDisabledBanner = (t0) => {
|
|
@@ -55708,7 +55708,7 @@ const ScheduledDraftMenuButtonWrapper = (t0) => {
|
|
|
55708
55708
|
const displayedMenuItems = t5, canPerformActions = !!scheduledDraftDocument;
|
|
55709
55709
|
let t6;
|
|
55710
55710
|
$[17] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t6 = () => {
|
|
55711
|
-
setOpenPopover(_temp$
|
|
55711
|
+
setOpenPopover(_temp$1D);
|
|
55712
55712
|
}, $[17] = t6) : t6 = $[17];
|
|
55713
55713
|
const handleOnButtonClick = t6;
|
|
55714
55714
|
let t7, t8;
|
|
@@ -55737,7 +55737,7 @@ const ScheduledDraftMenuButtonWrapper = (t0) => {
|
|
|
55737
55737
|
dialogs
|
|
55738
55738
|
] }), $[38] = dialogs, $[39] = t17, $[40] = t18) : t18 = $[40], t18;
|
|
55739
55739
|
};
|
|
55740
|
-
function _temp$
|
|
55740
|
+
function _temp$1D(prev) {
|
|
55741
55741
|
return !prev;
|
|
55742
55742
|
}
|
|
55743
55743
|
const singleDocReleaseNamespace = "singleDocRelease", singleDocReleaseUsEnglishLocaleBundle = {
|
|
@@ -56023,7 +56023,7 @@ function ReleasesOverview() {
|
|
|
56023
56023
|
$[11] !== allArchivedReleases || $[12] !== cardinalityView ? (t4 = allArchivedReleases.filter(shouldShowReleaseInView(cardinalityView)), $[11] = allArchivedReleases, $[12] = cardinalityView, $[13] = t4) : t4 = $[13];
|
|
56024
56024
|
const archivedReleases = t4;
|
|
56025
56025
|
let t5;
|
|
56026
|
-
$[14] !== releases2 ? (t5 = releases2.map(_temp$
|
|
56026
|
+
$[14] !== releases2 ? (t5 = releases2.map(_temp$1C), $[14] = releases2, $[15] = t5) : t5 = $[15];
|
|
56027
56027
|
const releaseIds = t5, {
|
|
56028
56028
|
data: releasesMetadata,
|
|
56029
56029
|
loading: loadingReleasesMetadata
|
|
@@ -56053,7 +56053,7 @@ function ReleasesOverview() {
|
|
|
56053
56053
|
}, $[16] = selectedPerspective, $[17] = t6) : t6 = $[17];
|
|
56054
56054
|
const getRowProps = t6, [scrollContainerRef, setScrollContainerRef] = useState(null), hasReleases = releases2.length > 0 || archivedReleases.length > 0, showDraftsDisabledBanner = cardinalityView === "drafts" && (!isDraftModelEnabled || !isScheduledDraftsEnabled);
|
|
56055
56055
|
let t7;
|
|
56056
|
-
$[18] !== cardinalityView || $[19] !== releases2 ? (t7 = cardinalityView === "drafts" && releases2.some(_temp2$
|
|
56056
|
+
$[18] !== cardinalityView || $[19] !== releases2 ? (t7 = cardinalityView === "drafts" && releases2.some(_temp2$F), $[18] = cardinalityView, $[19] = releases2, $[20] = t7) : t7 = $[20];
|
|
56057
56057
|
const showConfirmActiveScheduledDraftsBanner = t7, loadingOrHasReleases = loading || hasReleases, hasNoReleases = !loading && !hasReleases;
|
|
56058
56058
|
let t8;
|
|
56059
56059
|
bb0: {
|
|
@@ -56221,7 +56221,7 @@ function ReleasesOverview() {
|
|
|
56221
56221
|
let t38;
|
|
56222
56222
|
bb2: {
|
|
56223
56223
|
let t392;
|
|
56224
|
-
$[95] !== cardinalityView ? (t392 = (items) => cardinalityView === "drafts" ? items.filter(_temp3$
|
|
56224
|
+
$[95] !== cardinalityView ? (t392 = (items) => cardinalityView === "drafts" ? items.filter(_temp3$m) : items, $[95] = cardinalityView, $[96] = t392) : t392 = $[96];
|
|
56225
56225
|
const filterActiveIfNeeded = t392;
|
|
56226
56226
|
if (!releaseFilterDate) {
|
|
56227
56227
|
const t403 = releaseGroupMode === "active" ? tableReleases : archivedReleases;
|
|
@@ -56348,13 +56348,13 @@ function ReleasesOverview() {
|
|
|
56348
56348
|
t64
|
|
56349
56349
|
] }), $[201] = t63, $[202] = t64, $[203] = t65) : t65 = $[203], t65;
|
|
56350
56350
|
}
|
|
56351
|
-
function _temp3$
|
|
56351
|
+
function _temp3$m(release_3) {
|
|
56352
56352
|
return release_3.state !== "active";
|
|
56353
56353
|
}
|
|
56354
|
-
function _temp2$
|
|
56354
|
+
function _temp2$F(release_0) {
|
|
56355
56355
|
return release_0.state === "active" && isCardinalityOneRelease(release_0);
|
|
56356
56356
|
}
|
|
56357
|
-
function _temp$
|
|
56357
|
+
function _temp$1C(release) {
|
|
56358
56358
|
return release._id;
|
|
56359
56359
|
}
|
|
56360
56360
|
function ReleasesTool() {
|
|
@@ -56619,9 +56619,9 @@ const SINGLE_DOC_RELEASE_NAME = "sanity/singleDocRelease", RELEASES_SCHEDULED_DR
|
|
|
56619
56619
|
function useReleasesToolAvailable() {
|
|
56620
56620
|
const $ = c(2), workspace = useWorkspace();
|
|
56621
56621
|
let t0;
|
|
56622
|
-
return $[0] !== workspace.tools ? (t0 = workspace.tools.some(_temp$
|
|
56622
|
+
return $[0] !== workspace.tools ? (t0 = workspace.tools.some(_temp$1B), $[0] = workspace.tools, $[1] = t0) : t0 = $[1], t0;
|
|
56623
56623
|
}
|
|
56624
|
-
function _temp$
|
|
56624
|
+
function _temp$1B(t0) {
|
|
56625
56625
|
const {
|
|
56626
56626
|
name
|
|
56627
56627
|
} = t0;
|
|
@@ -56841,7 +56841,7 @@ const useHasCopyToDraftOption = (documentType, fromRelease) => {
|
|
|
56841
56841
|
t
|
|
56842
56842
|
} = useTranslation(), hasCopyToDraftOption = useHasCopyToDraftOption(documentType, fromRelease), isCopyToReleaseDisabled = disabled || !hasCreatePermission || isGoingToUnpublish2;
|
|
56843
56843
|
let t1;
|
|
56844
|
-
$[0] !== releases2 ? (t1 = releases2.filter(_temp$
|
|
56844
|
+
$[0] !== releases2 ? (t1 = releases2.filter(_temp$1A), $[0] = releases2, $[1] = t1) : t1 = $[1];
|
|
56845
56845
|
const copyToReleaseOptions = t1, showCopyToReleaseMenuItem = copyToReleaseOptions.length > 0 || hasCopyToDraftOption;
|
|
56846
56846
|
let t2;
|
|
56847
56847
|
$[2] !== disabled || $[3] !== fromRelease || $[4] !== isVersion || $[5] !== t ? (t2 = isVersion && /* @__PURE__ */ jsx(IntentLink, { intent: RELEASES_INTENT, params: {
|
|
@@ -56869,7 +56869,7 @@ const useHasCopyToDraftOption = (documentType, fromRelease) => {
|
|
|
56869
56869
|
t6
|
|
56870
56870
|
] }), $[32] = t2, $[33] = t3, $[34] = t4, $[35] = t5, $[36] = t6, $[37] = t7) : t7 = $[37], t7;
|
|
56871
56871
|
});
|
|
56872
|
-
function _temp$
|
|
56872
|
+
function _temp$1A(r) {
|
|
56873
56873
|
return !isReleaseScheduledOrScheduling(r);
|
|
56874
56874
|
}
|
|
56875
56875
|
const ScheduledDraftContextMenu = memo(function(props2) {
|
|
@@ -56890,7 +56890,7 @@ const ScheduledDraftContextMenu = memo(function(props2) {
|
|
|
56890
56890
|
t
|
|
56891
56891
|
} = useTranslation(), hasCopyToDraftOption = useHasCopyToDraftOption(documentType, fromRelease), isCopyToReleaseDisabled = disabled || !hasCreatePermission || isGoingToUnpublish2;
|
|
56892
56892
|
let t1;
|
|
56893
|
-
$[0] !== releases2 ? (t1 = releases2.filter(_temp$
|
|
56893
|
+
$[0] !== releases2 ? (t1 = releases2.filter(_temp$1z), $[0] = releases2, $[1] = t1) : t1 = $[1];
|
|
56894
56894
|
const copyToReleaseOptions = t1, showCopyToReleaseMenuItem = copyToReleaseOptions.length > 0 || hasCopyToDraftOption, {
|
|
56895
56895
|
actions
|
|
56896
56896
|
} = scheduledDraftMenuActions;
|
|
@@ -56929,7 +56929,7 @@ const ScheduledDraftContextMenu = memo(function(props2) {
|
|
|
56929
56929
|
t10
|
|
56930
56930
|
] }), $[27] = t10, $[28] = t2, $[29] = t3, $[30] = t7, $[31] = t9, $[32] = t11) : t11 = $[32], t11;
|
|
56931
56931
|
});
|
|
56932
|
-
function _temp$
|
|
56932
|
+
function _temp$1z(r) {
|
|
56933
56933
|
return !isReleaseScheduledOrScheduling(r);
|
|
56934
56934
|
}
|
|
56935
56935
|
const VersionContextMenu = memo(function(props2) {
|
|
@@ -57087,7 +57087,7 @@ function CopyToNewReleaseDialog(props2) {
|
|
|
57087
57087
|
let t7;
|
|
57088
57088
|
$[16] !== clearReleaseDataFromStorage || $[17] !== createRelease || $[18] !== createReleaseMetadata || $[19] !== handleAddVersion || $[20] !== onClose || $[21] !== release || $[22] !== releasePromise || $[23] !== setRerenderDialog || $[24] !== t || $[25] !== telemetry || $[26] !== toast ? (t7 = async () => {
|
|
57089
57089
|
if (getIsScheduledDateInPast(release)) {
|
|
57090
|
-
setRerenderDialog(_temp$
|
|
57090
|
+
setRerenderDialog(_temp$1y);
|
|
57091
57091
|
return;
|
|
57092
57092
|
}
|
|
57093
57093
|
if (setIsSubmitting(!0), !await releasePromise) {
|
|
@@ -57178,7 +57178,7 @@ function CopyToNewReleaseDialog(props2) {
|
|
|
57178
57178
|
t25
|
|
57179
57179
|
] }), $[73] = handleOnClose, $[74] = onClose, $[75] = t16, $[76] = t25, $[77] = t9, $[78] = t26) : t26 = $[78], t26;
|
|
57180
57180
|
}
|
|
57181
|
-
function _temp$
|
|
57181
|
+
function _temp$1y(cur) {
|
|
57182
57182
|
return cur + 1;
|
|
57183
57183
|
}
|
|
57184
57184
|
const ChipButtonContainer = styled.span`
|
|
@@ -57389,7 +57389,7 @@ function DocumentPreviewPresence(props2) {
|
|
|
57389
57389
|
data: releases2
|
|
57390
57390
|
} = useActiveReleases();
|
|
57391
57391
|
let t0;
|
|
57392
|
-
$[0] !== presence ? (t0 = Array.from(new Set(presence.map(_temp$
|
|
57392
|
+
$[0] !== presence ? (t0 = Array.from(new Set(presence.map(_temp$1x))), $[0] = presence, $[1] = t0) : t0 = $[1];
|
|
57393
57393
|
let t1;
|
|
57394
57394
|
$[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];
|
|
57395
57395
|
const uniquePresence = t1;
|
|
@@ -57420,16 +57420,16 @@ function DocumentPreviewPresence(props2) {
|
|
|
57420
57420
|
}
|
|
57421
57421
|
const tooltipContent = t2;
|
|
57422
57422
|
let t3;
|
|
57423
|
-
$[13] !== uniquePresence ? (t3 = uniquePresence.map(_temp2$
|
|
57423
|
+
$[13] !== uniquePresence ? (t3 = uniquePresence.map(_temp2$E), $[13] = uniquePresence, $[14] = t3) : t3 = $[14];
|
|
57424
57424
|
let t4;
|
|
57425
57425
|
$[15] !== t3 || $[16] !== tooltipContent ? (t4 = /* @__PURE__ */ jsx(AvatarStackBox, { children: /* @__PURE__ */ jsx(AvatarStack, { maxLength: 2, "aria-label": tooltipContent, size: 0, children: t3 }) }), $[15] = t3, $[16] = tooltipContent, $[17] = t4) : t4 = $[17];
|
|
57426
57426
|
let t5;
|
|
57427
57427
|
return $[18] !== t4 || $[19] !== tooltipContent ? (t5 = /* @__PURE__ */ jsx(Tooltip, { content: tooltipContent, ...PRESENCE_MENU_POPOVER_PROPS, children: t4 }), $[18] = t4, $[19] = tooltipContent, $[20] = t5) : t5 = $[20], t5;
|
|
57428
57428
|
}
|
|
57429
|
-
function _temp2$
|
|
57429
|
+
function _temp2$E(item) {
|
|
57430
57430
|
return /* @__PURE__ */ jsx(UserAvatar, { size: 0, user: item.user }, item.user.id);
|
|
57431
57431
|
}
|
|
57432
|
-
function _temp$
|
|
57432
|
+
function _temp$1x(a) {
|
|
57433
57433
|
return a.user.id;
|
|
57434
57434
|
}
|
|
57435
57435
|
const EMPTY_ARRAY$h = [];
|
|
@@ -57659,7 +57659,7 @@ function useFormState(t0) {
|
|
|
57659
57659
|
perspective,
|
|
57660
57660
|
hasUpstreamVersion,
|
|
57661
57661
|
displayInlineChanges
|
|
57662
|
-
} = t0, currentUser = useCurrentUser(), [prepareHiddenState] = useState(_temp$
|
|
57662
|
+
} = t0, currentUser = useCurrentUser(), [prepareHiddenState] = useState(_temp$1w), [prepareReadOnlyState] = useState(_temp2$D), [prepareFormState] = useState(_temp3$l), [reconcileFieldGroupState] = useState(_temp4$9);
|
|
57663
57663
|
let t1;
|
|
57664
57664
|
$[0] !== fieldGroupState || $[1] !== reconcileFieldGroupState ? (t1 = reconcileFieldGroupState(fieldGroupState), $[0] = fieldGroupState, $[1] = reconcileFieldGroupState, $[2] = t1) : t1 = $[2];
|
|
57665
57665
|
const reconciledFieldGroupState = t1, [reconcileCollapsedPaths] = useState(_temp5$6);
|
|
@@ -57733,15 +57733,15 @@ function _temp4$9() {
|
|
|
57733
57733
|
return last2 = result, result;
|
|
57734
57734
|
};
|
|
57735
57735
|
}
|
|
57736
|
-
function _temp3$
|
|
57736
|
+
function _temp3$l() {
|
|
57737
57737
|
return createPrepareFormState();
|
|
57738
57738
|
}
|
|
57739
|
-
function _temp2$
|
|
57739
|
+
function _temp2$D() {
|
|
57740
57740
|
return createCallbackResolver({
|
|
57741
57741
|
property: "readOnly"
|
|
57742
57742
|
});
|
|
57743
57743
|
}
|
|
57744
|
-
function _temp$
|
|
57744
|
+
function _temp$1w() {
|
|
57745
57745
|
return createCallbackResolver({
|
|
57746
57746
|
property: "hidden"
|
|
57747
57747
|
});
|
|
@@ -57836,15 +57836,15 @@ const INITIAL$1 = "connecting";
|
|
|
57836
57836
|
function useConnectionState(publishedDocId, docTypeName, version2) {
|
|
57837
57837
|
const $ = c(5), documentStore = useDocumentStore();
|
|
57838
57838
|
let t0;
|
|
57839
|
-
return $[0] !== docTypeName || $[1] !== documentStore.pair || $[2] !== publishedDocId || $[3] !== version2 ? (t0 = documentStore.pair.documentEvents(publishedDocId, docTypeName, version2).pipe(map(_temp$
|
|
57839
|
+
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);
|
|
57840
57840
|
}
|
|
57841
|
-
function _temp3$
|
|
57841
|
+
function _temp3$k(isConnected) {
|
|
57842
57842
|
return isConnected ? of("connected") : timer(200).pipe(mapTo("reconnecting"));
|
|
57843
57843
|
}
|
|
57844
|
-
function _temp2$
|
|
57844
|
+
function _temp2$C(eventType) {
|
|
57845
57845
|
return eventType !== "reconnect";
|
|
57846
57846
|
}
|
|
57847
|
-
function _temp$
|
|
57847
|
+
function _temp$1v(ev) {
|
|
57848
57848
|
return ev.type;
|
|
57849
57849
|
}
|
|
57850
57850
|
function useFilteredReleases(t0) {
|
|
@@ -57880,7 +57880,7 @@ function useFilteredReleases(t0) {
|
|
|
57880
57880
|
break bb0;
|
|
57881
57881
|
}
|
|
57882
57882
|
if ($[13] !== archivedReleases || $[14] !== displayed || $[15] !== documentVersions || $[16] !== historyVersion || $[17] !== isCreatingDocument || $[18] !== releases2 || $[19] !== selectedReleaseId || $[20] !== strict) {
|
|
57883
|
-
const releasesIds = documentVersions.map(_temp$
|
|
57883
|
+
const releasesIds = documentVersions.map(_temp$1u);
|
|
57884
57884
|
if (activeReleases = releases2.reduce((acc, release) => {
|
|
57885
57885
|
const versionDocExists = releasesIds.includes(getReleaseIdFromReleaseDocumentId(release._id)), releaseId = getReleaseIdFromReleaseDocumentId(release._id);
|
|
57886
57886
|
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;
|
|
@@ -57902,7 +57902,7 @@ function useFilteredReleases(t0) {
|
|
|
57902
57902
|
activeReleases = $[11], t3 = $[12];
|
|
57903
57903
|
return t3 !== /* @__PURE__ */ Symbol.for("react.early_return_sentinel") ? t3 : activeReleases;
|
|
57904
57904
|
}
|
|
57905
|
-
function _temp$
|
|
57905
|
+
function _temp$1u(id2) {
|
|
57906
57906
|
return getVersionFromId(id2);
|
|
57907
57907
|
}
|
|
57908
57908
|
function useDocumentIdStack(t0) {
|
|
@@ -57934,7 +57934,7 @@ function useDocumentIdStack(t0) {
|
|
|
57934
57934
|
let t72;
|
|
57935
57935
|
$[13] !== editState2 ? (t72 = (release) => editState2?.id && getVersionId(editState2.id, getReleaseIdFromReleaseDocumentId(release._id)), $[13] = editState2, $[14] = t72) : t72 = $[14];
|
|
57936
57936
|
const releaseStack = filteredReleases.currentReleases.map(t72);
|
|
57937
|
-
t6 = systemStack.concat(releaseStack).filter(_temp$
|
|
57937
|
+
t6 = systemStack.concat(releaseStack).filter(_temp$1t), $[8] = editState2, $[9] = filteredReleases.currentReleases, $[10] = shouldIncludeDraft, $[11] = t5, $[12] = t6;
|
|
57938
57938
|
} else
|
|
57939
57939
|
t6 = $[12];
|
|
57940
57940
|
const stack = t6;
|
|
@@ -57949,7 +57949,7 @@ function useDocumentIdStack(t0) {
|
|
|
57949
57949
|
stack
|
|
57950
57950
|
}, $[17] = nextId, $[18] = position, $[19] = previousId, $[20] = stack, $[21] = t8) : t8 = $[21], t8;
|
|
57951
57951
|
}
|
|
57952
|
-
function _temp$
|
|
57952
|
+
function _temp$1t(id2) {
|
|
57953
57953
|
return typeof id2 == "string";
|
|
57954
57954
|
}
|
|
57955
57955
|
function useActiveWorkspace() {
|
|
@@ -58106,7 +58106,7 @@ function useEditState(publishedDocId, docTypeName, t0, version2) {
|
|
|
58106
58106
|
let t22;
|
|
58107
58107
|
if ($[0] !== docTypeName || $[1] !== documentStore.pair || $[2] !== publishedDocId || $[3] !== version2) {
|
|
58108
58108
|
const base = documentStore.pair.editState(publishedDocId, docTypeName, version2).pipe(share$1());
|
|
58109
|
-
t22 = merge(base.pipe(take(1)), base.pipe(skip$1(1), debounce$2(_temp$
|
|
58109
|
+
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;
|
|
58110
58110
|
} else
|
|
58111
58111
|
t22 = $[4];
|
|
58112
58112
|
t1 = t22;
|
|
@@ -58117,7 +58117,7 @@ function useEditState(publishedDocId, docTypeName, t0, version2) {
|
|
|
58117
58117
|
}
|
|
58118
58118
|
return useObservable(t1);
|
|
58119
58119
|
}
|
|
58120
|
-
function _temp$
|
|
58120
|
+
function _temp$1s() {
|
|
58121
58121
|
return timer(1e3);
|
|
58122
58122
|
}
|
|
58123
58123
|
const INITIAL = {
|
|
@@ -58339,13 +58339,13 @@ function useDocumentForm(options) {
|
|
|
58339
58339
|
$[75] !== t23 ? (t24 = t23(), $[75] = t23, $[76] = t24) : t24 = $[76];
|
|
58340
58340
|
const readOnly = t24, {
|
|
58341
58341
|
patch: patch2
|
|
58342
|
-
} = useDocumentOperation(documentId, documentType, releaseId), patchRef = useRef(_temp$
|
|
58342
|
+
} = useDocumentOperation(documentId, documentType, releaseId), patchRef = useRef(_temp$1r);
|
|
58343
58343
|
let t25;
|
|
58344
58344
|
$[77] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (t25 = (event) => patchRef.current(event), $[77] = t25) : t25 = $[77];
|
|
58345
58345
|
const handleChange = t25;
|
|
58346
58346
|
let t26;
|
|
58347
58347
|
$[78] !== editState2.draft || $[79] !== editState2.published || $[80] !== initialValue?.value || $[81] !== isCreateLinked || $[82] !== patch2 || $[83] !== readOnly || $[84] !== telemetry ? (t26 = () => {
|
|
58348
|
-
readOnly && !isCreateLinked ? patchRef.current = _temp2$
|
|
58348
|
+
readOnly && !isCreateLinked ? patchRef.current = _temp2$B : patchRef.current = (event_0) => {
|
|
58349
58349
|
!editState2.draft && !editState2.published && telemetry.log(CreatedDraft), patch2.execute(toMutationPatches(event_0.patches), initialValue?.value);
|
|
58350
58350
|
};
|
|
58351
58351
|
}, $[78] = editState2.draft, $[79] = editState2.published, $[80] = initialValue?.value, $[81] = isCreateLinked, $[82] = patch2, $[83] = readOnly, $[84] = telemetry, $[85] = t26) : t26 = $[85];
|
|
@@ -58422,7 +58422,7 @@ function useDocumentForm(options) {
|
|
|
58422
58422
|
if (setFocusPath(pathFor(nextFocusPath_0)), enhancedObjectDialogEnabled) {
|
|
58423
58423
|
const lastSegment = nextFocusPath_0[nextFocusPath_0.length - 1];
|
|
58424
58424
|
if (!isKeySegment(lastSegment)) {
|
|
58425
|
-
const lastKeyIndex = nextFocusPath_0.findLastIndex(_temp3$
|
|
58425
|
+
const lastKeyIndex = nextFocusPath_0.findLastIndex(_temp3$j), newOpenPath = lastKeyIndex >= 0 ? nextFocusPath_0.slice(0, lastKeyIndex + 1) : nextFocusPath_0.slice(0, -1);
|
|
58426
58426
|
document.getElementById(`${pathToString$1(nextFocusPath_0)}`) || handleSetOpenPath(pathFor(newOpenPath));
|
|
58427
58427
|
}
|
|
58428
58428
|
} else
|
|
@@ -58470,13 +58470,13 @@ function useDocumentForm(options) {
|
|
|
58470
58470
|
onSetCollapsedFieldSet: handleOnSetCollapsedFieldSet
|
|
58471
58471
|
}, $[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;
|
|
58472
58472
|
}
|
|
58473
|
-
function _temp3$
|
|
58473
|
+
function _temp3$j(seg) {
|
|
58474
58474
|
return isKeySegment(seg);
|
|
58475
58475
|
}
|
|
58476
|
-
function _temp2$
|
|
58476
|
+
function _temp2$B() {
|
|
58477
58477
|
throw new Error("Attempted to patch a read-only document");
|
|
58478
58478
|
}
|
|
58479
|
-
function _temp$
|
|
58479
|
+
function _temp$1r() {
|
|
58480
58480
|
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.");
|
|
58481
58481
|
}
|
|
58482
58482
|
const IS_NUMERIC = /^\d+$/;
|
|
@@ -58821,7 +58821,7 @@ function SelectAssetsDialog(props2) {
|
|
|
58821
58821
|
i18n: workspace.i18n,
|
|
58822
58822
|
environment: "studio",
|
|
58823
58823
|
document: document2,
|
|
58824
|
-
getDocumentExists: _temp$
|
|
58824
|
+
getDocumentExists: _temp$1q
|
|
58825
58825
|
});
|
|
58826
58826
|
return filterMediaValidationMarkers(result);
|
|
58827
58827
|
}, $[4] = client, $[5] = document2, $[6] = mediaLibraryIds?.libraryId, $[7] = schema2, $[8] = schemaType, $[9] = workspace.i18n, $[10] = t4) : t4 = $[10];
|
|
@@ -58829,7 +58829,7 @@ function SelectAssetsDialog(props2) {
|
|
|
58829
58829
|
let t5;
|
|
58830
58830
|
$[11] !== schemaType?.options?.mediaLibrary?.filters ? (t5 = schemaType?.options?.mediaLibrary?.filters || [], $[11] = schemaType?.options?.mediaLibrary?.filters, $[12] = t5) : t5 = $[12];
|
|
58831
58831
|
let t6;
|
|
58832
|
-
$[13] !== t5 ? (t6 = t5.map(_temp2$
|
|
58832
|
+
$[13] !== t5 ? (t6 = t5.map(_temp2$A), $[13] = t5, $[14] = t6) : t6 = $[14];
|
|
58833
58833
|
const pluginFilters = t6, t7 = selectAssetType === "sanity.video" ? "video" : selectAssetType;
|
|
58834
58834
|
let t8;
|
|
58835
58835
|
$[15] !== t7 ? (t8 = [t7], $[15] = t7, $[16] = t8) : t8 = $[16];
|
|
@@ -58879,7 +58879,7 @@ function SelectAssetsDialog(props2) {
|
|
|
58879
58879
|
return;
|
|
58880
58880
|
}
|
|
58881
58881
|
const validationResult = await validateSelection(assetSelectionItems[0]);
|
|
58882
|
-
validationResult.some(_temp3$
|
|
58882
|
+
validationResult.some(_temp3$i) && setValidation(validationResult);
|
|
58883
58883
|
}, $[34] = validateSelection, $[35] = t14) : t14 = $[35];
|
|
58884
58884
|
const handleAssetSelection = t14;
|
|
58885
58885
|
let t15;
|
|
@@ -58931,10 +58931,10 @@ function SelectAssetsDialog(props2) {
|
|
|
58931
58931
|
function _temp4$8(marker_0) {
|
|
58932
58932
|
return marker_0.level === "error";
|
|
58933
58933
|
}
|
|
58934
|
-
function _temp3$
|
|
58934
|
+
function _temp3$i(marker) {
|
|
58935
58935
|
return marker.level === "error";
|
|
58936
58936
|
}
|
|
58937
|
-
function _temp2$
|
|
58937
|
+
function _temp2$A(filter2) {
|
|
58938
58938
|
return {
|
|
58939
58939
|
type: "groq",
|
|
58940
58940
|
name: filter2.name,
|
|
@@ -58942,7 +58942,7 @@ function _temp2$z(filter2) {
|
|
|
58942
58942
|
active: !0
|
|
58943
58943
|
};
|
|
58944
58944
|
}
|
|
58945
|
-
async function _temp$
|
|
58945
|
+
async function _temp$1q() {
|
|
58946
58946
|
return !0;
|
|
58947
58947
|
}
|
|
58948
58948
|
function UploadAssetsDialog(props2) {
|
|
@@ -59002,12 +59002,12 @@ function UploadAssetsDialog(props2) {
|
|
|
59002
59002
|
let t3, t4;
|
|
59003
59003
|
if ($[12] !== open || $[13] !== pageReadyForUploads || $[14] !== postMessage || $[15] !== t || $[16] !== toast || $[17] !== uploader ? (t3 = () => {
|
|
59004
59004
|
if (open && uploader) {
|
|
59005
|
-
pageReadyForUploads && uploader.getFiles().length > 0 && uploader.getFiles().every(_temp$
|
|
59005
|
+
pageReadyForUploads && uploader.getFiles().length > 0 && uploader.getFiles().every(_temp$1p) && (postMessage({
|
|
59006
59006
|
type: "uploadRequest",
|
|
59007
59007
|
files: uploader.getFiles()
|
|
59008
59008
|
}), setPageReadyForUploads(!1));
|
|
59009
59009
|
const subscribe2 = () => uploader.subscribe((event) => {
|
|
59010
|
-
event.type === "all-complete" && event.files.filter(_temp2$
|
|
59010
|
+
event.type === "all-complete" && event.files.filter(_temp2$z).forEach((file_1) => {
|
|
59011
59011
|
toast.push({
|
|
59012
59012
|
status: "warning",
|
|
59013
59013
|
title: t("asset-sources.media-library.warning.file-already-exist.title", {
|
|
@@ -59035,10 +59035,10 @@ function UploadAssetsDialog(props2) {
|
|
|
59035
59035
|
let t5;
|
|
59036
59036
|
return $[20] !== iframeUrl || $[21] !== setIframe ? (t5 = /* @__PURE__ */ jsx(Iframe, { ref: setIframe, src: iframeUrl, hidden: !0 }), $[20] = iframeUrl, $[21] = setIframe, $[22] = t5) : t5 = $[22], t5;
|
|
59037
59037
|
}
|
|
59038
|
-
function _temp2$
|
|
59038
|
+
function _temp2$z(file_0) {
|
|
59039
59039
|
return file_0.status === "alreadyExists";
|
|
59040
59040
|
}
|
|
59041
|
-
function _temp$
|
|
59041
|
+
function _temp$1p(file) {
|
|
59042
59042
|
return file.status === "pending";
|
|
59043
59043
|
}
|
|
59044
59044
|
const MediaLibraryAssetSourceComponent = function(props2, ref) {
|
|
@@ -59085,13 +59085,13 @@ const MediaLibraryAssetSourceComponent = function(props2, ref) {
|
|
|
59085
59085
|
t10
|
|
59086
59086
|
] }), $[26] = libraryIdProp, $[27] = projectId, $[28] = t10, $[29] = t5, $[30] = t11) : t11 = $[30], t11;
|
|
59087
59087
|
}, MediaLibraryAssetSource = memo(forwardRef(MediaLibraryAssetSourceComponent)), useRootPortalElement = () => {
|
|
59088
|
-
const $ = c(3), [container] = useState(_temp$
|
|
59088
|
+
const $ = c(3), [container] = useState(_temp$1o);
|
|
59089
59089
|
let t0, t1;
|
|
59090
59090
|
return $[0] !== container ? (t0 = () => (container.classList.add("media-library-portal"), document.body.appendChild(container), () => {
|
|
59091
59091
|
document.body.removeChild(container);
|
|
59092
59092
|
}), t1 = [container], $[0] = container, $[1] = t0, $[2] = t1) : (t0 = $[1], t1 = $[2]), useEffect(t0, t1), container;
|
|
59093
59093
|
};
|
|
59094
|
-
function _temp$
|
|
59094
|
+
function _temp$1o() {
|
|
59095
59095
|
return document.createElement("div");
|
|
59096
59096
|
}
|
|
59097
59097
|
class MediaLibraryUploader {
|
|
@@ -59219,24 +59219,56 @@ function pseudoRandomNumber(seed) {
|
|
|
59219
59219
|
const hashCode = seed.split("").reduce((prevHash, currVal) => (prevHash << 5) - prevHash + currVal.charCodeAt(0) | 0, 0);
|
|
59220
59220
|
return Math.abs(hashCode * 16807 % 2147483647) / 2147483647;
|
|
59221
59221
|
}
|
|
59222
|
-
const
|
|
59223
|
-
|
|
59224
|
-
|
|
59225
|
-
|
|
59226
|
-
|
|
59227
|
-
theme
|
|
59228
|
-
|
|
59229
|
-
|
|
59230
|
-
|
|
59231
|
-
|
|
59232
|
-
|
|
59233
|
-
|
|
59222
|
+
const possibleTints = ["300", "400", "500", "600", "700"];
|
|
59223
|
+
function DefaultIcon(t0) {
|
|
59224
|
+
const $ = c(22), {
|
|
59225
|
+
title,
|
|
59226
|
+
subtitle
|
|
59227
|
+
} = 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`;
|
|
59228
|
+
let t1;
|
|
59229
|
+
$[0] !== subtitle || $[1] !== title ? (t1 = () => pseudoRandomNumber(`${title} ${subtitle}`), $[0] = subtitle, $[1] = title, $[2] = t1) : t1 = $[2];
|
|
59230
|
+
const [rng1] = useState(t1), huesWithoutGray = COLOR_HUES.filter(_temp$1n), colorHue = huesWithoutGray[Math.floor(rng1 * huesWithoutGray.length)];
|
|
59231
|
+
let t2;
|
|
59232
|
+
$[3] !== rng1 ? (t2 = () => pseudoRandomNumber(rng1.toString()), $[3] = rng1, $[4] = t2) : t2 = $[4];
|
|
59233
|
+
const [rng2] = useState(t2), tint = possibleTints[Math.floor(rng2 * possibleTints.length)], color = hues[colorHue][tint].hex;
|
|
59234
|
+
let t3;
|
|
59235
|
+
$[5] !== title ? (t3 = title.split(/\s/g).map(_temp2$y).filter(Boolean).slice(0, 2).map(_temp3$h), $[5] = title, $[6] = t3) : t3 = $[6];
|
|
59236
|
+
const letters = t3;
|
|
59237
|
+
let t4;
|
|
59238
|
+
if ($[7] !== color) {
|
|
59239
|
+
const darkened = darken(color, 0.4), lightened = lighten(color, 0.4);
|
|
59240
|
+
t4 = hasBadContrast(color, "readable", darkened) ? hasBadContrast(color, "readable", lightened) ? readableColor(color) : lightened : darkened, $[7] = color, $[8] = t4;
|
|
59241
|
+
} else
|
|
59242
|
+
t4 = $[8];
|
|
59243
|
+
const textColor = t4;
|
|
59244
|
+
let t5;
|
|
59245
|
+
$[9] !== color ? (t5 = /* @__PURE__ */ jsx("rect", { width: 32, height: 32, rx: 2, fill: color }), $[9] = color, $[10] = t5) : t5 = $[10];
|
|
59246
|
+
let t6;
|
|
59247
|
+
$[11] !== fontFamily || $[12] !== fontSize || $[13] !== fontWeight ? (t6 = {
|
|
59248
|
+
fontFamily,
|
|
59249
|
+
fontWeight,
|
|
59250
|
+
fontSize,
|
|
59251
|
+
transform: "translateY(1px)"
|
|
59252
|
+
}, $[11] = fontFamily, $[12] = fontSize, $[13] = fontWeight, $[14] = t6) : t6 = $[14];
|
|
59253
|
+
let t7;
|
|
59254
|
+
$[15] !== letters || $[16] !== t6 || $[17] !== textColor ? (t7 = /* @__PURE__ */ jsx("text", { x: "50%", y: "50%", textAnchor: "middle", alignmentBaseline: "middle", dominantBaseline: "middle", fill: textColor, style: t6, children: letters }), $[15] = letters, $[16] = t6, $[17] = textColor, $[18] = t7) : t7 = $[18];
|
|
59255
|
+
let t8;
|
|
59256
|
+
return $[19] !== t5 || $[20] !== t7 ? (t8 = /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 32 32", children: [
|
|
59257
|
+
t5,
|
|
59258
|
+
t7
|
|
59259
|
+
] }), $[19] = t5, $[20] = t7, $[21] = t8) : t8 = $[21], t8;
|
|
59260
|
+
}
|
|
59261
|
+
function _temp3$h(i) {
|
|
59262
|
+
return i.charAt(0).toUpperCase();
|
|
59263
|
+
}
|
|
59264
|
+
function _temp2$y(word) {
|
|
59265
|
+
return word.replace(/\\W/g, "");
|
|
59266
|
+
}
|
|
59267
|
+
function _temp$1n(hue) {
|
|
59268
|
+
return hue !== "gray";
|
|
59269
|
+
}
|
|
59234
59270
|
function createDefaultIcon(title, subtitle) {
|
|
59235
|
-
|
|
59236
|
-
return /* @__PURE__ */ jsxs("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 32 32", children: [
|
|
59237
|
-
/* @__PURE__ */ jsx("rect", { width: 32, height: 32, rx: 2, fill: color }),
|
|
59238
|
-
/* @__PURE__ */ jsx(SvgText, { x: "50%", y: "50%", textAnchor: "middle", alignmentBaseline: "middle", dominantBaseline: "middle", fill: textColor, children: letters })
|
|
59239
|
-
] });
|
|
59271
|
+
return /* @__PURE__ */ jsx(DefaultIcon, { title, subtitle });
|
|
59240
59272
|
}
|
|
59241
59273
|
function defineConfig(config) {
|
|
59242
59274
|
return config;
|