@contentful/experiences-sdk-react 1.35.1-dev-20250326T1508-9517b58.0 → 1.35.1-dev-20250326T1536-723a32d.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.
@@ -1 +1 @@
1
- {"version":3,"file":"ExperienceRoot.js","sources":["../../src/ExperienceRoot.tsx"],"sourcesContent":["'use client';\nimport React from 'react';\nimport {\n VisualEditorMode,\n createExperience,\n validateExperienceBuilderConfig,\n debug as cfDebug,\n} from '@contentful/experiences-core';\nimport { EntityStore } from '@contentful/experiences-core';\nimport type { Experience } from '@contentful/experiences-core/types';\nimport { PreviewDeliveryRoot } from './blocks/preview/PreviewDeliveryRoot';\nimport VisualEditorRoot from './blocks/editor/VisualEditorRoot';\nimport { useDetectCanvasMode } from './hooks/useDetectCanvasMode';\nimport { StudioCanvasMode } from '@contentful/experiences-core/constants';\n\ntype ExperienceRootProps = {\n experience?: Experience<EntityStore> | string | null;\n locale: string;\n visualEditorMode?: VisualEditorMode;\n /** Enables extra logging in the SDK to support troubleshooting.\n * This option is not recommended for production enviroments as it\n * will result in too many unnecessary logs being produced during runtime.\n * Default: false\n */\n debug?: boolean;\n};\n\nexport const ExperienceRoot = ({\n locale,\n experience,\n visualEditorMode = VisualEditorMode.LazyLoad,\n debug,\n}: ExperienceRootProps) => {\n const mode = useDetectCanvasMode();\n\n if (typeof debug === 'boolean') {\n cfDebug.setEnabled(debug);\n }\n\n //If experience is passed in as a JSON string, recreate it to an experience object\n const experienceObject =\n typeof experience === 'string' ? createExperience(experience) : experience;\n\n validateExperienceBuilderConfig({\n locale,\n mode,\n });\n\n if (mode === StudioCanvasMode.EDITOR || mode === StudioCanvasMode.READ_ONLY) {\n return (\n <VisualEditorRoot\n experience={experienceObject as Experience<EntityStore> | undefined}\n visualEditorMode={visualEditorMode}\n initialLocale={locale}\n />\n );\n }\n\n if (!experienceObject) return null;\n\n return <PreviewDeliveryRoot locale={locale} experience={experienceObject} />;\n};\n"],"names":[],"mappings":";;;;;;;;AA2Ba;AAMX;AAEA;AACE;;;AAIF;AAGA;;;AAGC;AAED;AACE;;AASF;AAAuB;;AAGzB;;"}
1
+ {"version":3,"file":"ExperienceRoot.js","sources":["../../src/ExperienceRoot.tsx"],"sourcesContent":["'use client';\nimport React from 'react';\nimport {\n VisualEditorMode,\n createExperience,\n validateExperienceBuilderConfig,\n debug as cfDebug,\n} from '@contentful/experiences-core';\nimport { EntityStore } from '@contentful/experiences-core';\nimport type { Experience } from '@contentful/experiences-core/types';\nimport { PreviewDeliveryRoot } from './blocks/preview/PreviewDeliveryRoot';\nimport VisualEditorRoot from './blocks/editor/VisualEditorRoot';\nimport { useDetectCanvasMode } from './hooks/useDetectCanvasMode';\nimport { StudioCanvasMode } from '@contentful/experiences-core/constants';\n\ntype ExperienceRootProps = {\n experience?: Experience<EntityStore> | string | null;\n locale: string;\n visualEditorMode?: VisualEditorMode;\n /** Enables extra logging in the SDK to support troubleshooting.\n * This option is not recommended for production environments as it\n * will result in too many unnecessary logs being produced during runtime.\n * Default: false\n */\n debug?: boolean;\n};\n\nexport const ExperienceRoot = ({\n locale,\n experience,\n visualEditorMode = VisualEditorMode.LazyLoad,\n debug,\n}: ExperienceRootProps) => {\n const mode = useDetectCanvasMode();\n\n if (typeof debug === 'boolean') {\n cfDebug.setEnabled(debug);\n }\n\n //If experience is passed in as a JSON string, recreate it to an experience object\n const experienceObject =\n typeof experience === 'string' ? createExperience(experience) : experience;\n\n validateExperienceBuilderConfig({\n locale,\n mode,\n });\n\n if (mode === StudioCanvasMode.EDITOR || mode === StudioCanvasMode.READ_ONLY) {\n return (\n <VisualEditorRoot\n experience={experienceObject as Experience<EntityStore> | undefined}\n visualEditorMode={visualEditorMode}\n initialLocale={locale}\n />\n );\n }\n\n if (!experienceObject) return null;\n\n return <PreviewDeliveryRoot locale={locale} experience={experienceObject} />;\n};\n"],"names":[],"mappings":";;;;;;;;AA2Ba;AAMX;AAEA;AACE;;;AAIF;AAGA;;;AAGC;AAED;AACE;;AASF;AAAuB;;AAGzB;;"}
package/dist/index.d.ts CHANGED
@@ -8,14 +8,14 @@ import * as _contentful_experiences_core_constants from '@contentful/experiences
8
8
  export { CF_STYLE_ATTRIBUTES, CONTENTFUL_COMPONENTS, LATEST_SCHEMA_VERSION } from '@contentful/experiences-core/constants';
