@commercetools-demo/puck-editor 0.6.0 → 0.6.1

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.js CHANGED
@@ -3833,12 +3833,24 @@ var nimbusFieldTypes = {
3833
3833
  var import_nimbus9 = require("@commercetools/nimbus");
3834
3834
 
3835
3835
  // src/EnsureNimbusProvider.tsx
3836
+ var import_styled_system = require("@chakra-ui/react/styled-system");
3836
3837
  var import_nimbus8 = require("@commercetools/nimbus");
3837
3838
  var import_jsx_runtime43 = require("react/jsx-runtime");
3839
+ var SCOPED_SYSTEM_KEY = /* @__PURE__ */ Symbol.for(
3840
+ "@commercetools-demo/puck:nimbus-scoped-system"
3841
+ );
3842
+ var globalScope = globalThis;
3843
+ var scopedSystem = globalScope[SCOPED_SYSTEM_KEY] ?? (globalScope[SCOPED_SYSTEM_KEY] = (0, import_styled_system.createSystem)({
3844
+ // `_config` is the fully-merged Nimbus + Chakra config used to build the
3845
+ // stock system; reusing it keeps all Nimbus theming intact.
3846
+ ...import_nimbus8.system._config,
3847
+ preflight: false,
3848
+ globalCss: {}
3849
+ }));
3838
3850
  var EnsureNimbusProvider = ({
3839
3851
  locale = "en",
3840
3852
  children
3841
- }) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_nimbus8.NimbusProvider, { locale, children });
3853
+ }) => /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_styled_system.ChakraProvider, { value: scopedSystem, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_nimbus8.NimbusI18nProvider, { locale, children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_nimbus8._RegionProvider, { children }) }) });
3842
3854
 
3843
3855
  // src/PuckEditor.tsx
3844
3856
  var import_jsx_runtime44 = require("react/jsx-runtime");