sanity 3.83.1-canary.23 → 3.84.1-next.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/_chunks-cjs/PostMessageSchema.js.map +1 -1
- package/lib/_chunks-cjs/PostMessageTelemetry.js +1 -1
- package/lib/_chunks-cjs/PostMessageTelemetry.js.map +1 -1
- package/lib/_chunks-cjs/PresentationToolGrantsCheck.js +429 -1417
- package/lib/_chunks-cjs/PresentationToolGrantsCheck.js.map +1 -1
- package/lib/_chunks-cjs/presentation.js +70 -22
- package/lib/_chunks-cjs/presentation.js.map +1 -1
- package/lib/_chunks-cjs/resources6.js +0 -8
- package/lib/_chunks-cjs/resources6.js.map +1 -1
- package/lib/_chunks-cjs/version.js +1 -1
- package/lib/_chunks-es/PostMessageSchema.mjs.map +1 -1
- package/lib/_chunks-es/PostMessageTelemetry.mjs +1 -1
- package/lib/_chunks-es/PostMessageTelemetry.mjs.map +1 -1
- package/lib/_chunks-es/PresentationToolGrantsCheck.mjs +437 -1406
- package/lib/_chunks-es/PresentationToolGrantsCheck.mjs.map +1 -1
- package/lib/_chunks-es/presentation.mjs +73 -24
- package/lib/_chunks-es/presentation.mjs.map +1 -1
- package/lib/_chunks-es/resources6.mjs +0 -8
- package/lib/_chunks-es/resources6.mjs.map +1 -1
- package/lib/_chunks-es/version.mjs +1 -1
- package/lib/_singletons.d.mts +61 -2889
- package/lib/_singletons.d.ts +61 -2889
- package/lib/presentation.d.mts +57 -2887
- package/lib/presentation.d.ts +57 -2887
- package/lib/presentation.js +4 -0
- package/lib/presentation.js.map +1 -1
- package/lib/presentation.mjs +5 -1
- package/package.json +15 -16
- package/src/presentation/PostMessageTelemetry.tsx +1 -1
- package/src/presentation/PresentationTool.tsx +76 -85
- package/src/presentation/PresentationToolGrantsCheck.tsx +75 -39
- package/src/presentation/document/LocationsBanner.tsx +13 -52
- package/src/presentation/i18n/resources.ts +0 -10
- package/src/presentation/index.ts +13 -0
- package/src/presentation/{util → lib}/parse.ts +1 -2
- package/src/presentation/overlays/schema/PostMessageSchema.tsx +0 -1
- package/src/presentation/panels/usePanelsStorage.ts +1 -1
- package/src/presentation/preview/IFrame.tsx +35 -83
- package/src/presentation/preview/Preview.tsx +56 -172
- package/src/presentation/preview/PreviewHeader.tsx +10 -43
- package/src/presentation/preview/PreviewLocationInput.tsx +24 -48
- package/src/presentation/preview/SharePreviewMenu.tsx +2 -2
- package/src/presentation/reducers/presentationReducer.ts +134 -0
- package/src/presentation/types.ts +7 -139
- package/src/presentation/useMainDocument.ts +12 -4
- package/src/presentation/useParams.ts +3 -2
- package/src/presentation/usePreviewUrl.ts +133 -0
- package/src/presentation/actors/create-preview-secret.ts +0 -19
- package/src/presentation/actors/read-shared-secret.ts +0 -18
- package/src/presentation/actors/resolve-allow-patterns.ts +0 -55
- package/src/presentation/actors/resolve-initial-url.ts +0 -65
- package/src/presentation/actors/resolve-preview-mode-url.ts +0 -72
- package/src/presentation/actors/resolve-preview-mode.ts +0 -66
- package/src/presentation/actors/resolve-url-from-preview-search-param.ts +0 -29
- package/src/presentation/machines/presentation-machine.ts +0 -101
- package/src/presentation/machines/preview-url.ts +0 -568
- package/src/presentation/useAllowPatterns.ts +0 -12
- package/src/presentation/useId.ts +0 -7
- package/src/presentation/usePresentationPerspective.ts +0 -14
- package/src/presentation/usePreviewUrlActorRef.ts +0 -96
- package/src/presentation/useReportInvalidPreviewSearchParam.tsx +0 -43
- package/src/presentation/useTargetOrigin.ts +0 -11
- /package/src/presentation/{util → lib}/debounce.ts +0 -0
@@ -12,6 +12,7 @@ import { Observable, switchMap, from, of, isObservable, map, combineLatest, merg
|
|
12
12
|
import { useIntentLink, useRouter, encodeJsonParams, route } from "sanity/router";
|
13
13
|
import { useEffectEvent } from "use-effect-event";
|
14
14
|
import { uuid } from "@sanity/uuid";
|
15
|
+
import { parse, object, fallback, boolean, picklist } from "valibot";
|
15
16
|
const useSharedState = (key, value) => {
|
16
17
|
const $ = c(5), context = useContext(PresentationSharedStateContext);
|
17
18
|
if (!context)
|
@@ -34,9 +35,9 @@ function setKey(source, key, value) {
|
|
34
35
|
};
|
35
36
|
}
|
36
37
|
function props(options = {}) {
|
37
|
-
return (source) => new Observable((observer) => source.subscribe(observer)).pipe(switchMap((
|
38
|
-
const keyObservables = keysOf(
|
39
|
-
const value =
|
38
|
+
return (source) => new Observable((observer) => source.subscribe(observer)).pipe(switchMap((object2) => {
|
39
|
+
const keyObservables = keysOf(object2).map((key) => {
|
40
|
+
const value = object2[key];
|
40
41
|
return isObservable(value) ? from(value).pipe(map((val) => [key, val])) : of([key, value]);
|
41
42
|
});
|
42
43
|
return options.wait ? combineLatest(keyObservables).pipe(map((pairs) => pairs.reduce((acc, [key, value]) => setKey(acc, key, value), {}))) : from(keyObservables).pipe(mergeAll(), scan((acc, [key, value]) => setKey(acc, key, value), {}));
|
@@ -214,7 +215,7 @@ function LocationsBanner(props2) {
|
|
214
215
|
] }) })
|
215
216
|
] }), $[8] = ToneIcon, $[9] = locations, $[10] = options, $[11] = showPresentationTitle, $[12] = title, $[13] = tone, $[14] = t3) : t3 = $[14];
|
216
217
|
let t4;
|
217
|
-
$[15] !== documentId || $[16] !== expanded || $[17] !== isResolving || $[18] !== len || $[19] !== locations || $[20] !== options || $[21] !== presentation || $[22] !== presentationName || $[23] !== schemaType || $[24] !== showPresentationTitle || $[25] !== title || $[26] !== toggle ? (t4 = locations && /* @__PURE__ */ jsxs(Fragment, { children: [
|
218
|
+
$[15] !== documentId || $[16] !== expanded || $[17] !== isResolving || $[18] !== len || $[19] !== locations || $[20] !== options || $[21] !== presentation?.params || $[22] !== presentationName || $[23] !== schemaType || $[24] !== showPresentationTitle || $[25] !== title || $[26] !== toggle ? (t4 = locations && /* @__PURE__ */ jsxs(Fragment, { children: [
|
218
219
|
/* @__PURE__ */ jsx(Card, { as: len ? "button" : void 0, onClick: toggle, padding: 3, radius: 1, tone: "inherit", children: /* @__PURE__ */ jsxs(Flex, { gap: 3, children: [
|
219
220
|
/* @__PURE__ */ jsx(Box, { flex: "none", children: isResolving ? /* @__PURE__ */ jsx(Spinner, { size: 1 }) : /* @__PURE__ */ jsx(Text, { size: 1, children: len === 0 ? /* @__PURE__ */ jsx(InfoOutlineIcon, {}) : /* @__PURE__ */ jsx(ChevronRightIcon, { style: {
|
220
221
|
transform: `rotate(${expanded ? "90deg" : 0})`,
|
@@ -228,11 +229,8 @@ function LocationsBanner(props2) {
|
|
228
229
|
title
|
229
230
|
] }) })
|
230
231
|
] }) }),
|
231
|
-
/* @__PURE__ */ jsx(Stack, { hidden: !expanded, marginTop: 1, space: 1, children: locations.map((l) => {
|
232
|
-
|
233
|
-
return (options.name || DEFAULT_TOOL_NAME) === presentationName && presentation?.params.preview && (active = areUrlsMatching(presentation.params.preview, l.href)), /* @__PURE__ */ jsx(LocationItem, { active, documentId, documentType: schemaType.name, node: l, toolName: options.name || DEFAULT_TOOL_NAME }, l.href);
|
234
|
-
}) })
|
235
|
-
] }), $[15] = documentId, $[16] = expanded, $[17] = isResolving, $[18] = len, $[19] = locations, $[20] = options, $[21] = presentation, $[22] = presentationName, $[23] = schemaType, $[24] = showPresentationTitle, $[25] = title, $[26] = toggle, $[27] = t4) : t4 = $[27];
|
232
|
+
/* @__PURE__ */ jsx(Stack, { hidden: !expanded, marginTop: 1, space: 1, children: locations.map((l, index) => /* @__PURE__ */ jsx(LocationItem, { active: (options.name || DEFAULT_TOOL_NAME) === presentationName && l.href === presentation?.params.preview, documentId, documentType: schemaType.name, node: l, toolName: options.name || DEFAULT_TOOL_NAME }, index)) })
|
233
|
+
] }), $[15] = documentId, $[16] = expanded, $[17] = isResolving, $[18] = len, $[19] = locations, $[20] = options, $[21] = presentation?.params, $[22] = presentationName, $[23] = schemaType, $[24] = showPresentationTitle, $[25] = title, $[26] = toggle, $[27] = t4) : t4 = $[27];
|
236
234
|
let t5;
|
237
235
|
$[28] !== t3 || $[29] !== t4 ? (t5 = /* @__PURE__ */ jsxs("div", { style: t2, children: [
|
238
236
|
t3,
|
@@ -292,20 +290,6 @@ function LocationItem(props2) {
|
|
292
290
|
let t9;
|
293
291
|
return $[20] !== active || $[21] !== node.href || $[22] !== t3 || $[23] !== t4 || $[24] !== t8 ? (t9 = /* @__PURE__ */ createElement(Card, { ...t3, as: "a", key: node.href, onClick: t4, padding: 3, radius: 1, pressed: active, tone: "inherit" }, t8), $[20] = active, $[21] = node.href, $[22] = t3, $[23] = t4, $[24] = t8, $[25] = t9) : t9 = $[25], t9;
|
294
292
|
}
|
295
|
-
function areUrlsMatching(previewUrlString, locationUrlString) {
|
296
|
-
try {
|
297
|
-
const previewUrl = new URL(previewUrlString, location.origin), locationUrl = new URL(locationUrlString, previewUrl.origin);
|
298
|
-
if (previewUrl.origin !== locationUrl.origin || previewUrl.pathname !== locationUrl.pathname)
|
299
|
-
return !1;
|
300
|
-
const locationParams = new URLSearchParams(locationUrl.search), previewParams = new URLSearchParams(previewUrl.search);
|
301
|
-
for (const [key, value] of locationParams.entries())
|
302
|
-
if (previewParams.get(key) !== value)
|
303
|
-
return !1;
|
304
|
-
return !0;
|
305
|
-
} catch {
|
306
|
-
return !1;
|
307
|
-
}
|
308
|
-
}
|
309
293
|
const LocationStack = styled(Stack)`
|
310
294
|
min-height: ${rem(42)};
|
311
295
|
|
@@ -544,7 +528,66 @@ const presentationTool = definePlugin((options) => {
|
|
544
528
|
__internalApplicationType: "sanity/presentation"
|
545
529
|
}]
|
546
530
|
};
|
547
|
-
})
|
531
|
+
}), ACTION_IFRAME_LOADED = "ACTION_IFRAME_LOADED", ACTION_IFRAME_REFRESH = "ACTION_IFRAME_REFRESH", ACTION_IFRAME_RELOAD = "ACTION_IFRAME_RELOAD", ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE = "ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE", presentationReducer = (state, action) => {
|
532
|
+
switch (action.type) {
|
533
|
+
case ACTION_IFRAME_LOADED:
|
534
|
+
return state.iframe.status === "loaded" ? state : {
|
535
|
+
...state,
|
536
|
+
iframe: {
|
537
|
+
...state.iframe,
|
538
|
+
status: "loaded"
|
539
|
+
}
|
540
|
+
};
|
541
|
+
case ACTION_IFRAME_REFRESH:
|
542
|
+
return state.iframe.status === "refreshing" ? state : {
|
543
|
+
...state,
|
544
|
+
iframe: {
|
545
|
+
...state.iframe,
|
546
|
+
status: "refreshing"
|
547
|
+
}
|
548
|
+
};
|
549
|
+
case ACTION_IFRAME_RELOAD:
|
550
|
+
return state.iframe.status === "reloading" ? state : {
|
551
|
+
...state,
|
552
|
+
iframe: {
|
553
|
+
...state.iframe,
|
554
|
+
status: "reloading"
|
555
|
+
}
|
556
|
+
};
|
557
|
+
case ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE:
|
558
|
+
return toggleVisualEditingOverlays(state, action);
|
559
|
+
default:
|
560
|
+
return state;
|
561
|
+
}
|
562
|
+
}, toggleVisualEditingOverlays = (state, action) => state.visualEditing.overlaysEnabled === action.enabled ? state : {
|
563
|
+
...state,
|
564
|
+
visualEditing: {
|
565
|
+
...state.visualEditing,
|
566
|
+
overlaysEnabled: action.enabled
|
567
|
+
}
|
568
|
+
}, mainDocumentSchema = fallback(boolean(), !1), iframeStatusSchema = picklist(["loading", "loaded", "refreshing", "reloading"]), initStateSchema = object({
|
569
|
+
mainDocument: mainDocumentSchema,
|
570
|
+
iframe: object({
|
571
|
+
status: iframeStatusSchema
|
572
|
+
}),
|
573
|
+
visualEditing: object({
|
574
|
+
overlaysEnabled: boolean()
|
575
|
+
})
|
576
|
+
}), INITIAL_PRESENTATION_STATE = {
|
577
|
+
mainDocument: !1,
|
578
|
+
iframe: {
|
579
|
+
status: "loading"
|
580
|
+
},
|
581
|
+
visualEditing: {
|
582
|
+
overlaysEnabled: !1
|
583
|
+
}
|
584
|
+
};
|
585
|
+
function presentationReducerInit(state) {
|
586
|
+
return parse(initStateSchema, {
|
587
|
+
...INITIAL_PRESENTATION_STATE,
|
588
|
+
...state
|
589
|
+
});
|
590
|
+
}
|
548
591
|
function usePresentationNavigate() {
|
549
592
|
const navigate = useContext(PresentationNavigateContext);
|
550
593
|
if (!navigate)
|
@@ -558,6 +601,10 @@ function usePresentationParams(t0) {
|
|
558
601
|
return params;
|
559
602
|
}
|
560
603
|
export {
|
604
|
+
ACTION_IFRAME_LOADED,
|
605
|
+
ACTION_IFRAME_REFRESH,
|
606
|
+
ACTION_IFRAME_RELOAD,
|
607
|
+
ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE,
|
561
608
|
API_VERSION,
|
562
609
|
DEFAULT_TOOL_NAME,
|
563
610
|
EDIT_INTENT_MODE,
|
@@ -569,6 +616,8 @@ export {
|
|
569
616
|
defineDocuments,
|
570
617
|
defineLocations,
|
571
618
|
presentationLocaleNamespace,
|
619
|
+
presentationReducer,
|
620
|
+
presentationReducerInit,
|
572
621
|
presentationTool,
|
573
622
|
usePresentationNavigate,
|
574
623
|
usePresentationParams,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"presentation.mjs","sources":["../../src/presentation/overlays/useSharedState.ts","../../src/presentation/constants.ts","../../src/presentation/util/props.ts","../../src/presentation/useDocumentLocations.ts","../../src/presentation/i18n/index.ts","../../src/presentation/usePresentationTool.ts","../../src/presentation/document/useCurrentPresentationToolName.ts","../../src/presentation/document/LocationsBanner.tsx","../../src/presentation/document/PresentationDocumentHeader.tsx","../../src/presentation/document/PresentationDocumentProvider.tsx","../../src/presentation/fieldActions/openInStructure.ts","../../src/presentation/getIntentState.ts","../../src/presentation/PresentationSpinner.tsx","../../src/presentation/router.ts","../../src/presentation/plugin.tsx","../../src/presentation/usePresentationNavigate.ts","../../src/presentation/usePresentationParams.ts"],"sourcesContent":["import {type Serializable} from '@sanity/presentation-comlink'\nimport {useContext, useEffect} from 'react'\nimport {PresentationSharedStateContext} from 'sanity/_singletons'\n\n/** @public */\nexport const useSharedState = (key: string, value: Serializable): undefined => {\n const context = useContext(PresentationSharedStateContext)\n\n if (!context) {\n throw new Error('Preview Snapshots context is missing')\n }\n\n const {setValue} = context\n\n useEffect(() => {\n setValue(key, value)\n }, [key, value, setValue])\n\n return undefined\n}\n","import {ComposeIcon} from '@sanity/icons'\nimport {apiVersion} from '@sanity/preview-url-secret/constants'\n\nexport const DEFAULT_TOOL_ICON = ComposeIcon\nexport const DEFAULT_TOOL_NAME = 'presentation'\nexport const DEFAULT_TOOL_TITLE = 'Presentation'\n\nexport const EDIT_INTENT_MODE = 'presentation'\n\n// How long we wait until an iframe is loaded until we consider it to be slow and possibly failed\nexport const MAX_TIME_TO_OVERLAYS_CONNECTION = 3_000 // ms\n\n// The API version to use when using `@sanity/client`\nexport const API_VERSION = apiVersion\n\n// Heartbeats shouldn't fire on intervals that are so short it causes performance issues\nexport const MIN_LOADER_QUERY_LISTEN_HEARTBEAT_INTERVAL = 1000 // ms\n\n// How often the list over loader queries should be garbage collected\nexport const LOADER_QUERY_GC_INTERVAL = 30_000 // ms\n\n// The interval at which we check if existing popups have been closed\nexport const POPUP_CHECK_INTERVAL = 1000 // ms\n","import {\n combineLatest,\n from,\n isObservable,\n map,\n mergeAll,\n Observable,\n of,\n scan,\n switchMap,\n} from 'rxjs'\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\ntype Props<K extends keyof any, T> = {\n [P in K]: T | Observable<T>\n}\n\nfunction keysOf<T extends object>(value: T) {\n return Object.keys(value) as (keyof T)[]\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction setKey(source: Record<string, unknown>, key: any, value: unknown) {\n return {\n ...source,\n [key]: value,\n }\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function props<K extends keyof any, T>(options: {wait?: boolean} = {}) {\n return (source: Observable<Props<K, T>>): Observable<Record<string, unknown>> => {\n return new Observable<Props<K, T>>((observer) => source.subscribe(observer)).pipe(\n switchMap((object) => {\n const keyObservables = keysOf(object).map((key) => {\n const value = object[key]\n return isObservable(value) ? from(value).pipe(map((val) => [key, val])) : of([key, value])\n })\n\n return options.wait\n ? combineLatest(keyObservables).pipe(\n map((pairs) => pairs.reduce((acc, [key, value]) => setKey(acc, key, value), {})),\n )\n : from(keyObservables).pipe(\n mergeAll(),\n scan((acc, [key, value]) => setKey(acc, key, value), {}),\n )\n }),\n )\n }\n}\n","/* eslint-disable @typescript-eslint/no-shadow */\nimport {type StackablePerspective} from '@sanity/client'\nimport {get} from 'lodash'\nimport {useEffect, useMemo, useState} from 'react'\nimport {isObservable, map, type Observable, of, switchMap} from 'rxjs'\nimport {\n type DocumentStore,\n getDraftId,\n getPublishedId,\n getVersionId,\n isRecord,\n isReference,\n type Previewable,\n type SanityDocument,\n useDocumentStore,\n usePerspective,\n} from 'sanity'\n\nimport {\n type DocumentLocationResolver,\n type DocumentLocationResolverObject,\n type DocumentLocationResolvers,\n type DocumentLocationsState,\n type DocumentLocationsStatus,\n} from './types'\nimport {props} from './util/props'\n\nconst INITIAL_STATE: DocumentLocationsState = {locations: []}\n\nfunction getDocumentId(value: Previewable) {\n if (isReference(value)) {\n return value._ref\n }\n return '_id' in value ? value._id : undefined\n}\n\nfunction cleanPreviewable(id: string | undefined, previewable: Previewable) {\n const clean: Record<string, unknown> = id ? {...previewable, _id: id} : {...previewable}\n\n if (clean._type === 'reference') {\n delete clean._type\n delete clean._ref\n delete clean._weak\n delete clean._dataset\n delete clean._projectId\n delete clean._strengthenOnPublish\n }\n\n return clean\n}\n\nfunction listen(\n id: string,\n fields: string[],\n store: DocumentStore,\n perspectiveStack: StackablePerspective[],\n) {\n const projection = fields.join(', ')\n const query = {\n fetch: `*[_id==$id][0]{${projection}}`,\n // TODO: is it more performant to use `||` instead of `in`?\n listen: `*[_id in $versions]`,\n }\n const params = {\n id,\n versions: perspectiveStack\n .map((p) => {\n if (p === 'published') return getPublishedId(id)\n if (p === 'drafts') return getDraftId(id)\n return getVersionId(getPublishedId(id), p)\n })\n .concat(getPublishedId(id)),\n }\n return store.listenQuery(query, params, {\n perspective: perspectiveStack,\n tag: 'use-document-locations',\n }) as Observable<SanityDocument | null>\n}\nfunction observeDocument(\n value: Previewable | null,\n paths: string[][],\n store: DocumentStore,\n perspectiveStack: StackablePerspective[],\n): Observable<Record<string, unknown> | null> {\n if (!value || typeof value !== 'object') {\n return of(value)\n }\n\n const id = getDocumentId(value)\n const currentValue = cleanPreviewable(id, value)\n\n const headlessPaths = paths.filter((path) => !(path[0] in currentValue))\n\n if (id && headlessPaths.length) {\n const fields = [...new Set(headlessPaths.map((path: string[]) => path[0]))]\n return listen(id, fields, store, perspectiveStack).pipe(\n switchMap((snapshot) => {\n if (snapshot) {\n return observeDocument(snapshot, paths, store, perspectiveStack)\n }\n return of(null)\n }),\n )\n }\n\n const leads: Record<string, string[][]> = {}\n paths.forEach((path) => {\n const [head, ...tail] = path\n if (!leads[head]) {\n leads[head] = []\n }\n leads[head].push(tail)\n })\n const next = Object.keys(leads).reduce((res: Record<string, unknown>, head) => {\n const tails = leads[head].filter((tail) => tail.length > 0)\n if (tails.length === 0) {\n res[head] = isRecord(value) ? (value as Record<string, unknown>)[head] : undefined\n } else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n res[head] = observeDocument((value as any)[head], tails, store, perspectiveStack)\n }\n return res\n }, currentValue)\n\n return of(next).pipe(props({wait: true}))\n}\n\nfunction observeForLocations(\n documentId: string,\n resolver: DocumentLocationResolverObject<string>,\n documentStore: DocumentStore,\n perspectiveStack: StackablePerspective[],\n) {\n const {select} = resolver\n const paths = Object.values(select).map((value) => String(value).split('.')) || []\n const doc = {_type: 'reference', _ref: documentId}\n return observeDocument(doc, paths, documentStore, perspectiveStack).pipe(\n map((doc) => {\n return Object.keys(select).reduce<Record<string, unknown>>((acc, key) => {\n acc[key] = get(doc, select[key])\n return acc\n }, {})\n }),\n map(resolver.resolve),\n )\n}\n\nexport function useDocumentLocations(props: {\n id: string\n version: string | undefined\n resolvers?: DocumentLocationResolver | DocumentLocationResolvers\n type: string\n}): {\n state: DocumentLocationsState\n status: DocumentLocationsStatus\n} {\n const {id, resolvers, type, version} = props\n const documentStore = useDocumentStore()\n const {perspectiveStack} = usePerspective()\n const [locationsState, setLocationsState] = useState<DocumentLocationsState>(INITIAL_STATE)\n\n const resolver = resolvers && (typeof resolvers === 'function' ? resolvers : resolvers[type])\n\n const [locationsStatus, setLocationsStatus] = useState<DocumentLocationsStatus>(\n resolver ? 'resolving' : 'empty',\n )\n\n const result = useMemo(() => {\n if (!resolver) return undefined\n\n // Original/advanced resolver which requires explicit use of Observables\n if (typeof resolver === 'function') {\n const params = {id, type, version, perspectiveStack}\n const context = {documentStore}\n const _result = resolver(params, context)\n return isObservable(_result) ? _result : of(_result)\n }\n\n // Simplified resolver pattern which abstracts away Observable logic\n if ('select' in resolver && 'resolve' in resolver) {\n return observeForLocations(id, resolver, documentStore, perspectiveStack)\n }\n\n // Resolver is explicitly provided state\n return of(resolver)\n }, [documentStore, id, resolver, type, version, perspectiveStack])\n\n useEffect(() => {\n const sub = result?.subscribe((state) => {\n setLocationsState(state || INITIAL_STATE)\n setLocationsStatus(state ? 'resolved' : 'empty')\n })\n\n return () => sub?.unsubscribe()\n }, [result])\n\n return {\n state: locationsState,\n status: locationsStatus,\n }\n}\n","import {defineLocaleResourceBundle} from 'sanity'\n\n/**\n * The locale namespace for the presentation tool\n *\n * @public\n */\nexport const presentationLocaleNamespace = 'presentation' as const\n\n/**\n * The default locale bundle for the presentation tool, which is US English.\n *\n * @internal\n */\nexport const presentationUsEnglishLocaleBundle = defineLocaleResourceBundle({\n locale: 'en-US',\n namespace: presentationLocaleNamespace,\n resources: () => import('./resources'),\n})\n","import {useContext} from 'react'\nimport {PresentationContext} from 'sanity/_singletons'\n\nimport {type PresentationContextValue} from './types'\n\nexport function usePresentationTool(throwOnMissingContext?: true): PresentationContextValue\nexport function usePresentationTool(throwOnMissingContext: false): PresentationContextValue | null\nexport function usePresentationTool(throwOnMissingContext = true): PresentationContextValue | null {\n const presentation = useContext(PresentationContext)\n\n if (throwOnMissingContext && !presentation) {\n throw new Error('Presentation context is missing')\n }\n\n return presentation\n}\n","import {usePresentationTool} from '../usePresentationTool'\n\nexport function useCurrentPresentationToolName(): string | undefined {\n return usePresentationTool(false)?.name ?? undefined\n}\n","import {\n ChevronRightIcon,\n DesktopIcon,\n ErrorOutlineIcon,\n InfoOutlineIcon,\n WarningOutlineIcon,\n} from '@sanity/icons'\nimport {Box, Card, Flex, Spinner, Stack, Text} from '@sanity/ui'\nimport {type ComponentType, type ReactNode, useCallback, useContext, useState} from 'react'\nimport {type ObjectSchemaType, useTranslation} from 'sanity'\nimport {PresentationContext} from 'sanity/_singletons'\nimport {useIntentLink} from 'sanity/router'\n\nimport {DEFAULT_TOOL_NAME, DEFAULT_TOOL_TITLE} from '../constants'\nimport {presentationLocaleNamespace} from '../i18n'\nimport {\n type DocumentLocation,\n type DocumentLocationsState,\n type PresentationPluginOptions,\n} from '../types'\nimport {useCurrentPresentationToolName} from './useCurrentPresentationToolName'\n\nconst TONE_ICONS: Record<'positive' | 'caution' | 'critical', ComponentType> = {\n positive: InfoOutlineIcon,\n caution: WarningOutlineIcon,\n critical: ErrorOutlineIcon,\n}\n\nexport function LocationsBanner(props: {\n documentId: string\n isResolving: boolean\n options: PresentationPluginOptions\n schemaType: ObjectSchemaType\n showPresentationTitle: boolean\n state: DocumentLocationsState\n}): ReactNode {\n const {documentId, isResolving, options, schemaType, showPresentationTitle} = props\n const {locations, message, tone} = props.state\n const len = locations?.length || 0\n\n const {t} = useTranslation(presentationLocaleNamespace)\n const presentation = useContext(PresentationContext)\n const presentationName = presentation?.name\n const [expanded, setExpanded] = useState(false)\n const toggle = useCallback(() => {\n if (!len) return\n setExpanded((v) => !v)\n }, [len])\n\n const title = isResolving\n ? t('locations-banner.resolving.text')\n : message || t('locations-banner.locations-count', {count: len})\n\n const ToneIcon = tone ? TONE_ICONS[tone] : undefined\n\n return (\n <Card padding={1} radius={2} border tone={tone}>\n <div style={{margin: -1}}>\n {!locations && (\n <Flex align=\"flex-start\" gap={3} padding={3}>\n {tone && ToneIcon && (\n <Box flex=\"none\">\n <Text size={1}>\n <ToneIcon />\n </Text>\n </Box>\n )}\n <Box flex={1}>\n <Text size={1} weight=\"medium\">\n {showPresentationTitle && <>{options.title || DEFAULT_TOOL_TITLE} · </>}\n {title}\n </Text>\n </Box>\n </Flex>\n )}\n {locations && (\n <>\n <Card\n as={len ? 'button' : undefined}\n onClick={toggle}\n padding={3}\n radius={1}\n tone=\"inherit\"\n >\n <Flex gap={3}>\n <Box flex=\"none\">\n {isResolving ? (\n <Spinner size={1} />\n ) : (\n <Text size={1}>\n {len === 0 ? (\n <InfoOutlineIcon />\n ) : (\n <ChevronRightIcon\n style={{\n transform: `rotate(${expanded ? '90deg' : 0})`,\n transition: 'transform 100ms ease-in-out',\n }}\n />\n )}\n </Text>\n )}\n </Box>\n <Box flex={1}>\n <Text size={1} weight=\"medium\">\n {showPresentationTitle && <>{options.title || DEFAULT_TOOL_TITLE} · </>}\n {title}\n </Text>\n </Box>\n </Flex>\n </Card>\n <Stack hidden={!expanded} marginTop={1} space={1}>\n {locations.map((l) => {\n let active = false\n if (\n (options.name || DEFAULT_TOOL_NAME) === presentationName &&\n presentation?.params.preview\n ) {\n active = areUrlsMatching(presentation.params.preview, l.href)\n }\n\n return (\n <LocationItem\n active={active}\n documentId={documentId}\n documentType={schemaType.name}\n key={l.href}\n node={l}\n toolName={options.name || DEFAULT_TOOL_NAME}\n />\n )\n })}\n </Stack>\n </>\n )}\n </div>\n </Card>\n )\n}\n\nfunction LocationItem(props: {\n active: boolean\n documentId: string\n documentType: string\n node: DocumentLocation\n toolName: string\n}) {\n const {documentId, documentType, node, active, toolName} = props\n const presentation = useContext(PresentationContext)\n const currentPresentationToolName = useCurrentPresentationToolName()\n const isCurrentTool = toolName === currentPresentationToolName\n const navigate = presentation?.navigate\n\n const presentationLinkProps = useIntentLink({\n intent: 'edit',\n params: {\n id: documentId,\n type: documentType,\n mode: 'presentation',\n presentation: toolName,\n ...presentation?.structureParams,\n preview: node.href,\n },\n })\n\n const handleCurrentToolClick = useCallback(() => {\n navigate?.({}, {preview: node.href})\n }, [node.href, navigate])\n\n return (\n <Card\n {...(isCurrentTool ? {} : presentationLinkProps)}\n as=\"a\"\n key={node.href}\n onClick={isCurrentTool ? handleCurrentToolClick : presentationLinkProps.onClick}\n padding={3}\n radius={1}\n pressed={active}\n tone=\"inherit\"\n >\n <Flex gap={3}>\n <Box flex=\"none\">\n <Text size={1}>\n <DesktopIcon />\n </Text>\n </Box>\n <Stack flex={1} space={2}>\n <Text size={1} weight=\"medium\">\n {node.title}\n </Text>\n <Text muted size={1} textOverflow=\"ellipsis\">\n {node.href}\n </Text>\n </Stack>\n </Flex>\n </Card>\n )\n}\n\n/**\n * Compares two URLs to determine if they match based on origin, pathname, and search parameters\n * The previewUrl should have all the search parameters that are in the locationUrl\n */\nfunction areUrlsMatching(previewUrlString: string, locationUrlString: string): boolean {\n try {\n const previewUrl = new URL(previewUrlString, location.origin)\n const locationUrl = new URL(locationUrlString, previewUrl.origin)\n\n // First compare origin and pathname\n if (previewUrl.origin !== locationUrl.origin || previewUrl.pathname !== locationUrl.pathname) {\n return false\n }\n\n // Then check search params\n // All search params in locationUrl must exist with the same values in previewUrl\n const locationParams = new URLSearchParams(locationUrl.search)\n const previewParams = new URLSearchParams(previewUrl.search)\n\n for (const [key, value] of locationParams.entries()) {\n if (previewParams.get(key) !== value) {\n return false\n }\n }\n\n return true\n } catch {\n // If URL parsing fails, URLs don't match\n return false\n }\n}\n","import {rem, Stack} from '@sanity/ui'\nimport {type ReactNode, useContext} from 'react'\nimport {type ObjectSchemaType, type PublishedId} from 'sanity'\nimport {PresentationDocumentContext} from 'sanity/_singletons'\nimport {styled} from 'styled-components'\n\nimport {type PresentationPluginOptions} from '../types'\nimport {useDocumentLocations} from '../useDocumentLocations'\nimport {LocationsBanner} from './LocationsBanner'\n\nconst LocationStack = styled(Stack)`\n min-height: ${rem(42)};\n\n & + &:empty {\n display: none;\n }\n`\n\nexport function PresentationDocumentHeader(props: {\n documentId: PublishedId\n version: string | undefined\n options: PresentationPluginOptions\n schemaType: ObjectSchemaType\n}): ReactNode {\n const {documentId, options, schemaType, version} = props\n const context = useContext(PresentationDocumentContext)\n const {state, status} = useDocumentLocations({\n id: documentId,\n version,\n resolvers: options.resolve?.locations || options.locate,\n type: schemaType.name,\n })\n\n if ((context && context.options[0] !== options) || status === 'empty') {\n return null\n }\n\n const contextOptions = context?.options || []\n\n return (\n <LocationStack marginBottom={5} space={5}>\n <Stack space={2}>\n {contextOptions.map(\n (\n // eslint-disable-next-line @typescript-eslint/no-shadow\n options,\n idx,\n ) => (\n <LocationsBanner\n documentId={documentId}\n isResolving={status === 'resolving'}\n key={idx}\n options={options}\n schemaType={schemaType}\n showPresentationTitle={contextOptions.length > 1}\n state={state}\n />\n ),\n )}\n </Stack>\n </LocationStack>\n )\n}\n","import {type ReactNode, useCallback, useContext, useLayoutEffect, useMemo, useState} from 'react'\nimport {PresentationDocumentContext} from 'sanity/_singletons'\nimport {useEffectEvent} from 'use-effect-event'\n\nimport {type PresentationPluginOptions} from '../types'\nimport {type PresentationDocumentContextValue} from './types'\n\n/** @internal */\nexport function PresentationDocumentProvider(props: {\n children?: ReactNode\n options: PresentationPluginOptions\n}): React.JSX.Element {\n const {children, options} = props\n const parent = useContext(PresentationDocumentContext)\n const parentRegister = parent?.register\n\n const [optionsArray, setOptionsArray] = useState<PresentationPluginOptions[]>(() => [])\n\n const register = useCallback(\n // eslint-disable-next-line @typescript-eslint/no-shadow\n (options: PresentationPluginOptions) => {\n if (parentRegister) {\n return parentRegister(options)\n }\n\n setOptionsArray((prev) => [options].concat(prev))\n\n return () => {\n setOptionsArray((prev) => prev.filter((o) => o !== options))\n }\n },\n [parentRegister],\n )\n\n const context: PresentationDocumentContextValue = useMemo(\n () => ({\n options: parent?.options || optionsArray,\n register,\n }),\n [optionsArray, parent, register],\n )\n\n // eslint-disable-next-line @typescript-eslint/no-shadow\n const registerEffectEvent = useEffectEvent((options: PresentationPluginOptions) =>\n register(options),\n )\n useLayoutEffect(() => registerEffectEvent(options), [options])\n\n return (\n <PresentationDocumentContext.Provider value={context}>\n {children}\n </PresentationDocumentContext.Provider>\n )\n}\n","import {MasterDetailIcon} from '@sanity/icons'\nimport {useContext, useMemo} from 'react'\nimport {\n defineDocumentFieldAction,\n type DocumentFieldActionGroup,\n type DocumentFieldActionItem,\n type DocumentFieldActionProps,\n isRecord,\n pathToString,\n type Tool,\n useWorkspace,\n} from 'sanity'\nimport {PresentationContext} from 'sanity/_singletons'\nimport {useRouter} from 'sanity/router'\n\nimport {DEFAULT_TOOL_NAME} from '../constants'\n\nfunction useOpenInStructureAction(\n props: DocumentFieldActionProps,\n): DocumentFieldActionItem | DocumentFieldActionGroup {\n const {documentId, documentType, path} = props\n const workspace = useWorkspace()\n const {navigateIntent} = useRouter()\n const presentation = useContext(PresentationContext)\n\n const defaultStructureTool = useMemo(\n () =>\n findStructureTool(\n workspace.tools,\n documentId,\n documentType,\n presentation?.name || DEFAULT_TOOL_NAME,\n ),\n [documentId, documentType, workspace.tools, presentation],\n )\n\n return {\n type: 'action',\n hidden: !presentation || path.length > 0 || !defaultStructureTool,\n icon: defaultStructureTool?.icon || MasterDetailIcon,\n title: `Open in ${defaultStructureTool?.title || 'Structure'}`,\n onAction() {\n navigateIntent('edit', {\n id: documentId,\n type: documentType,\n mode: 'structure',\n path: pathToString(path),\n })\n },\n renderAsButton: true,\n }\n}\n\nexport const openInStructure = defineDocumentFieldAction({\n name: 'presentation/openInStructure',\n useAction: useOpenInStructureAction,\n})\n\nfunction findStructureTool(\n tools: Tool[],\n documentId: string,\n documentType: string,\n presentationToolName?: string,\n): Tool | undefined {\n const results = tools\n .filter((t) => t.name !== presentationToolName)\n .map((t) => {\n const match = t.canHandleIntent?.(\n 'edit',\n {\n id: documentId,\n type: documentType,\n mode: 'structure',\n },\n {},\n )\n\n return {tool: t, match}\n })\n\n const modeMatches = results.filter((t) => isRecord(t.match) && t.match.mode)\n\n if (modeMatches.length > 0) {\n return modeMatches[0].tool\n }\n\n const matches = results.filter((t) => t.match)\n\n return matches[0]?.tool\n}\n","import {uuid} from '@sanity/uuid'\nimport {getPublishedId} from 'sanity'\nimport {encodeJsonParams, type RouterState, type SearchParam} from 'sanity/router'\n\nimport {type PresentationSearchParams, type PresentationStateParams} from './types'\n\nconst preservedSearchParamKeys: Array<keyof PresentationSearchParams> = ['preview', 'viewport']\n\n/**\n * @internal\n */\nexport function getIntentState(\n intent: string,\n params: Record<string, string>,\n routerState: RouterState | undefined,\n payload: unknown,\n):\n | (PresentationStateParams & {_searchParams: SearchParam[]})\n | {intent: string; params: Record<string, string>; payload: unknown} {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {id, mode, path, presentation, type, ...searchParams} = params\n\n const preservedSearchParams = (routerState?._searchParams || [])\n // @todo Casting https://github.com/microsoft/TypeScript/issues/14520\n .filter(([key]) => preservedSearchParamKeys.includes(key as keyof PresentationSearchParams))\n .reduce((acc, [key, value]) => ({...acc, [key]: value}), {} as Record<string, string>)\n\n const _searchParams = {\n ...preservedSearchParams,\n ...searchParams,\n }\n\n if (intent === 'edit' && id) {\n _searchParams.preview =\n _searchParams.preview || new URLSearchParams(window.location.search).get('preview') || '/'\n return {\n type: type || '*',\n id: getPublishedId(id),\n path,\n _searchParams: Object.entries(_searchParams),\n }\n }\n\n if (intent === 'create') {\n _searchParams.preview =\n _searchParams.preview || new URLSearchParams(window.location.search).get('preview') || '/'\n\n if (payload && typeof payload === 'object') {\n _searchParams.templateParams = encodeJsonParams(payload as Record<string, unknown>)\n }\n\n return {\n type: type || '*',\n id: id || uuid(),\n _searchParams: Object.entries(_searchParams),\n }\n }\n return {intent, params, payload}\n}\n","import {Flex, Spinner} from '@sanity/ui'\n\nexport function PresentationSpinner(): React.JSX.Element {\n return (\n <Flex align=\"center\" direction=\"column\" height=\"fill\" justify=\"center\" style={{width: '100%'}}>\n <Spinner />\n </Flex>\n )\n}\n","import {route} from 'sanity/router'\n\n// eslint-disable-next-line camelcase\nexport const router = route.create('/', {__unsafe_disableScopedSearchParams: true}, [\n route.intents('/intent'),\n route.create(':type', [route.create(':id', [route.create(':path')])]),\n])\n","import {type SanityDocument} from '@sanity/client'\nimport {lazy, Suspense} from 'react'\nimport {\n definePlugin,\n getPublishedId,\n getVersionFromId,\n type InputProps,\n isDocumentSchemaType,\n} from 'sanity'\n\nimport {DEFAULT_TOOL_ICON, DEFAULT_TOOL_NAME, EDIT_INTENT_MODE} from './constants'\nimport {PresentationDocumentHeader} from './document/PresentationDocumentHeader'\nimport {PresentationDocumentProvider} from './document/PresentationDocumentProvider'\nimport {openInStructure} from './fieldActions/openInStructure'\nimport {getIntentState} from './getIntentState'\nimport {presentationUsEnglishLocaleBundle} from './i18n'\nimport {PresentationSpinner} from './PresentationSpinner'\nimport {router} from './router'\nimport {\n type DocumentLocationResolverObject,\n type DocumentLocationsState,\n type DocumentResolver,\n type PresentationPluginOptions,\n} from './types'\n\nconst PresentationTool = lazy(() => import('./PresentationToolGrantsCheck'))\nconst BroadcastDisplayedDocument = lazy(() => import('./loader/BroadcastDisplayedDocument'))\n\n/**\n * Define locations for a given document type.\n * This function doesn't do anything itself, it is used to provide type information.\n * @param resolver - resolver that return locations for a document.\n * @public\n */\nexport function defineLocations<K extends string>(\n resolver: DocumentLocationResolverObject<K> | DocumentLocationsState,\n): typeof resolver {\n return resolver\n}\n\n/**\n * Define documents for a given location.\n * This function doesn't do anything itself, it is used to provide type information.\n * @param resolvers - resolvers that return documents.\n * @public\n */\nexport function defineDocuments(resolvers: DocumentResolver[]): typeof resolvers {\n return resolvers\n}\n\n/** @public */\nexport const presentationTool = definePlugin<PresentationPluginOptions>((options) => {\n const toolName = options.name || DEFAULT_TOOL_NAME\n\n if ('locate' in options) {\n // eslint-disable-next-line no-console\n console.warn('Presentation’s `locate` option is deprecated. Use `resolve.locations` instead.')\n }\n\n const hasLocationsResolver = !!(options.resolve?.locations || options.locate)\n\n function PresentationDocumentInput(props: InputProps) {\n const value = props.value as SanityDocument\n const documentId = value?._id ? getPublishedId(value?._id) : undefined\n const documentVersion = value?._id ? getVersionFromId(value._id) : undefined\n if (isDocumentSchemaType(props.schemaType)) {\n return (\n <PresentationDocumentProvider options={options}>\n {hasLocationsResolver && documentId && (\n <PresentationDocumentHeader\n documentId={documentId}\n version={documentVersion}\n options={options}\n schemaType={props.schemaType}\n />\n )}\n <Suspense fallback={<PresentationSpinner />}>{props.renderDefault(props)}</Suspense>\n <Suspense key=\"broadcast-displayed-document\">\n <BroadcastDisplayedDocument key={documentId} value={value} />\n </Suspense>\n </PresentationDocumentProvider>\n )\n }\n\n return props.renderDefault(props)\n }\n\n function canHandleCreateIntent(params: Record<string, unknown>) {\n // We can't handle create intents without a `type` parameter\n if (!('type' in params)) {\n return false\n }\n\n if ('presentation' in params && params.presentation !== toolName) {\n return false\n }\n\n return 'template' in params ? {template: true} : true\n }\n\n function canHandleEditIntent(params: Record<string, unknown>) {\n // We can't handle edit intents without `type` or `id` parameters\n if (!('type' in params) || !('id' in params)) {\n return false\n }\n\n if ('presentation' in params && params.presentation !== toolName) {\n return false\n }\n\n return 'mode' in params ? {mode: params.mode === EDIT_INTENT_MODE} : true\n }\n\n return {\n i18n: {\n bundles: [presentationUsEnglishLocaleBundle],\n },\n document: {\n unstable_fieldActions: (prev) => {\n return [\n ...prev.filter((a) => a.name !== openInStructure.name), // prevent duplication\n openInStructure,\n ]\n },\n },\n\n form: {\n components: {\n input: PresentationDocumentInput,\n },\n },\n\n tools: [\n {\n icon: options.icon || DEFAULT_TOOL_ICON,\n name: toolName,\n title: options.title,\n component: PresentationTool,\n options,\n canHandleIntent(intent, params) {\n if (intent === 'create') return canHandleCreateIntent(params)\n if (intent === 'edit') return canHandleEditIntent(params)\n return false\n },\n getIntentState,\n router,\n __internalApplicationType: 'sanity/presentation',\n },\n ],\n }\n})\n","import {useContext} from 'react'\nimport {PresentationNavigateContext} from 'sanity/_singletons'\n\nimport {type PresentationNavigateContextValue} from './types'\n\n/** @public */\nexport function usePresentationNavigate(): PresentationNavigateContextValue {\n const navigate = useContext(PresentationNavigateContext)\n\n if (!navigate) {\n throw new Error('Presentation navigate context is missing')\n }\n\n return navigate\n}\n\nexport type {PresentationNavigateContextValue}\n","import {useContext} from 'react'\nimport {PresentationParamsContext} from 'sanity/_singletons'\n\nimport {type PresentationParamsContextValue} from './types'\n\n/** @public */\nexport function usePresentationParams(throwOnMissingContext?: true): PresentationParamsContextValue\n/** @public */\nexport function usePresentationParams(\n throwOnMissingContext: false,\n): PresentationParamsContextValue | null\n/** @public */\nexport function usePresentationParams(\n throwOnMissingContext = true,\n): PresentationParamsContextValue | null {\n const params = useContext(PresentationParamsContext)\n\n if (throwOnMissingContext && !params) {\n throw new Error('Presentation params context is missing')\n }\n\n return params\n}\n"],"names":["useSharedState","key","value","$","_c","context","useContext","PresentationSharedStateContext","Error","setValue","t0","t1","useEffect","DEFAULT_TOOL_ICON","ComposeIcon","DEFAULT_TOOL_NAME","DEFAULT_TOOL_TITLE","EDIT_INTENT_MODE","MAX_TIME_TO_OVERLAYS_CONNECTION","API_VERSION","apiVersion","MIN_LOADER_QUERY_LISTEN_HEARTBEAT_INTERVAL","LOADER_QUERY_GC_INTERVAL","POPUP_CHECK_INTERVAL","keysOf","Object","keys","setKey","source","props","options","Observable","observer","subscribe","pipe","switchMap","object","keyObservables","map","isObservable","from","val","of","wait","combineLatest","pairs","reduce","acc","mergeAll","scan","INITIAL_STATE","locations","getDocumentId","isReference","_ref","_id","undefined","cleanPreviewable","id","previewable","clean","_type","_weak","_dataset","_projectId","_strengthenOnPublish","listen","fields","store","perspectiveStack","query","fetch","join","params","versions","p","getPublishedId","getDraftId","getVersionId","concat","listenQuery","perspective","tag","observeDocument","paths","currentValue","headlessPaths","filter","path","length","Set","snapshot","leads","forEach","head","tail","push","next","res","tails","isRecord","observeForLocations","documentId","resolver","documentStore","select","values","String","split","doc","get","resolve","useDocumentLocations","resolvers","type","version","useDocumentStore","usePerspective","locationsState","setLocationsState","useState","locationsStatus","setLocationsStatus","bb0","_result","result","t2","sub","state","unsubscribe","t3","status","presentationLocaleNamespace","presentationUsEnglishLocaleBundle","defineLocaleResourceBundle","locale","namespace","resources","usePresentationTool","throwOnMissingContext","presentation","PresentationContext","useCurrentPresentationToolName","name","TONE_ICONS","positive","InfoOutlineIcon","caution","WarningOutlineIcon","critical","ErrorOutlineIcon","LocationsBanner","isResolving","schemaType","showPresentationTitle","message","tone","len","t","useTranslation","presentationName","expanded","setExpanded","_temp","toggle","count","title","ToneIcon","Symbol","for","margin","t4","transform","transition","l","active","preview","href","t5","t6","v","LocationItem","documentType","node","toolName","currentPresentationToolName","isCurrentTool","navigate","structureParams","intent","mode","presentationLinkProps","useIntentLink","handleCurrentToolClick","onClick","t7","t8","t9","areUrlsMatching","previewUrlString","locationUrlString","previewUrl","URL","location","origin","locationUrl","pathname","locationParams","URLSearchParams","search","previewParams","entries","LocationStack","styled","Stack","rem","PresentationDocumentHeader","PresentationDocumentContext","locate","contextOptions","options_0","idx","PresentationDocumentProvider","children","parent","parentRegister","register","optionsArray","setOptionsArray","prev","prev_0","o","options_1","registerEffectEvent","useEffectEvent","useLayoutEffect","useOpenInStructureAction","workspace","useWorkspace","navigateIntent","useRouter","tools","findStructureTool","defaultStructureTool","icon","MasterDetailIcon","hidden","onAction","pathToString","renderAsButton","openInStructure","defineDocumentFieldAction","useAction","presentationToolName","results","match","canHandleIntent","tool","modeMatches","preservedSearchParamKeys","getIntentState","routerState","payload","searchParams","_searchParams","includes","window","templateParams","encodeJsonParams","uuid","PresentationSpinner","width","router","route","create","__unsafe_disableScopedSearchParams","intents","PresentationTool","lazy","BroadcastDisplayedDocument","defineLocations","defineDocuments","presentationTool","definePlugin","console","warn","hasLocationsResolver","PresentationDocumentInput","getVersionFromId","documentVersion","isDocumentSchemaType","renderDefault","canHandleCreateIntent","template","canHandleEditIntent","i18n","bundles","document","unstable_fieldActions","a","form","components","input","component","__internalApplicationType","usePresentationNavigate","PresentationNavigateContext","usePresent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,EAAE5J,SAAS2G,gBAAgB3G,IAAI;AAAA;AAAA,QACrD2G;AAAAA,MAAAA;AAAAA,IAGN;AAAA,IAEAkD,MAAM;AAAA,MACJC,YAAY;AAAA,QACVC,OAAOf;AAAAA,MAAAA;AAAAA,IAEX;AAAA,IAEA9C,OAAO,CACL;AAAA,MACEG,MAAMtN,QAAQsN,QAAQvO;AAAAA,MACtBkI,MAAMyC;AAAAA,MACNlB,OAAOxI,QAAQwI;AAAAA,MACfyI,WAAW1B;AAAAA,MACXvP;AAAAA,MACAkO,gBAAgBnE,QAAQpH,QAAQ;AAC1BoH,eAAAA,WAAW,WAAiBuG,sBAAsB3N,MAAM,IACxDoH,WAAW,SAAeyG,oBAAoB7N,MAAM,IACjD;AAAA,MACT;AAAA,MACA2L;AAAAA,MACAY;AAAAA,MACAgC,2BAA2B;AAAA,IAC5B,CAAA;AAAA,EAEL;AACF,CAAC;AChJM,SAAAC,0BAAA;AACLtH,QAAAA,WAAiBrL,WAAA4S,2BAAsC;AAAC,MAAA,CAEnDvH;AAAQnL,UAAAA,IAAAA,MACK,0CAA0C;AAGrDmL,SAAAA;AAAQ;ACDV,SAAAwH,sBAAAzS,IAAA;AACL,QAAAiI,wBAAAjI,OAA4B8C,cAA5B9C,IAEA+D,SAAenE,WAAA8S,yBAAoC;AAAC,MAEhDzK,0BAA0BlE;AAAMjE,UAAAA,IAAAA,MAClB,wCAAwC;AAGnDiE,SAAAA;AAAM;"}
|
1
|
+
{"version":3,"file":"presentation.mjs","sources":["../../src/presentation/overlays/useSharedState.ts","../../src/presentation/constants.ts","../../src/presentation/util/props.ts","../../src/presentation/useDocumentLocations.ts","../../src/presentation/i18n/index.ts","../../src/presentation/usePresentationTool.ts","../../src/presentation/document/useCurrentPresentationToolName.ts","../../src/presentation/document/LocationsBanner.tsx","../../src/presentation/document/PresentationDocumentHeader.tsx","../../src/presentation/document/PresentationDocumentProvider.tsx","../../src/presentation/fieldActions/openInStructure.ts","../../src/presentation/getIntentState.ts","../../src/presentation/PresentationSpinner.tsx","../../src/presentation/router.ts","../../src/presentation/plugin.tsx","../../src/presentation/reducers/presentationReducer.ts","../../src/presentation/usePresentationNavigate.ts","../../src/presentation/usePresentationParams.ts"],"sourcesContent":["import {type Serializable} from '@sanity/presentation-comlink'\nimport {useContext, useEffect} from 'react'\nimport {PresentationSharedStateContext} from 'sanity/_singletons'\n\n/** @public */\nexport const useSharedState = (key: string, value: Serializable): undefined => {\n const context = useContext(PresentationSharedStateContext)\n\n if (!context) {\n throw new Error('Preview Snapshots context is missing')\n }\n\n const {setValue} = context\n\n useEffect(() => {\n setValue(key, value)\n }, [key, value, setValue])\n\n return undefined\n}\n","import {ComposeIcon} from '@sanity/icons'\nimport {apiVersion} from '@sanity/preview-url-secret/constants'\n\nexport const DEFAULT_TOOL_ICON = ComposeIcon\nexport const DEFAULT_TOOL_NAME = 'presentation'\nexport const DEFAULT_TOOL_TITLE = 'Presentation'\n\nexport const EDIT_INTENT_MODE = 'presentation'\n\n// How long we wait until an iframe is loaded until we consider it to be slow and possibly failed\nexport const MAX_TIME_TO_OVERLAYS_CONNECTION = 3_000 // ms\n\n// The API version to use when using `@sanity/client`\nexport const API_VERSION = apiVersion\n\n// Heartbeats shouldn't fire on intervals that are so short it causes performance issues\nexport const MIN_LOADER_QUERY_LISTEN_HEARTBEAT_INTERVAL = 1000 // ms\n\n// How often the list over loader queries should be garbage collected\nexport const LOADER_QUERY_GC_INTERVAL = 30_000 // ms\n\n// The interval at which we check if existing popups have been closed\nexport const POPUP_CHECK_INTERVAL = 1000 // ms\n","import {\n combineLatest,\n from,\n isObservable,\n map,\n mergeAll,\n Observable,\n of,\n scan,\n switchMap,\n} from 'rxjs'\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\ntype Props<K extends keyof any, T> = {\n [P in K]: T | Observable<T>\n}\n\nfunction keysOf<T extends object>(value: T) {\n return Object.keys(value) as (keyof T)[]\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nfunction setKey(source: Record<string, unknown>, key: any, value: unknown) {\n return {\n ...source,\n [key]: value,\n }\n}\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport function props<K extends keyof any, T>(options: {wait?: boolean} = {}) {\n return (source: Observable<Props<K, T>>): Observable<Record<string, unknown>> => {\n return new Observable<Props<K, T>>((observer) => source.subscribe(observer)).pipe(\n switchMap((object) => {\n const keyObservables = keysOf(object).map((key) => {\n const value = object[key]\n return isObservable(value) ? from(value).pipe(map((val) => [key, val])) : of([key, value])\n })\n\n return options.wait\n ? combineLatest(keyObservables).pipe(\n map((pairs) => pairs.reduce((acc, [key, value]) => setKey(acc, key, value), {})),\n )\n : from(keyObservables).pipe(\n mergeAll(),\n scan((acc, [key, value]) => setKey(acc, key, value), {}),\n )\n }),\n )\n }\n}\n","/* eslint-disable @typescript-eslint/no-shadow */\nimport {type StackablePerspective} from '@sanity/client'\nimport {get} from 'lodash'\nimport {useEffect, useMemo, useState} from 'react'\nimport {isObservable, map, type Observable, of, switchMap} from 'rxjs'\nimport {\n type DocumentStore,\n getDraftId,\n getPublishedId,\n getVersionId,\n isRecord,\n isReference,\n type Previewable,\n type SanityDocument,\n useDocumentStore,\n usePerspective,\n} from 'sanity'\n\nimport {\n type DocumentLocationResolver,\n type DocumentLocationResolverObject,\n type DocumentLocationResolvers,\n type DocumentLocationsState,\n type DocumentLocationsStatus,\n} from './types'\nimport {props} from './util/props'\n\nconst INITIAL_STATE: DocumentLocationsState = {locations: []}\n\nfunction getDocumentId(value: Previewable) {\n if (isReference(value)) {\n return value._ref\n }\n return '_id' in value ? value._id : undefined\n}\n\nfunction cleanPreviewable(id: string | undefined, previewable: Previewable) {\n const clean: Record<string, unknown> = id ? {...previewable, _id: id} : {...previewable}\n\n if (clean._type === 'reference') {\n delete clean._type\n delete clean._ref\n delete clean._weak\n delete clean._dataset\n delete clean._projectId\n delete clean._strengthenOnPublish\n }\n\n return clean\n}\n\nfunction listen(\n id: string,\n fields: string[],\n store: DocumentStore,\n perspectiveStack: StackablePerspective[],\n) {\n const projection = fields.join(', ')\n const query = {\n fetch: `*[_id==$id][0]{${projection}}`,\n // TODO: is it more performant to use `||` instead of `in`?\n listen: `*[_id in $versions]`,\n }\n const params = {\n id,\n versions: perspectiveStack\n .map((p) => {\n if (p === 'published') return getPublishedId(id)\n if (p === 'drafts') return getDraftId(id)\n return getVersionId(getPublishedId(id), p)\n })\n .concat(getPublishedId(id)),\n }\n return store.listenQuery(query, params, {\n perspective: perspectiveStack,\n tag: 'use-document-locations',\n }) as Observable<SanityDocument | null>\n}\nfunction observeDocument(\n value: Previewable | null,\n paths: string[][],\n store: DocumentStore,\n perspectiveStack: StackablePerspective[],\n): Observable<Record<string, unknown> | null> {\n if (!value || typeof value !== 'object') {\n return of(value)\n }\n\n const id = getDocumentId(value)\n const currentValue = cleanPreviewable(id, value)\n\n const headlessPaths = paths.filter((path) => !(path[0] in currentValue))\n\n if (id && headlessPaths.length) {\n const fields = [...new Set(headlessPaths.map((path: string[]) => path[0]))]\n return listen(id, fields, store, perspectiveStack).pipe(\n switchMap((snapshot) => {\n if (snapshot) {\n return observeDocument(snapshot, paths, store, perspectiveStack)\n }\n return of(null)\n }),\n )\n }\n\n const leads: Record<string, string[][]> = {}\n paths.forEach((path) => {\n const [head, ...tail] = path\n if (!leads[head]) {\n leads[head] = []\n }\n leads[head].push(tail)\n })\n const next = Object.keys(leads).reduce((res: Record<string, unknown>, head) => {\n const tails = leads[head].filter((tail) => tail.length > 0)\n if (tails.length === 0) {\n res[head] = isRecord(value) ? (value as Record<string, unknown>)[head] : undefined\n } else {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n res[head] = observeDocument((value as any)[head], tails, store, perspectiveStack)\n }\n return res\n }, currentValue)\n\n return of(next).pipe(props({wait: true}))\n}\n\nfunction observeForLocations(\n documentId: string,\n resolver: DocumentLocationResolverObject<string>,\n documentStore: DocumentStore,\n perspectiveStack: StackablePerspective[],\n) {\n const {select} = resolver\n const paths = Object.values(select).map((value) => String(value).split('.')) || []\n const doc = {_type: 'reference', _ref: documentId}\n return observeDocument(doc, paths, documentStore, perspectiveStack).pipe(\n map((doc) => {\n return Object.keys(select).reduce<Record<string, unknown>>((acc, key) => {\n acc[key] = get(doc, select[key])\n return acc\n }, {})\n }),\n map(resolver.resolve),\n )\n}\n\nexport function useDocumentLocations(props: {\n id: string\n version: string | undefined\n resolvers?: DocumentLocationResolver | DocumentLocationResolvers\n type: string\n}): {\n state: DocumentLocationsState\n status: DocumentLocationsStatus\n} {\n const {id, resolvers, type, version} = props\n const documentStore = useDocumentStore()\n const {perspectiveStack} = usePerspective()\n const [locationsState, setLocationsState] = useState<DocumentLocationsState>(INITIAL_STATE)\n\n const resolver = resolvers && (typeof resolvers === 'function' ? resolvers : resolvers[type])\n\n const [locationsStatus, setLocationsStatus] = useState<DocumentLocationsStatus>(\n resolver ? 'resolving' : 'empty',\n )\n\n const result = useMemo(() => {\n if (!resolver) return undefined\n\n // Original/advanced resolver which requires explicit use of Observables\n if (typeof resolver === 'function') {\n const params = {id, type, version, perspectiveStack}\n const context = {documentStore}\n const _result = resolver(params, context)\n return isObservable(_result) ? _result : of(_result)\n }\n\n // Simplified resolver pattern which abstracts away Observable logic\n if ('select' in resolver && 'resolve' in resolver) {\n return observeForLocations(id, resolver, documentStore, perspectiveStack)\n }\n\n // Resolver is explicitly provided state\n return of(resolver)\n }, [documentStore, id, resolver, type, version, perspectiveStack])\n\n useEffect(() => {\n const sub = result?.subscribe((state) => {\n setLocationsState(state || INITIAL_STATE)\n setLocationsStatus(state ? 'resolved' : 'empty')\n })\n\n return () => sub?.unsubscribe()\n }, [result])\n\n return {\n state: locationsState,\n status: locationsStatus,\n }\n}\n","import {defineLocaleResourceBundle} from 'sanity'\n\n/**\n * The locale namespace for the presentation tool\n *\n * @public\n */\nexport const presentationLocaleNamespace = 'presentation' as const\n\n/**\n * The default locale bundle for the presentation tool, which is US English.\n *\n * @internal\n */\nexport const presentationUsEnglishLocaleBundle = defineLocaleResourceBundle({\n locale: 'en-US',\n namespace: presentationLocaleNamespace,\n resources: () => import('./resources'),\n})\n","import {useContext} from 'react'\nimport {PresentationContext} from 'sanity/_singletons'\n\nimport {type PresentationContextValue} from './types'\n\nexport function usePresentationTool(throwOnMissingContext?: true): PresentationContextValue\nexport function usePresentationTool(throwOnMissingContext: false): PresentationContextValue | null\nexport function usePresentationTool(throwOnMissingContext = true): PresentationContextValue | null {\n const presentation = useContext(PresentationContext)\n\n if (throwOnMissingContext && !presentation) {\n throw new Error('Presentation context is missing')\n }\n\n return presentation\n}\n","import {usePresentationTool} from '../usePresentationTool'\n\nexport function useCurrentPresentationToolName(): string | undefined {\n return usePresentationTool(false)?.name ?? undefined\n}\n","import {\n ChevronRightIcon,\n DesktopIcon,\n ErrorOutlineIcon,\n InfoOutlineIcon,\n WarningOutlineIcon,\n} from '@sanity/icons'\nimport {Box, Card, Flex, Spinner, Stack, Text} from '@sanity/ui'\nimport {type ComponentType, type ReactNode, useCallback, useContext, useState} from 'react'\nimport {type ObjectSchemaType, useTranslation} from 'sanity'\nimport {PresentationContext} from 'sanity/_singletons'\nimport {useIntentLink} from 'sanity/router'\n\nimport {DEFAULT_TOOL_NAME, DEFAULT_TOOL_TITLE} from '../constants'\nimport {presentationLocaleNamespace} from '../i18n'\nimport {\n type DocumentLocation,\n type DocumentLocationsState,\n type PresentationPluginOptions,\n} from '../types'\nimport {useCurrentPresentationToolName} from './useCurrentPresentationToolName'\n\nconst TONE_ICONS: Record<'positive' | 'caution' | 'critical', ComponentType> = {\n positive: InfoOutlineIcon,\n caution: WarningOutlineIcon,\n critical: ErrorOutlineIcon,\n}\n\nexport function LocationsBanner(props: {\n documentId: string\n isResolving: boolean\n options: PresentationPluginOptions\n schemaType: ObjectSchemaType\n showPresentationTitle: boolean\n state: DocumentLocationsState\n}): ReactNode {\n const {documentId, isResolving, options, schemaType, showPresentationTitle} = props\n const {locations, message, tone} = props.state\n const len = locations?.length || 0\n\n const {t} = useTranslation(presentationLocaleNamespace)\n const presentation = useContext(PresentationContext)\n const presentationName = presentation?.name\n const [expanded, setExpanded] = useState(false)\n const toggle = useCallback(() => {\n if (!len) return\n setExpanded((v) => !v)\n }, [len])\n\n const title = isResolving\n ? t('locations-banner.resolving.text')\n : message || t('locations-banner.locations-count', {count: len})\n\n const ToneIcon = tone ? TONE_ICONS[tone] : undefined\n\n return (\n <Card padding={1} radius={2} border tone={tone}>\n <div style={{margin: -1}}>\n {!locations && (\n <Flex align=\"flex-start\" gap={3} padding={3}>\n {tone && ToneIcon && (\n <Box flex=\"none\">\n <Text size={1}>\n <ToneIcon />\n </Text>\n </Box>\n )}\n <Box flex={1}>\n <Text size={1} weight=\"medium\">\n {showPresentationTitle && <>{options.title || DEFAULT_TOOL_TITLE} · </>}\n {title}\n </Text>\n </Box>\n </Flex>\n )}\n {locations && (\n <>\n <Card\n as={len ? 'button' : undefined}\n onClick={toggle}\n padding={3}\n radius={1}\n tone=\"inherit\"\n >\n <Flex gap={3}>\n <Box flex=\"none\">\n {isResolving ? (\n <Spinner size={1} />\n ) : (\n <Text size={1}>\n {len === 0 ? (\n <InfoOutlineIcon />\n ) : (\n <ChevronRightIcon\n style={{\n transform: `rotate(${expanded ? '90deg' : 0})`,\n transition: 'transform 100ms ease-in-out',\n }}\n />\n )}\n </Text>\n )}\n </Box>\n <Box flex={1}>\n <Text size={1} weight=\"medium\">\n {showPresentationTitle && <>{options.title || DEFAULT_TOOL_TITLE} · </>}\n {title}\n </Text>\n </Box>\n </Flex>\n </Card>\n <Stack hidden={!expanded} marginTop={1} space={1}>\n {locations.map((l, index) => (\n <LocationItem\n active={\n (options.name || DEFAULT_TOOL_NAME) === presentationName &&\n l.href === presentation?.params.preview\n }\n documentId={documentId}\n documentType={schemaType.name}\n key={index}\n node={l}\n toolName={options.name || DEFAULT_TOOL_NAME}\n />\n ))}\n </Stack>\n </>\n )}\n </div>\n </Card>\n )\n}\n\nfunction LocationItem(props: {\n active: boolean\n documentId: string\n documentType: string\n node: DocumentLocation\n toolName: string\n}) {\n const {documentId, documentType, node, active, toolName} = props\n const presentation = useContext(PresentationContext)\n const currentPresentationToolName = useCurrentPresentationToolName()\n const isCurrentTool = toolName === currentPresentationToolName\n const navigate = presentation?.navigate\n\n const presentationLinkProps = useIntentLink({\n intent: 'edit',\n params: {\n id: documentId,\n type: documentType,\n mode: 'presentation',\n presentation: toolName,\n ...presentation?.structureParams,\n preview: node.href,\n },\n })\n\n const handleCurrentToolClick = useCallback(() => {\n navigate?.({}, {preview: node.href})\n }, [node.href, navigate])\n\n return (\n <Card\n {...(isCurrentTool ? {} : presentationLinkProps)}\n as=\"a\"\n key={node.href}\n onClick={isCurrentTool ? handleCurrentToolClick : presentationLinkProps.onClick}\n padding={3}\n radius={1}\n pressed={active}\n tone=\"inherit\"\n >\n <Flex gap={3}>\n <Box flex=\"none\">\n <Text size={1}>\n <DesktopIcon />\n </Text>\n </Box>\n <Stack flex={1} space={2}>\n <Text size={1} weight=\"medium\">\n {node.title}\n </Text>\n <Text muted size={1} textOverflow=\"ellipsis\">\n {node.href}\n </Text>\n </Stack>\n </Flex>\n </Card>\n )\n}\n","import {rem, Stack} from '@sanity/ui'\nimport {type ReactNode, useContext} from 'react'\nimport {type ObjectSchemaType, type PublishedId} from 'sanity'\nimport {PresentationDocumentContext} from 'sanity/_singletons'\nimport {styled} from 'styled-components'\n\nimport {type PresentationPluginOptions} from '../types'\nimport {useDocumentLocations} from '../useDocumentLocations'\nimport {LocationsBanner} from './LocationsBanner'\n\nconst LocationStack = styled(Stack)`\n min-height: ${rem(42)};\n\n & + &:empty {\n display: none;\n }\n`\n\nexport function PresentationDocumentHeader(props: {\n documentId: PublishedId\n version: string | undefined\n options: PresentationPluginOptions\n schemaType: ObjectSchemaType\n}): ReactNode {\n const {documentId, options, schemaType, version} = props\n const context = useContext(PresentationDocumentContext)\n const {state, status} = useDocumentLocations({\n id: documentId,\n version,\n resolvers: options.resolve?.locations || options.locate,\n type: schemaType.name,\n })\n\n if ((context && context.options[0] !== options) || status === 'empty') {\n return null\n }\n\n const contextOptions = context?.options || []\n\n return (\n <LocationStack marginBottom={5} space={5}>\n <Stack space={2}>\n {contextOptions.map(\n (\n // eslint-disable-next-line @typescript-eslint/no-shadow\n options,\n idx,\n ) => (\n <LocationsBanner\n documentId={documentId}\n isResolving={status === 'resolving'}\n key={idx}\n options={options}\n schemaType={schemaType}\n showPresentationTitle={contextOptions.length > 1}\n state={state}\n />\n ),\n )}\n </Stack>\n </LocationStack>\n )\n}\n","import {type ReactNode, useCallback, useContext, useLayoutEffect, useMemo, useState} from 'react'\nimport {PresentationDocumentContext} from 'sanity/_singletons'\nimport {useEffectEvent} from 'use-effect-event'\n\nimport {type PresentationPluginOptions} from '../types'\nimport {type PresentationDocumentContextValue} from './types'\n\n/** @internal */\nexport function PresentationDocumentProvider(props: {\n children?: ReactNode\n options: PresentationPluginOptions\n}): React.JSX.Element {\n const {children, options} = props\n const parent = useContext(PresentationDocumentContext)\n const parentRegister = parent?.register\n\n const [optionsArray, setOptionsArray] = useState<PresentationPluginOptions[]>(() => [])\n\n const register = useCallback(\n // eslint-disable-next-line @typescript-eslint/no-shadow\n (options: PresentationPluginOptions) => {\n if (parentRegister) {\n return parentRegister(options)\n }\n\n setOptionsArray((prev) => [options].concat(prev))\n\n return () => {\n setOptionsArray((prev) => prev.filter((o) => o !== options))\n }\n },\n [parentRegister],\n )\n\n const context: PresentationDocumentContextValue = useMemo(\n () => ({\n options: parent?.options || optionsArray,\n register,\n }),\n [optionsArray, parent, register],\n )\n\n // eslint-disable-next-line @typescript-eslint/no-shadow\n const registerEffectEvent = useEffectEvent((options: PresentationPluginOptions) =>\n register(options),\n )\n useLayoutEffect(() => registerEffectEvent(options), [options])\n\n return (\n <PresentationDocumentContext.Provider value={context}>\n {children}\n </PresentationDocumentContext.Provider>\n )\n}\n","import {MasterDetailIcon} from '@sanity/icons'\nimport {useContext, useMemo} from 'react'\nimport {\n defineDocumentFieldAction,\n type DocumentFieldActionGroup,\n type DocumentFieldActionItem,\n type DocumentFieldActionProps,\n isRecord,\n pathToString,\n type Tool,\n useWorkspace,\n} from 'sanity'\nimport {PresentationContext} from 'sanity/_singletons'\nimport {useRouter} from 'sanity/router'\n\nimport {DEFAULT_TOOL_NAME} from '../constants'\n\nfunction useOpenInStructureAction(\n props: DocumentFieldActionProps,\n): DocumentFieldActionItem | DocumentFieldActionGroup {\n const {documentId, documentType, path} = props\n const workspace = useWorkspace()\n const {navigateIntent} = useRouter()\n const presentation = useContext(PresentationContext)\n\n const defaultStructureTool = useMemo(\n () =>\n findStructureTool(\n workspace.tools,\n documentId,\n documentType,\n presentation?.name || DEFAULT_TOOL_NAME,\n ),\n [documentId, documentType, workspace.tools, presentation],\n )\n\n return {\n type: 'action',\n hidden: !presentation || path.length > 0 || !defaultStructureTool,\n icon: defaultStructureTool?.icon || MasterDetailIcon,\n title: `Open in ${defaultStructureTool?.title || 'Structure'}`,\n onAction() {\n navigateIntent('edit', {\n id: documentId,\n type: documentType,\n mode: 'structure',\n path: pathToString(path),\n })\n },\n renderAsButton: true,\n }\n}\n\nexport const openInStructure = defineDocumentFieldAction({\n name: 'presentation/openInStructure',\n useAction: useOpenInStructureAction,\n})\n\nfunction findStructureTool(\n tools: Tool[],\n documentId: string,\n documentType: string,\n presentationToolName?: string,\n): Tool | undefined {\n const results = tools\n .filter((t) => t.name !== presentationToolName)\n .map((t) => {\n const match = t.canHandleIntent?.(\n 'edit',\n {\n id: documentId,\n type: documentType,\n mode: 'structure',\n },\n {},\n )\n\n return {tool: t, match}\n })\n\n const modeMatches = results.filter((t) => isRecord(t.match) && t.match.mode)\n\n if (modeMatches.length > 0) {\n return modeMatches[0].tool\n }\n\n const matches = results.filter((t) => t.match)\n\n return matches[0]?.tool\n}\n","import {uuid} from '@sanity/uuid'\nimport {getPublishedId} from 'sanity'\nimport {encodeJsonParams, type RouterState, type SearchParam} from 'sanity/router'\n\nimport {type PresentationSearchParams, type PresentationStateParams} from './types'\n\nconst preservedSearchParamKeys: Array<keyof PresentationSearchParams> = ['preview', 'viewport']\n\n/**\n * @internal\n */\nexport function getIntentState(\n intent: string,\n params: Record<string, string>,\n routerState: RouterState | undefined,\n payload: unknown,\n):\n | (PresentationStateParams & {_searchParams: SearchParam[]})\n | {intent: string; params: Record<string, string>; payload: unknown} {\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {id, mode, path, presentation, type, ...searchParams} = params\n\n const preservedSearchParams = (routerState?._searchParams || [])\n // @todo Casting https://github.com/microsoft/TypeScript/issues/14520\n .filter(([key]) => preservedSearchParamKeys.includes(key as keyof PresentationSearchParams))\n .reduce((acc, [key, value]) => ({...acc, [key]: value}), {} as Record<string, string>)\n\n const _searchParams = {\n ...preservedSearchParams,\n ...searchParams,\n }\n\n if (intent === 'edit' && id) {\n _searchParams.preview =\n _searchParams.preview || new URLSearchParams(window.location.search).get('preview') || '/'\n return {\n type: type || '*',\n id: getPublishedId(id),\n path,\n _searchParams: Object.entries(_searchParams),\n }\n }\n\n if (intent === 'create') {\n _searchParams.preview =\n _searchParams.preview || new URLSearchParams(window.location.search).get('preview') || '/'\n\n if (payload && typeof payload === 'object') {\n _searchParams.templateParams = encodeJsonParams(payload as Record<string, unknown>)\n }\n\n return {\n type: type || '*',\n id: id || uuid(),\n _searchParams: Object.entries(_searchParams),\n }\n }\n return {intent, params, payload}\n}\n","import {Flex, Spinner} from '@sanity/ui'\n\nexport function PresentationSpinner(): React.JSX.Element {\n return (\n <Flex align=\"center\" direction=\"column\" height=\"fill\" justify=\"center\" style={{width: '100%'}}>\n <Spinner />\n </Flex>\n )\n}\n","import {route} from 'sanity/router'\n\n// eslint-disable-next-line camelcase\nexport const router = route.create('/', {__unsafe_disableScopedSearchParams: true}, [\n route.intents('/intent'),\n route.create(':type', [route.create(':id', [route.create(':path')])]),\n])\n","import {type SanityDocument} from '@sanity/client'\nimport {lazy, Suspense} from 'react'\nimport {\n definePlugin,\n getPublishedId,\n getVersionFromId,\n type InputProps,\n isDocumentSchemaType,\n} from 'sanity'\n\nimport {DEFAULT_TOOL_ICON, DEFAULT_TOOL_NAME, EDIT_INTENT_MODE} from './constants'\nimport {PresentationDocumentHeader} from './document/PresentationDocumentHeader'\nimport {PresentationDocumentProvider} from './document/PresentationDocumentProvider'\nimport {openInStructure} from './fieldActions/openInStructure'\nimport {getIntentState} from './getIntentState'\nimport {presentationUsEnglishLocaleBundle} from './i18n'\nimport {PresentationSpinner} from './PresentationSpinner'\nimport {router} from './router'\nimport {\n type DocumentLocationResolverObject,\n type DocumentLocationsState,\n type DocumentResolver,\n type PresentationPluginOptions,\n} from './types'\n\nconst PresentationTool = lazy(() => import('./PresentationToolGrantsCheck'))\nconst BroadcastDisplayedDocument = lazy(() => import('./loader/BroadcastDisplayedDocument'))\n\n/**\n * Define locations for a given document type.\n * This function doesn't do anything itself, it is used to provide type information.\n * @param resolver - resolver that return locations for a document.\n * @public\n */\nexport function defineLocations<K extends string>(\n resolver: DocumentLocationResolverObject<K> | DocumentLocationsState,\n): typeof resolver {\n return resolver\n}\n\n/**\n * Define documents for a given location.\n * This function doesn't do anything itself, it is used to provide type information.\n * @param resolvers - resolvers that return documents.\n * @public\n */\nexport function defineDocuments(resolvers: DocumentResolver[]): typeof resolvers {\n return resolvers\n}\n\n/** @public */\nexport const presentationTool = definePlugin<PresentationPluginOptions>((options) => {\n const toolName = options.name || DEFAULT_TOOL_NAME\n\n if ('locate' in options) {\n // eslint-disable-next-line no-console\n console.warn('Presentation’s `locate` option is deprecated. Use `resolve.locations` instead.')\n }\n\n const hasLocationsResolver = !!(options.resolve?.locations || options.locate)\n\n function PresentationDocumentInput(props: InputProps) {\n const value = props.value as SanityDocument\n const documentId = value?._id ? getPublishedId(value?._id) : undefined\n const documentVersion = value?._id ? getVersionFromId(value._id) : undefined\n if (isDocumentSchemaType(props.schemaType)) {\n return (\n <PresentationDocumentProvider options={options}>\n {hasLocationsResolver && documentId && (\n <PresentationDocumentHeader\n documentId={documentId}\n version={documentVersion}\n options={options}\n schemaType={props.schemaType}\n />\n )}\n <Suspense fallback={<PresentationSpinner />}>{props.renderDefault(props)}</Suspense>\n <Suspense key=\"broadcast-displayed-document\">\n <BroadcastDisplayedDocument key={documentId} value={value} />\n </Suspense>\n </PresentationDocumentProvider>\n )\n }\n\n return props.renderDefault(props)\n }\n\n function canHandleCreateIntent(params: Record<string, unknown>) {\n // We can't handle create intents without a `type` parameter\n if (!('type' in params)) {\n return false\n }\n\n if ('presentation' in params && params.presentation !== toolName) {\n return false\n }\n\n return 'template' in params ? {template: true} : true\n }\n\n function canHandleEditIntent(params: Record<string, unknown>) {\n // We can't handle edit intents without `type` or `id` parameters\n if (!('type' in params) || !('id' in params)) {\n return false\n }\n\n if ('presentation' in params && params.presentation !== toolName) {\n return false\n }\n\n return 'mode' in params ? {mode: params.mode === EDIT_INTENT_MODE} : true\n }\n\n return {\n i18n: {\n bundles: [presentationUsEnglishLocaleBundle],\n },\n document: {\n unstable_fieldActions: (prev) => {\n return [\n ...prev.filter((a) => a.name !== openInStructure.name), // prevent duplication\n openInStructure,\n ]\n },\n },\n\n form: {\n components: {\n input: PresentationDocumentInput,\n },\n },\n\n tools: [\n {\n icon: options.icon || DEFAULT_TOOL_ICON,\n name: toolName,\n title: options.title,\n component: PresentationTool,\n options,\n canHandleIntent(intent, params) {\n if (intent === 'create') return canHandleCreateIntent(params)\n if (intent === 'edit') return canHandleEditIntent(params)\n return false\n },\n getIntentState,\n router,\n __internalApplicationType: 'sanity/presentation',\n },\n ],\n }\n})\n","import {type Dispatch, type Reducer} from 'react'\nimport {boolean, fallback, object, parse, picklist} from 'valibot'\n\n/** @public */\nexport interface PresentationState {\n mainDocument: boolean\n iframe: {\n status: 'loading' | 'loaded' | 'refreshing' | 'reloading'\n }\n visualEditing: {\n overlaysEnabled: boolean\n }\n}\n\n/** @public */\nexport const ACTION_IFRAME_LOADED = 'ACTION_IFRAME_LOADED'\n/** @public */\nexport const ACTION_IFRAME_REFRESH = 'ACTION_IFRAME_REFRESH'\n/** @public */\nexport const ACTION_IFRAME_RELOAD = 'ACTION_IFRAME_RELOAD'\n/** @public */\nexport const ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE = 'ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE'\n\n/** @public */\nexport interface IframeLoadedAction {\n type: typeof ACTION_IFRAME_LOADED\n}\n/** @public */\nexport interface IframeRefreshAction {\n type: typeof ACTION_IFRAME_REFRESH\n}\n/** @public */\nexport interface IframeReloadAction {\n type: typeof ACTION_IFRAME_RELOAD\n}\n/** @public */\nexport interface VisualEditingOverlaysToggleAction {\n type: typeof ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE\n enabled: boolean\n}\n\n/** @public */\nexport type PresentationAction =\n | IframeLoadedAction\n | IframeRefreshAction\n | IframeReloadAction\n | VisualEditingOverlaysToggleAction\n\nexport const presentationReducer: Reducer<\n Readonly<PresentationState>,\n Readonly<PresentationAction>\n> = (state, action) => {\n switch (action.type) {\n case ACTION_IFRAME_LOADED:\n return state.iframe.status === 'loaded'\n ? state\n : {\n ...state,\n iframe: {\n ...state.iframe,\n status: 'loaded',\n },\n }\n case ACTION_IFRAME_REFRESH:\n return state.iframe.status === 'refreshing'\n ? state\n : {\n ...state,\n iframe: {\n ...state.iframe,\n status: 'refreshing',\n },\n }\n case ACTION_IFRAME_RELOAD:\n return state.iframe.status === 'reloading'\n ? state\n : {\n ...state,\n iframe: {\n ...state.iframe,\n status: 'reloading',\n },\n }\n case ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE:\n return toggleVisualEditingOverlays(state, action)\n default:\n return state\n }\n}\n\nconst toggleVisualEditingOverlays: Reducer<\n Readonly<PresentationState>,\n Readonly<VisualEditingOverlaysToggleAction>\n> = (state, action) => {\n if (state.visualEditing.overlaysEnabled === action.enabled) return state\n return {\n ...state,\n visualEditing: {\n ...state.visualEditing,\n overlaysEnabled: action.enabled,\n },\n }\n}\n\nconst mainDocumentSchema = fallback(boolean(), false)\n\nconst iframeStatusSchema = picklist(['loading', 'loaded', 'refreshing', 'reloading'])\n\nconst initStateSchema = object({\n mainDocument: mainDocumentSchema,\n iframe: object({\n status: iframeStatusSchema,\n }),\n visualEditing: object({overlaysEnabled: boolean()}),\n})\n\nconst INITIAL_PRESENTATION_STATE = {\n mainDocument: false,\n iframe: {\n status: 'loading',\n },\n visualEditing: {\n overlaysEnabled: false,\n },\n} as const satisfies PresentationState\n\nexport function presentationReducerInit(\n state: Readonly<Partial<PresentationState>>,\n): Readonly<PresentationState> {\n return parse(initStateSchema, {...INITIAL_PRESENTATION_STATE, ...state})\n}\n\n/** @public */\nexport type DispatchPresentationAction = Dispatch<Readonly<PresentationAction>>\n","import {useContext} from 'react'\nimport {PresentationNavigateContext} from 'sanity/_singletons'\n\nimport {type PresentationNavigateContextValue} from './types'\n\n/** @public */\nexport function usePresentationNavigate(): PresentationNavigateContextValue {\n const navigate = useContext(PresentationNavigateContext)\n\n if (!navigate) {\n throw new Error('Presentation navigate context is missing')\n }\n\n return navigate\n}\n\nexport type {PresentationNavigateContextValue}\n","import {useContext} from 'react'\nimport {PresentationParamsContext} from 'sanity/_singletons'\n\nimport {type PresentationParamsContextValue} from './types'\n\n/** @public */\nexport function usePresentationParams(throwOnMissingContext?: true): PresentationParamsContextValue\n/** @public */\nexport function usePresentationParams(\n throwOnMissingContext: false,\n): PresentationParamsContextValue | null\n/** @public */\nexport function usePresentationParams(\n throwOnMissingContext = true,\n): PresentationParamsContextValue | null {\n const params = useContext(PresentationParamsContext)\n\n if (throwOnMissingContext && !params) {\n throw new Error('Presentation params context is missing')\n }\n\n return params\n}\n"],"names":["useSharedState","key","value","$","_c","context","useContext","PresentationSharedStateContext","Error","setValue","t0","t1","useEffect","DEFAULT_TOOL_ICON","ComposeIcon","DEFAULT_TOOL_NAME","DEFAULT_TOOL_TITLE","EDIT_INTENT_MODE","MAX_TIME_TO_OVERLAYS_CONNECTION","API_VERSION","apiVersion","MIN_LOADER_QUERY_LISTEN_HEARTBEAT_INTERVAL","LOADER_QUERY_GC_INTERVAL","POPUP_CHECK_INTERVAL","keysOf","Object","keys","setKey","source","props","options","Observable","observer","subscribe","pipe","switchMap","object","keyObservables","map","isObservable","from","val","of","wait","combineLatest","pairs","reduce","acc","mergeAll","scan","INITIAL_STATE","locations","getDocumentId","isReference","_ref","_id","undefined","cleanPreviewable","id","previewable","clean","_type","_weak","_dataset","_projectId","_strengthenOnPublish","listen","fields","store","perspectiveStack","query","fetch","join","params","versions","p","getPublishedId","getDraftId","getVersionId","concat","listenQuery","perspective","tag","observeDocument","paths","currentValue","headlessPaths","filter","path","length","Set","snapshot","leads","forEach","head","tail","push","next","res","tails","isRecord","observeForLocations","documentId","resolver","documentStore","select","values","String","split","doc","get","resolve","useDocumentLocations","resolvers","type","version","useDocumentStore","usePerspective","locationsState","setLocationsState","useState","locationsStatus","setLocationsStatus","bb0","_result","result","t2","sub","state","unsubscribe","t3","status","presentationLocaleNamespace","presentationUsEnglishLocaleBundle","defineLocaleResourceBundle","locale","namespace","resources","usePresentationTool","throwOnMissingContext","presentation","PresentationContext","useCurrentPresentationToolName","name","TONE_ICONS","positive","InfoOutlineIcon","caution","WarningOutlineIcon","critical","ErrorOutlineIcon","LocationsBanner","isResolving","schemaType","showPresentationTitle","message","tone","len","t","useTranslation","presentationName","expanded","setExpanded","_temp","toggle","count","title","ToneIcon","Symbol","for","margin","t4","transform","transition","l","index","href","preview","t5","t6","v","LocationItem","documentType","node","active","toolName","currentPresentationToolName","isCurrentTool","navigate","structureParams","intent","mode","presentationLinkProps","useIntentLink","handleCurrentToolClick","onClick","t7","t8","t9","LocationStack","styled","Stack","rem","PresentationDocumentHeader","PresentationDocumentContext","locate","contextOptions","options_0","idx","PresentationDocumentProvider","children","parent","parentRegister","register","optionsArray","setOptionsArray","prev","prev_0","o","options_1","registerEffectEvent","useEffectEvent","useLayoutEffect","useOpenInStructureAction","workspace","useWorkspace","navigateIntent","useRouter","tools","findStructureTool","defaultStructureTool","icon","MasterDetailIcon","hidden","onAction","pathToString","renderAsButton","openInStructure","defineDocumentFieldAction","useAction","presentationToolName","results","match","canHandleIntent","tool","modeMatches","preservedSearchParamKeys","getIntentState","routerState","payload","searchParams","_searchParams","includes","URLSearchParams","window","location","search","entries","templateParams","encodeJsonParams","uuid","PresentationSpinner","width","router","route","create","__unsafe_disableScopedSearchParams","intents","PresentationTool","lazy","BroadcastDisplayedDocument","defineLocations","defineDocuments","presentationTool","definePlugin","console","warn","hasLocationsResolver","PresentationDocumentInput","getVersionFromId","documentVersion","isDocumentSchemaType","renderDefault","canHandleCreateIntent","template","canHandleEditIntent","i18n","bundles","document","unstable_fieldActions","a","form","components","input","component","__internalApplicationType","ACTION_IFRAME_LOADED","ACTION_IFRAME_REFRESH","ACTION_IFRAME_RELOAD","ACTION_VISUAL_EDITING_OVERLAYS_TOGGLE","presentationReducer","action","iframe","toggleVisualEditingOverlays","visualEditing","overlaysEnabled","enabled","mainDocumentSchema","fallback","boolean","iframeStatusSchema","picklist","initStateSchema","mainDocument","INITIAL_PRESENTATION_STATE","presentationReducerInit","parse","usePresentationNavigate","PresentationNavigateContext","usePresentationParams","PresentationParamsContext"],"mappings":";;;;;;;;;;;;;;;AAKaA,MAAAA,iBAAiBA,CAAAC,KAAAC,UAAA;AAAA,QAAAC,IAAAC,EAAA,CAAA,GAC5BC,UAAgBC,WAAAC,8BAAyC;AAAC,MAAA,CAErDF;AAAOG,UAAAA,IAAAA,MACM,sCAAsC;AAGxD,QAAA;AAAA,IAAAC;AAAAA,EAAAA,IAAmBJ;AAAO,MAAAK,IAAAC;AAAAR,IAAAF,CAAAA,MAAAA,OAAAE,SAAAM,YAAAN,EAAA,CAAA,MAAAD,SAEhBQ,KAAAA,MAAA;AACRD,aAASR,KAAKC,KAAK;AAAA,EAAA,GAClBS,KAACV,CAAAA,KAAKC,OAAOO,QAAQ,GAACN,OAAAF,KAAAE,OAAAM,UAAAN,OAAAD,OAAAC,OAAAO,IAAAP,OAAAQ,OAAAD,KAAAP,EAAA,CAAA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EA+D,SAAenE,WAAA0T,yBAAoC;AAAC,MAEhDrL,0BAA0BlE;AAAMjE,UAAAA,IAAAA,MAClB,wCAAwC;AAGnDiE,SAAAA;AAAM;"}
|
@@ -35,14 +35,6 @@ var resources = {
|
|
35
35
|
"presentation-error.label": "Error message",
|
36
36
|
/** The text shown when the preview frame cannot connect to Presentation */
|
37
37
|
"preview-frame.connection.error.text": "Could not connect to the preview",
|
38
|
-
/** The title of the error toast that shows when the preview iframe times out while waiting for a connection over comlink to establish, and the root cause is discovered to be that the iframe is loading on an URL origin that's not in the allow list. */
|
39
|
-
"preview-frame.configuration.error.title": "Preview URL origin mismatch",
|
40
|
-
/** The toast description for the error message explaining that the iframe is blocked from loading due to a security mismatch. */
|
41
|
-
"preview-frame.configuration.error.description": "The preview iframe is configured to load <Code>{{targetOrigin}}</Code>, but the reported origin is <Code>{{reportedOrigin}}</Code>. Presentation Tool is unable to connect to unknown origins for security purposes. Update your <Code>presentationTool.allowOrigins</Code> configuration to allow connecting to Visual Editing and Loaders.",
|
42
|
-
/** The title of the error toast that shows when attempting to navigate to a preview URL origin that's not in the allow list. */
|
43
|
-
"preview-search-param.configuration.error.title": "Blocked preview URL",
|
44
|
-
/** The toast description for the error message explaining that the iframe won't navigate to the new preview URL due to an URL origin security mismatch. */
|
45
|
-
"preview-search-param.configuration.error.description": "The router wants to navigate to <Code>{{previewSearchParam}}</Code>, but the origin <Code>{{blockedOrigin}}</Code> is not allowed. Update your <Code>presentationTool.allowOrigins</Code> configuration to allow it.",
|
46
38
|
/** The text shown on the button for dismissing the error overlay after a timeout */
|
47
39
|
"preview-frame.continue-button.text": "Continue anyway",
|
48
40
|
/** The label for the loader's connection status */
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"resources6.mjs","sources":["../../src/presentation/i18n/resources.ts"],"sourcesContent":["export default {\n /** The title shown above the document list */\n 'document-list-pane.document-list.title': 'Documents on this page',\n /** The text shown if the document list is unable to render */\n 'document-list-pane.error.text': 'Could not render the document list',\n /** The status of the channel connection */\n 'channel.status_connected': 'Connected',\n /** The status of the channel connection */\n 'channel.status_connecting': 'Connecting',\n /** The status of the channel connection */\n 'channel.status_disconnected': 'Disconnected',\n /** The status of the channel connection */\n 'channel.status_reconnecting': 'Reconnecting',\n /** The text shown if the document editor is unable to render */\n 'document-pane.error.text': 'Could not render the document editor',\n /** The text shown on the button for bypassing after a connection has failed */\n 'error-card.continue-button.text': 'Continue anyway',\n /** The text shown on the button for retrying after a connection has failed */\n 'error-card.retry-button.text': 'Retry',\n /** The title on the card shown after a connection has failed */\n 'error-card.title': 'An error occurred',\n /** The text shown when the document is used in a single location */\n 'locations-banner.locations-count_one': 'Used on one page',\n /** The text shown when the document is used in multiple locations */\n 'locations-banner.locations-count_other': 'Used on {{count}} pages',\n /** The text shown when a resolver exists but the document is not used in any locations */\n 'locations-banner.locations-count_zero': 'Not used on any pages',\n /** The text shown whilst the locations resolver is executing */\n 'locations-banner.resolving.text': 'Resolving locations...',\n /** The label shown on a main document in the list pane */\n 'main-document.label': 'Main document',\n /** The warning message text shown when a defined resolver fails to return a main document */\n 'main-document.missing.text': 'Missing a main document for <Code>{{path}}</Code>',\n /** The label for a generic error message */\n 'presentation-error.label': 'Error message',\n /** The text shown when the preview frame cannot connect to Presentation */\n 'preview-frame.connection.error.text': 'Could not connect to the preview',\n /** The title of the error toast that shows when the preview iframe times out while waiting for a connection over comlink to establish, and the root cause is discovered to be that the iframe is loading on an URL origin that's not in the allow list. */\n 'preview-frame.configuration.error.title': 'Preview URL origin mismatch',\n /** The toast description for the error message explaining that the iframe is blocked from loading due to a security mismatch. */\n 'preview-frame.configuration.error.description':\n 'The preview iframe is configured to load <Code>{{targetOrigin}}</Code>, but the reported origin is <Code>{{reportedOrigin}}</Code>. Presentation Tool is unable to connect to unknown origins for security purposes. Update your <Code>presentationTool.allowOrigins</Code> configuration to allow connecting to Visual Editing and Loaders.',\n /** The title of the error toast that shows when attempting to navigate to a preview URL origin that's not in the allow list. */\n 'preview-search-param.configuration.error.title': 'Blocked preview URL',\n /** The toast description for the error message explaining that the iframe won't navigate to the new preview URL due to an URL origin security mismatch. */\n 'preview-search-param.configuration.error.description':\n 'The router wants to navigate to <Code>{{previewSearchParam}}</Code>, but the origin <Code>{{blockedOrigin}}</Code> is not allowed. Update your <Code>presentationTool.allowOrigins</Code> configuration to allow it.',\n /** The text shown on the button for dismissing the error overlay after a timeout */\n 'preview-frame.continue-button.text': 'Continue anyway',\n /** The label for the loader's connection status */\n 'preview-frame.loader.connection-status.label': 'Loader connection status',\n /** The `aria-label` for the navigator toggle button */\n 'preview-frame.navigator.toggle-button.aria-label': 'Toggle navigator',\n /** The tooltip text for the navigator toggle button */\n 'preview-frame.navigator.toggle-button.tooltip': 'Toggle navigator',\n /** The label for the overlay's connection status */\n 'preview-frame.overlay.connection-status.label': 'Overlay connection status',\n /** The text shown on the overlay toggle button */\n 'preview-frame.overlay.toggle-button.text': 'Edit',\n /** The text shown on the overlay toggle tooltip when overlays are enabled */\n 'preview-frame.overlay.toggle-button.tooltip_disable': 'Disable edit overlay',\n /** The text shown on the overlay toggle tooltip when overlays are disabled */\n 'preview-frame.overlay.toggle-button.tooltip_enable': 'Enable edit overlay',\n /** The text description for the published perspective switcher menu item */\n 'preview-frame.perspective.published.text': 'View this page with published content',\n /** The `aria-label` for the refresh button */\n 'preview-frame.refresh-button.aria-label': 'Refresh preview',\n /** The tooltip text for the refresh button */\n 'preview-frame.refresh-button.tooltip': 'Refresh preview',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_connecting': 'Connecting.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_loading': 'Loading.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_refreshing': 'Refreshing.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_reloading': 'Refreshing.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_timeout':\n 'Unable to connect, check the browser console for more information.',\n /** The `aria-label` for the button that switches viewport size */\n 'preview-frame.viewport-button.aria-label': 'Toggle viewport size',\n /** The viewport size button tooltip text when switching to a full width viewport */\n 'preview-frame.viewport-button.tooltip_full': 'Switch to full viewport',\n /** The viewport size button tooltip text when switching to a narrow viewport */\n 'preview-frame.viewport-button.tooltip_narrow': 'Switch to narrow viewport',\n /** The validation error message shown when the preview location input is missing an origin */\n 'preview-location-input.error_missing-origin': 'URL must start with {{origin}}',\n /** The validation error message shown when the preview location input's base path matches that of the studio */\n 'preview-location-input.error_same-base-path':\n 'URL can’t have the same base path as the Studio {{basePath}}',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_copying': 'Copying URL to clipboard…',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_failed': 'Copy failed',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_success': 'The URL is copied to the clipboard',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_unsupported': 'Clipboard not supported',\n /** The share URL menu item text for opening a preview window */\n 'share-url.menu-item.open.text': 'Open preview',\n /** Error toast that notifies that URL Preview Secrets can't be generated as the user lacks ACL grants */\n 'preview-url-secret.missing-grants':\n \"You don't have permission to create URL Preview Secrets. This will likely cause the preview to fail loading.\",\n /** The `aria-label` for the button that opens the share menu */\n 'preview-frame.share-button.aria-label': 'Share this preview',\n /** The <title> for the QR Code SVG that shows a link to the current preview */\n 'share-preview-menu.qr-code.title': 'A QR Code which encodes the URL: {{url}}',\n /** Error message toast that shows the current user does not have permission to toggle sharing of the current preview */\n 'share-preview-menu.error_toggle-sharing':\n \"You don't have permission to toggle sharing of this preview\",\n /** The text shown on the sharing toggle tooltip when sharing is enabled */\n 'share-preview-menu.toggle-button.tooltip_disable': 'Disable sharing',\n /** The text shown on the sharing toggle tooltip when sharing is disabled */\n 'share-preview-menu.toggle-button.tooltip_enable': 'Enable sharing',\n /** The first line of the label that renders next to the sharing toggle, it renders on two rows */\n 'share-preview-menu.toggle-button.label_first-line': 'Share this preview',\n /** The second line of the label that renders next to the sharing toggle, it renders on two rows */\n 'share-preview-menu.toggle-button.label_second-line': 'with anyone who has the link',\n /** Placeholder message for the QR Code SVG when sharing is yet to be enabled */\n 'share-preview-menu.qr-code.placeholder': 'QR code will appear here',\n /** The text show below the QR Code SVG, with instructions on how to use it */\n 'share-preview-menu.qr-code.instructions': 'Scan the QR Code to open the preview on your phone.',\n /** Menu item in the share preview menu that allows copying the current preview URL, if sharing is enabled */\n 'share-preview-menu.copy-url.text': 'Copy preview link',\n /** Fallback message shown when the current user is not permitted to share previews */\n 'share-preview-menu.error_missing-grants': \"You don't have permission to share previews. \",\n}\n"],"names":[],"mappings":"AAAA,IAAe,YAAA;AAAA;AAAA,EAEb,0CAA0C;AAAA;AAAA,EAE1C,iCAAiC;AAAA;AAAA,EAEjC,4BAA4B;AAAA;AAAA,EAE5B,6BAA6B;AAAA;AAAA,EAE7B,+BAA+B;AAAA;AAAA,EAE/B,+BAA+B;AAAA;AAAA,EAE/B,4BAA4B;AAAA;AAAA,EAE5B,mCAAmC;AAAA;AAAA,EAEnC,gCAAgC;AAAA;AAAA,EAEhC,oBAAoB;AAAA;AAAA,EAEpB,wCAAwC;AAAA;AAAA,EAExC,0CAA0C;AAAA;AAAA,EAE1C,yCAAyC;AAAA;AAAA,EAEzC,mCAAmC;AAAA;AAAA,EAEnC,uBAAuB;AAAA;AAAA,EAEvB,8BAA8B;AAAA;AAAA,EAE9B,4BAA4B;AAAA;AAAA,EAE5B,uCAAuC;AAAA;AAAA,EAEvC,2CAA2C;AAAA;AAAA,EAE3C,iDACE;AAAA;AAAA,EAEF,kDAAkD;AAAA;AAAA,EAElD,wDACE;AAAA;AAAA,EAEF,sCAAsC;AAAA;AAAA,EAEtC,gDAAgD;AAAA;AAAA,EAEhD,oDAAoD;AAAA;AAAA,EAEpD,iDAAiD;AAAA;AAAA,EAEjD,iDAAiD;AAAA;AAAA,EAEjD,4CAA4C;AAAA;AAAA,EAE5C,uDAAuD;AAAA;AAAA,EAEvD,sDAAsD;AAAA;AAAA,EAEtD,4CAA4C;AAAA;AAAA,EAE5C,2CAA2C;AAAA;AAAA,EAE3C,wCAAwC;AAAA;AAAA,EAExC,mCAAmC;AAAA;AAAA,EAEnC,gCAAgC;AAAA;AAAA,EAEhC,mCAAmC;AAAA;AAAA,EAEnC,kCAAkC;AAAA;AAAA,EAElC,gCACE;AAAA;AAAA,EAEF,4CAA4C;AAAA;AAAA,EAE5C,8CAA8C;AAAA;AAAA,EAE9C,gDAAgD;AAAA;AAAA,EAEhD,+CAA+C;AAAA;AAAA,EAE/C,+CACE;AAAA;AAAA,EAEF,sCAAsC;AAAA;AAAA,EAEtC,qCAAqC;AAAA;AAAA,EAErC,sCAAsC;AAAA;AAAA,EAEtC,0CAA0C;AAAA;AAAA,EAE1C,iCAAiC;AAAA;AAAA,EAEjC,qCACE;AAAA;AAAA,EAEF,yCAAyC;AAAA;AAAA,EAEzC,oCAAoC;AAAA;AAAA,EAEpC,2CACE;AAAA;AAAA,EAEF,oDAAoD;AAAA;AAAA,EAEpD,mDAAmD;AAAA;AAAA,EAEnD,qDAAqD;AAAA;AAAA,EAErD,sDAAsD;AAAA;AAAA,EAEtD,0CAA0C;AAAA;AAAA,EAE1C,2CAA2C;AAAA;AAAA,EAE3C,oCAAoC;AAAA;AAAA,EAEpC,2CAA2C;AAC7C;"}
|
1
|
+
{"version":3,"file":"resources6.mjs","sources":["../../src/presentation/i18n/resources.ts"],"sourcesContent":["export default {\n /** The title shown above the document list */\n 'document-list-pane.document-list.title': 'Documents on this page',\n /** The text shown if the document list is unable to render */\n 'document-list-pane.error.text': 'Could not render the document list',\n /** The status of the channel connection */\n 'channel.status_connected': 'Connected',\n /** The status of the channel connection */\n 'channel.status_connecting': 'Connecting',\n /** The status of the channel connection */\n 'channel.status_disconnected': 'Disconnected',\n /** The status of the channel connection */\n 'channel.status_reconnecting': 'Reconnecting',\n /** The text shown if the document editor is unable to render */\n 'document-pane.error.text': 'Could not render the document editor',\n /** The text shown on the button for bypassing after a connection has failed */\n 'error-card.continue-button.text': 'Continue anyway',\n /** The text shown on the button for retrying after a connection has failed */\n 'error-card.retry-button.text': 'Retry',\n /** The title on the card shown after a connection has failed */\n 'error-card.title': 'An error occurred',\n /** The text shown when the document is used in a single location */\n 'locations-banner.locations-count_one': 'Used on one page',\n /** The text shown when the document is used in multiple locations */\n 'locations-banner.locations-count_other': 'Used on {{count}} pages',\n /** The text shown when a resolver exists but the document is not used in any locations */\n 'locations-banner.locations-count_zero': 'Not used on any pages',\n /** The text shown whilst the locations resolver is executing */\n 'locations-banner.resolving.text': 'Resolving locations...',\n /** The label shown on a main document in the list pane */\n 'main-document.label': 'Main document',\n /** The warning message text shown when a defined resolver fails to return a main document */\n 'main-document.missing.text': 'Missing a main document for <Code>{{path}}</Code>',\n /** The label for a generic error message */\n 'presentation-error.label': 'Error message',\n /** The text shown when the preview frame cannot connect to Presentation */\n 'preview-frame.connection.error.text': 'Could not connect to the preview',\n /** The text shown on the button for dismissing the error overlay after a timeout */\n 'preview-frame.continue-button.text': 'Continue anyway',\n /** The label for the loader's connection status */\n 'preview-frame.loader.connection-status.label': 'Loader connection status',\n /** The `aria-label` for the navigator toggle button */\n 'preview-frame.navigator.toggle-button.aria-label': 'Toggle navigator',\n /** The tooltip text for the navigator toggle button */\n 'preview-frame.navigator.toggle-button.tooltip': 'Toggle navigator',\n /** The label for the overlay's connection status */\n 'preview-frame.overlay.connection-status.label': 'Overlay connection status',\n /** The text shown on the overlay toggle button */\n 'preview-frame.overlay.toggle-button.text': 'Edit',\n /** The text shown on the overlay toggle tooltip when overlays are enabled */\n 'preview-frame.overlay.toggle-button.tooltip_disable': 'Disable edit overlay',\n /** The text shown on the overlay toggle tooltip when overlays are disabled */\n 'preview-frame.overlay.toggle-button.tooltip_enable': 'Enable edit overlay',\n /** The text description for the published perspective switcher menu item */\n 'preview-frame.perspective.published.text': 'View this page with published content',\n /** The `aria-label` for the refresh button */\n 'preview-frame.refresh-button.aria-label': 'Refresh preview',\n /** The tooltip text for the refresh button */\n 'preview-frame.refresh-button.tooltip': 'Refresh preview',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_connecting': 'Connecting.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_loading': 'Loading.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_refreshing': 'Refreshing.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_reloading': 'Refreshing.',\n /** Text describing the current status of the preview frame */\n 'preview-frame.status_timeout':\n 'Unable to connect, check the browser console for more information.',\n /** The `aria-label` for the button that switches viewport size */\n 'preview-frame.viewport-button.aria-label': 'Toggle viewport size',\n /** The viewport size button tooltip text when switching to a full width viewport */\n 'preview-frame.viewport-button.tooltip_full': 'Switch to full viewport',\n /** The viewport size button tooltip text when switching to a narrow viewport */\n 'preview-frame.viewport-button.tooltip_narrow': 'Switch to narrow viewport',\n /** The validation error message shown when the preview location input is missing an origin */\n 'preview-location-input.error_missing-origin': 'URL must start with {{origin}}',\n /** The validation error message shown when the preview location input's base path matches that of the studio */\n 'preview-location-input.error_same-base-path':\n 'URL can’t have the same base path as the Studio {{basePath}}',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_copying': 'Copying URL to clipboard…',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_failed': 'Copy failed',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_success': 'The URL is copied to the clipboard',\n /** The status of the clipboard operation when copying a URL */\n 'share-url.clipboard.status_unsupported': 'Clipboard not supported',\n /** The share URL menu item text for opening a preview window */\n 'share-url.menu-item.open.text': 'Open preview',\n /** Error toast that notifies that URL Preview Secrets can't be generated as the user lacks ACL grants */\n 'preview-url-secret.missing-grants':\n \"You don't have permission to create URL Preview Secrets. This will likely cause the preview to fail loading.\",\n /** The `aria-label` for the button that opens the share menu */\n 'preview-frame.share-button.aria-label': 'Share this preview',\n /** The <title> for the QR Code SVG that shows a link to the current preview */\n 'share-preview-menu.qr-code.title': 'A QR Code which encodes the URL: {{url}}',\n /** Error message toast that shows the current user does not have permission to toggle sharing of the current preview */\n 'share-preview-menu.error_toggle-sharing':\n \"You don't have permission to toggle sharing of this preview\",\n /** The text shown on the sharing toggle tooltip when sharing is enabled */\n 'share-preview-menu.toggle-button.tooltip_disable': 'Disable sharing',\n /** The text shown on the sharing toggle tooltip when sharing is disabled */\n 'share-preview-menu.toggle-button.tooltip_enable': 'Enable sharing',\n /** The first line of the label that renders next to the sharing toggle, it renders on two rows */\n 'share-preview-menu.toggle-button.label_first-line': 'Share this preview',\n /** The second line of the label that renders next to the sharing toggle, it renders on two rows */\n 'share-preview-menu.toggle-button.label_second-line': 'with anyone who has the link',\n /** Placeholder message for the QR Code SVG when sharing is yet to be enabled */\n 'share-preview-menu.qr-code.placeholder': 'QR code will appear here',\n /** The text show below the QR Code SVG, with instructions on how to use it */\n 'share-preview-menu.qr-code.instructions': 'Scan the QR Code to open the preview on your phone.',\n /** Menu item in the share preview menu that allows copying the current preview URL, if sharing is enabled */\n 'share-preview-menu.copy-url.text': 'Copy preview link',\n /** Fallback message shown when the current user is not permitted to share previews */\n 'share-preview-menu.error_missing-grants': \"You don't have permission to share previews. \",\n}\n"],"names":[],"mappings":"AAAA,IAAe,YAAA;AAAA;AAAA,EAEb,0CAA0C;AAAA;AAAA,EAE1C,iCAAiC;AAAA;AAAA,EAEjC,4BAA4B;AAAA;AAAA,EAE5B,6BAA6B;AAAA;AAAA,EAE7B,+BAA+B;AAAA;AAAA,EAE/B,+BAA+B;AAAA;AAAA,EAE/B,4BAA4B;AAAA;AAAA,EAE5B,mCAAmC;AAAA;AAAA,EAEnC,gCAAgC;AAAA;AAAA,EAEhC,oBAAoB;AAAA;AAAA,EAEpB,wCAAwC;AAAA;AAAA,EAExC,0CAA0C;AAAA;AAAA,EAE1C,yCAAyC;AAAA;AAAA,EAEzC,mCAAmC;AAAA;AAAA,EAEnC,uBAAuB;AAAA;AAAA,EAEvB,8BAA8B;AAAA;AAAA,EAE9B,4BAA4B;AAAA;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