9
9
  import { ContentfulClientApi } from 'contentful';
10
10
 
11
- declare const SDK_VERSION = "1.35.1-dev-20250326T1508-9517b58.0";
11
+ declare const SDK_VERSION = "1.35.1-dev-20250326T1536-723a32d.0";
12
12
 
13
13
  type ExperienceRootProps = {
14
14
  experience?: Experience<EntityStore> | string | null;
15
15
  locale: string;
16
16
  visualEditorMode?: VisualEditorMode;
17
17
  /** Enables extra logging in the SDK to support troubleshooting.
18
- * This option is not recommended for production enviroments as it
18
+ * This option is not recommended for production environments as it
19
19
  * will result in too many unnecessary logs being produced during runtime.
20
20
  * Default: false
21
21
  */
@@ -1,4 +1,4 @@
1
- const SDK_VERSION = '1.35.1-dev-20250326T1508-9517b58.0';
1
+ const SDK_VERSION = '1.35.1-dev-20250326T1536-723a32d.0';
2
2
 
3
3
  export { SDK_VERSION };
4
4
  //# sourceMappingURL=sdkVersion.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"sdkVersion.js","sources":["../../src/sdkVersion.ts"],"sourcesContent":["export const SDK_VERSION = '1.35.1-dev-20250326T1508-9517b58.0';\n"],"names":[],"mappings":"AAAO,MAAM,WAAW,GAAG;;;;"}
1
+ {"version":3,"file":"sdkVersion.js","sources":["../../src/sdkVersion.ts"],"sourcesContent":["export const SDK_VERSION = '1.35.1-dev-20250326T1536-723a32d.0';\n"],"names":[],"mappings":"AAAO,MAAM,WAAW,GAAG;;;;"}
@@ -6,7 +6,7 @@ type ExperienceRootProps = {
6
6
  locale: string;
7
7
  visualEditorMode?: VisualEditorMode;
8
8
  /** Enables extra logging in the SDK to support troubleshooting.
9
- * This option is not recommended for production enviroments as it
9
+ * This option is not recommended for production environments as it
10
10
  * will result in too many unnecessary logs being produced during runtime.
11
11
  * Default: false
12
12
  */
@@ -1 +1 @@
1
- export declare const SDK_VERSION = "1.35.1-dev-20250326T1508-9517b58.0";
1
+ export declare const SDK_VERSION = "1.35.1-dev-20250326T1536-723a32d.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@contentful/experiences-sdk-react",
3
- "version": "1.35.1-dev-20250326T1508-9517b58.0",
3
+ "version": "1.35.1-dev-20250326T1536-723a32d.0",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.js",
6
6
  "typings": "./dist/src/index.d.ts",
@@ -41,10 +41,10 @@
41
41
  "depcruise": "depcruise src"
42
42
  },
43
43
  "dependencies": {
44
- "@contentful/experiences-components-react": "1.35.1-dev-20250326T1508-9517b58.0",
45
- "@contentful/experiences-core": "1.35.1-dev-20250326T1508-9517b58.0",
46
- "@contentful/experiences-validators": "1.35.1-dev-20250326T1508-9517b58.0",
47
- "@contentful/experiences-visual-editor-react": "1.35.1-dev-20250326T1508-9517b58.0",
44
+ "@contentful/experiences-components-react": "1.35.1-dev-20250326T1536-723a32d.0",
45
+ "@contentful/experiences-core": "1.35.1-dev-20250326T1536-723a32d.0",
46
+ "@contentful/experiences-validators": "1.35.1-dev-20250326T1536-723a32d.0",
47
+ "@contentful/experiences-visual-editor-react": "1.35.1-dev-20250326T1536-723a32d.0",
48
48
  "@contentful/rich-text-types": "^17.0.0",
49
49
  "classnames": "^2.3.2",
50
50
  "csstype": "^3.1.2",
@@ -102,5 +102,5 @@
102
102
  "dist",
103
103
  "package.json"
104
104
  ],
105
- "gitHead": "b56dec2295e460263f29f3f1b9d02bc0a52ead50"
105
+ "gitHead": "e9cd3b2e471f5d543d84a27ae0a0c8eee04f2683"
106
106
  }