@cmssy/react 12.9.0 → 12.11.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/dist/index.cjs +6 -3
- package/dist/index.d.cts +3 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +6 -3
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -403,15 +403,18 @@ async function resolveCmssyLayoutSlot(config, options) {
|
|
|
403
403
|
forms,
|
|
404
404
|
appContext,
|
|
405
405
|
path,
|
|
406
|
-
locale: explicitLocale
|
|
406
|
+
locale: explicitLocale,
|
|
407
|
+
retry
|
|
407
408
|
} = options;
|
|
408
|
-
const
|
|
409
|
+
const requestOptions = { retry: retry ?? "build" };
|
|
410
|
+
const siteLocales = await locale.resolveSiteLocales(config, requestOptions);
|
|
409
411
|
const fromPath = path ? locale.splitLocaleFromPath(path, siteLocales) : { locale: siteLocales.defaultLocale, path: [] };
|
|
410
412
|
const locale$1 = explicitLocale ?? fromPath.locale;
|
|
411
413
|
const slugSegments = fromPath.path ?? [];
|
|
412
414
|
const pageSlug = page ?? "/" + slugSegments.join("/");
|
|
413
415
|
const groups = await internal.fetchLayouts(config, pageSlug, {
|
|
414
|
-
previewSecret: editMode ? config.draftSecret : void 0
|
|
416
|
+
previewSecret: editMode ? config.draftSecret : void 0,
|
|
417
|
+
...requestOptions
|
|
415
418
|
});
|
|
416
419
|
const base = {
|
|
417
420
|
groups,
|
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { CmssyPageData, CmssyClientConfig, CmssyFormDefinition, CmssyBlockAuthContext, CmssyBlockWorkspace, CmssyLayoutGroup, CmssyConfig, RawBlock, CmssyBlockContext } from '@cmssy/core';
|
|
2
|
-
export { AppToEditorMessage, BlockMeta, BlockPropsSchema, BlockRect, BlockSchema, BoundsMessage, BuildBlockContextExtra, ClickMessage, CmssyBlockAuthContext, CmssyBlockContext, CmssyBlockMember, CmssyBlockPage, CmssyBlockWorkspace, CmssyBranding, CmssyClient, CmssyClientConfig, CmssyFormDefinition, CmssyFormField, CmssyFormSettings, CmssyFormSubmitResponse, CmssyLayoutGroup, CmssyLayoutSettings, CmssyLocaleContext, CmssyLocalizedValue, CmssyModelDefinition, CmssyModelRecord, CmssyPageData, CmssyPageMeta, CmssyPageSummary, CmssyRecordList, CmssyRequestError, CmssySiteConfig, CmssyTypedDocument, EditorToAppMessage, FetchLike, FetchLikeResponse, FetchPageOptions, FieldControl, FieldDefinition, FieldType, GraphqlRequestOptions, InferBlockContent, LayoutPosition, MediaLike, PROTOCOL_VERSION, ParentReadyMessage, PatchMessage, PostTarget, QueryScopedOptions, RawBlock, RawLayoutBlock, ReadyMessage, RetryPolicy, SelectMessage, SubmitFormInput, TypedField, createCmssyClient, fields, graphqlRequest, isProtocolCompatible, layoutPositionValues, mediaAlt, mediaUrl, mediaUrls, normalizeOrigin, parseEditorMessage, postToEditor } from '@cmssy/core';
|
|
1
|
+
import { CmssyPageData, CmssyClientConfig, CmssyFormDefinition, CmssyBlockAuthContext, CmssyBlockWorkspace, CmssyLayoutGroup, RetryOption, CmssyConfig, RawBlock, CmssyBlockContext } from '@cmssy/core';
|
|
2
|
+
export { AppToEditorMessage, BlockMeta, BlockPropsSchema, BlockRect, BlockSchema, BoundsMessage, BuildBlockContextExtra, ClickMessage, CmssyBlockAuthContext, CmssyBlockContext, CmssyBlockMember, CmssyBlockPage, CmssyBlockWorkspace, CmssyBranding, CmssyClient, CmssyClientConfig, CmssyFormDefinition, CmssyFormField, CmssyFormSettings, CmssyFormSubmitResponse, CmssyLayoutGroup, CmssyLayoutSettings, CmssyLocaleContext, CmssyLocalizedValue, CmssyModelDefinition, CmssyModelRecord, CmssyPageData, CmssyPageMeta, CmssyPageSummary, CmssyRecordList, CmssyRequestError, CmssyRetryMode, CmssySiteConfig, CmssyTypedDocument, EditorToAppMessage, FetchLike, FetchLikeResponse, FetchPageOptions, FieldControl, FieldDefinition, FieldType, GraphqlRequestOptions, InferBlockContent, LayoutPosition, MediaLike, PROTOCOL_VERSION, ParentReadyMessage, PatchMessage, PostTarget, QueryScopedOptions, RawBlock, RawLayoutBlock, ReadyMessage, RetryOption, RetryPolicy, SelectMessage, SubmitFormInput, TypedField, createCmssyClient, fields, graphqlRequest, isProtocolCompatible, layoutPositionValues, mediaAlt, mediaUrl, mediaUrls, normalizeOrigin, parseEditorMessage, postToEditor } from '@cmssy/core';
|
|
3
3
|
import { B as BlockDefinition, a as BlockMap } from './registry-CwJ2cby4.cjs';
|
|
4
4
|
export { b as BlockProps, c as buildBlockMap, d as defineBlock } from './registry-CwJ2cby4.cjs';
|
|
5
5
|
import { FieldDefinition } from '@cmssy/types';
|
|
@@ -31,6 +31,7 @@ interface ResolveCmssyLayoutSlotBase {
|
|
|
31
31
|
page?: string;
|
|
32
32
|
forms?: Record<string, CmssyFormDefinition>;
|
|
33
33
|
appContext?: Record<string, unknown>;
|
|
34
|
+
retry?: RetryOption;
|
|
34
35
|
}
|
|
35
36
|
type CmssyLayoutSlotLocaleSource = {
|
|
36
37
|
path: string[];
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { CmssyPageData, CmssyClientConfig, CmssyFormDefinition, CmssyBlockAuthContext, CmssyBlockWorkspace, CmssyLayoutGroup, CmssyConfig, RawBlock, CmssyBlockContext } from '@cmssy/core';
|
|
2
|
-
export { AppToEditorMessage, BlockMeta, BlockPropsSchema, BlockRect, BlockSchema, BoundsMessage, BuildBlockContextExtra, ClickMessage, CmssyBlockAuthContext, CmssyBlockContext, CmssyBlockMember, CmssyBlockPage, CmssyBlockWorkspace, CmssyBranding, CmssyClient, CmssyClientConfig, CmssyFormDefinition, CmssyFormField, CmssyFormSettings, CmssyFormSubmitResponse, CmssyLayoutGroup, CmssyLayoutSettings, CmssyLocaleContext, CmssyLocalizedValue, CmssyModelDefinition, CmssyModelRecord, CmssyPageData, CmssyPageMeta, CmssyPageSummary, CmssyRecordList, CmssyRequestError, CmssySiteConfig, CmssyTypedDocument, EditorToAppMessage, FetchLike, FetchLikeResponse, FetchPageOptions, FieldControl, FieldDefinition, FieldType, GraphqlRequestOptions, InferBlockContent, LayoutPosition, MediaLike, PROTOCOL_VERSION, ParentReadyMessage, PatchMessage, PostTarget, QueryScopedOptions, RawBlock, RawLayoutBlock, ReadyMessage, RetryPolicy, SelectMessage, SubmitFormInput, TypedField, createCmssyClient, fields, graphqlRequest, isProtocolCompatible, layoutPositionValues, mediaAlt, mediaUrl, mediaUrls, normalizeOrigin, parseEditorMessage, postToEditor } from '@cmssy/core';
|
|
1
|
+
import { CmssyPageData, CmssyClientConfig, CmssyFormDefinition, CmssyBlockAuthContext, CmssyBlockWorkspace, CmssyLayoutGroup, RetryOption, CmssyConfig, RawBlock, CmssyBlockContext } from '@cmssy/core';
|
|
2
|
+
export { AppToEditorMessage, BlockMeta, BlockPropsSchema, BlockRect, BlockSchema, BoundsMessage, BuildBlockContextExtra, ClickMessage, CmssyBlockAuthContext, CmssyBlockContext, CmssyBlockMember, CmssyBlockPage, CmssyBlockWorkspace, CmssyBranding, CmssyClient, CmssyClientConfig, CmssyFormDefinition, CmssyFormField, CmssyFormSettings, CmssyFormSubmitResponse, CmssyLayoutGroup, CmssyLayoutSettings, CmssyLocaleContext, CmssyLocalizedValue, CmssyModelDefinition, CmssyModelRecord, CmssyPageData, CmssyPageMeta, CmssyPageSummary, CmssyRecordList, CmssyRequestError, CmssyRetryMode, CmssySiteConfig, CmssyTypedDocument, EditorToAppMessage, FetchLike, FetchLikeResponse, FetchPageOptions, FieldControl, FieldDefinition, FieldType, GraphqlRequestOptions, InferBlockContent, LayoutPosition, MediaLike, PROTOCOL_VERSION, ParentReadyMessage, PatchMessage, PostTarget, QueryScopedOptions, RawBlock, RawLayoutBlock, ReadyMessage, RetryOption, RetryPolicy, SelectMessage, SubmitFormInput, TypedField, createCmssyClient, fields, graphqlRequest, isProtocolCompatible, layoutPositionValues, mediaAlt, mediaUrl, mediaUrls, normalizeOrigin, parseEditorMessage, postToEditor } from '@cmssy/core';
|
|
3
3
|
import { B as BlockDefinition, a as BlockMap } from './registry-CwJ2cby4.js';
|
|
4
4
|
export { b as BlockProps, c as buildBlockMap, d as defineBlock } from './registry-CwJ2cby4.js';
|
|
5
5
|
import { FieldDefinition } from '@cmssy/types';
|
|
@@ -31,6 +31,7 @@ interface ResolveCmssyLayoutSlotBase {
|
|
|
31
31
|
page?: string;
|
|
32
32
|
forms?: Record<string, CmssyFormDefinition>;
|
|
33
33
|
appContext?: Record<string, unknown>;
|
|
34
|
+
retry?: RetryOption;
|
|
34
35
|
}
|
|
35
36
|
type CmssyLayoutSlotLocaleSource = {
|
|
36
37
|
path: string[];
|
package/dist/index.js
CHANGED
|
@@ -403,15 +403,18 @@ async function resolveCmssyLayoutSlot(config, options) {
|
|
|
403
403
|
forms,
|
|
404
404
|
appContext,
|
|
405
405
|
path,
|
|
406
|
-
locale: explicitLocale
|
|
406
|
+
locale: explicitLocale,
|
|
407
|
+
retry
|
|
407
408
|
} = options;
|
|
408
|
-
const
|
|
409
|
+
const requestOptions = { retry: retry ?? "build" };
|
|
410
|
+
const siteLocales = await resolveSiteLocales(config, requestOptions);
|
|
409
411
|
const fromPath = path ? splitLocaleFromPath(path, siteLocales) : { locale: siteLocales.defaultLocale, path: [] };
|
|
410
412
|
const locale = explicitLocale ?? fromPath.locale;
|
|
411
413
|
const slugSegments = fromPath.path ?? [];
|
|
412
414
|
const pageSlug = page ?? "/" + slugSegments.join("/");
|
|
413
415
|
const groups = await fetchLayouts(config, pageSlug, {
|
|
414
|
-
previewSecret: editMode ? config.draftSecret : void 0
|
|
416
|
+
previewSecret: editMode ? config.draftSecret : void 0,
|
|
417
|
+
...requestOptions
|
|
415
418
|
});
|
|
416
419
|
const base = {
|
|
417
420
|
groups,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cmssy/react",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.11.0",
|
|
4
4
|
"description": "React blocks, renderers, data client and editor bridge for cmssy headless sites",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cmssy",
|
|
@@ -97,7 +97,7 @@
|
|
|
97
97
|
},
|
|
98
98
|
"dependencies": {
|
|
99
99
|
"@cmssy/types": "0.35.0",
|
|
100
|
-
"@cmssy/core": "12.
|
|
100
|
+
"@cmssy/core": "12.11.0"
|
|
101
101
|
},
|
|
102
102
|
"scripts": {
|
|
103
103
|
"build": "tsup",
|