@gem-sdk/core 1.14.0-dev.373 → 1.14.0-dev.377

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
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),react=require("react"),composeAdvanceStyle=require("../helpers/compose-advance-style.js"),constant=require("./constant.js"),RenderCustomCode=require("./RenderCustomCode.js"),ComponentToolbarPreview=require("./ComponentToolbarPreview.js");const ComponentWrapperPreview=({children:e,...t})=>{if("section"===t.type)return null;let o={};if("Section"===t.tag&&t.isThemeSection&&(o["data-theme-section"]=!0),t.editorConfigs){let e=t.editorConfigs;e.placeholder?.notAppendBeforeAfter&&(o["data-placeholder-not-append-before-after"]=!0),e.toolbar?.parent&&(o["data-toolbar-parent"]=!0),e.component?.noDelete&&(o["data-component-no-delete"]=!0),e.component?.noDuplicate&&(o["data-component-no-duplicate"]=!0),e.component?.noDragDrop&&(o["data-component-no-drag-drop"]=!0),e.component?.noSetting&&(o["data-component-no-setting"]=!0),e.component?.isThirdParty&&(o["data-component-is-third-party"]=!0),e.toolbar?.hide&&(o["data-toolbar-hide"]=!0),e.slots?.children&&(o["data-slots-children"]=!0),e.toolbar?.hide||(o["data-toolbar-wrap"]=!0)}t?.editorConfigs?.toolbar?.hide||(o["data-toolbar-wrap"]=!0);let n=composeAdvanceStyle.composeAdvanceStyle(t.advanced,t.tag),a=t.advanced,r={...o,"data-uid":t.uid,"data-component-type":"component","data-component-tag":t.tag,"data-component-label":t.label};return constant.disableWrap.includes(t.tag)&&react.isValidElement(e)?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(RenderCustomCode.default,{uid:t.uid,advanced:a}),jsxRuntime.jsxs(e.type,{className:a?.cssClass,...e.props,style:n,builderAttrs:r,advanced:a,children:[e.props.children,jsxRuntime.jsx(ComponentToolbarPreview.ComponentToolbarPreview,{...t})]})]}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(RenderCustomCode.default,{uid:t.uid,advanced:a}),jsxRuntime.jsxs("div",{style:t.editorConfigs?.component?.excludeApplyStyle?{}:n,className:`${t.uid} ${t.advanced?.cssClass?t.advanced?.cssClass:""}`,...r,children:[!t.editorConfigs?.component?.validate&&e,react.isValidElement(e)&&t.editorConfigs?.component?.validate&&jsxRuntime.jsx(e.type,{...e.props,style:n,advanced:a}),jsxRuntime.jsx(ComponentToolbarPreview.ComponentToolbarPreview,{...t})]})]})};exports.default=ComponentWrapperPreview;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var jsxRuntime=require("react/jsx-runtime"),react=require("react"),composeAdvanceStyle=require("../helpers/compose-advance-style.js"),constant=require("./constant.js"),RenderCustomCode=require("./RenderCustomCode.js"),ComponentToolbarPreview=require("./ComponentToolbarPreview.js");const ComponentWrapperPreview=({children:e,...t})=>{if("section"===t.type)return null;let o={};if("Section"===t.tag&&t.isThemeSection&&(o["data-theme-section"]=!0),t.editorConfigs){let e=t.editorConfigs;e.placeholder?.notAppendBeforeAfter&&(o["data-placeholder-not-append-before-after"]=!0),e.toolbar?.parent&&(o["data-toolbar-parent"]=!0),e.component?.noDelete&&(o["data-component-no-delete"]=!0),e.component?.noDuplicate&&(o["data-component-no-duplicate"]=!0),e.component?.noDragDrop&&(o["data-component-no-drag-drop"]=!0),e.component?.noSetting&&(o["data-component-no-setting"]=!0),e.component?.isThirdParty&&(o["data-component-is-third-party"]=!0),e.toolbar?.hide&&(o["data-toolbar-hide"]=!0),e.slots?.children&&(o["data-slots-children"]=!0),e.toolbar?.hide||(o["data-toolbar-wrap"]=!0)}t?.editorConfigs?.toolbar?.hide||(o["data-toolbar-wrap"]=!0);let n=composeAdvanceStyle.composeAdvanceStyle(t.advanced,t.tag),a=t.advanced,r={...o,"data-uid":t.uid,"data-component-type":"component","data-component-tag":t.tag,"data-component-label":t.label};return constant.disableWrap.includes(t.tag)&&react.isValidElement(e)?jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(RenderCustomCode.default,{uid:t.uid,advanced:a}),jsxRuntime.jsxs(e.type,{className:a?.cssClass,...e.props,style:n,builderAttrs:r,advanced:a,children:[e.props.children,jsxRuntime.jsx(ComponentToolbarPreview.ComponentToolbarPreview,{...t})]})]}):jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[jsxRuntime.jsx(RenderCustomCode.default,{uid:t.uid,advanced:a}),jsxRuntime.jsxs("div",{style:constant.excludeApplyStyle.includes(t.tag)?{}:n,className:`${t.uid} ${t.advanced?.cssClass?t.advanced?.cssClass:""}`,...r,children:[!constant.excludeApplyStyle.includes(t.tag)&&e,react.isValidElement(e)&&constant.excludeApplyStyle.includes(t.tag)&&jsxRuntime.jsx(e.type,{...e.props,style:n,advanced:a}),jsxRuntime.jsx(ComponentToolbarPreview.ComponentToolbarPreview,{...t})]})]})};exports.default=ComponentWrapperPreview;
@@ -1 +1 @@
1
- "use strict";const disableWrap=["Col","CollectionBanner","Row","Section","Image","Text","Button","ProductButton","Cart","Tabs","TabItem","Carousel","CarouselItem","ShopPayButton","AccordionItem","Video","Header","HeroBanner","Icon","IconList","HTMLCode","IconListHoz","IconListItem","CSSCode","FormEmail","FormDropdown","SubmitButton","Dialog","TextField","FormTextarea","ProductPrice","Product","ProductImages","ProductImagesV2","Sticky"],customRenderChildren=["Accordion","AccordionItem","Row","IconList","Tabs"];exports.customRenderChildren=customRenderChildren,exports.disableWrap=disableWrap;
1
+ "use strict";const disableWrap=["Col","CollectionBanner","Row","Section","Image","Text","Button","ProductButton","Cart","Tabs","TabItem","Carousel","CarouselItem","ShopPayButton","AccordionItem","Video","Header","HeroBanner","Icon","IconList","HTMLCode","IconListHoz","IconListItem","CSSCode","FormEmail","FormDropdown","SubmitButton","Dialog","TextField","FormTextarea","ProductPrice","Product","ProductImages","ProductImagesV2","Sticky"],customRenderChildren=["Accordion","AccordionItem","Row","IconList","Tabs"],excludeApplyStyle=["IconListV2","Accordion"];exports.customRenderChildren=customRenderChildren,exports.disableWrap=disableWrap,exports.excludeApplyStyle=excludeApplyStyle;
@@ -1 +1 @@
1
- import{jsxs as e,Fragment as o,jsx as t}from"react/jsx-runtime";import{isValidElement as a}from"react";import{composeAdvanceStyle as n}from"../helpers/compose-advance-style.js";import{disableWrap as r}from"./constant.js";import d from"./RenderCustomCode.js";import{ComponentToolbarPreview as p}from"./ComponentToolbarPreview.js";let ComponentWrapperPreview=({children:i,...l})=>{if("section"===l.type)return null;let c={};if("Section"===l.tag&&l.isThemeSection&&(c["data-theme-section"]=!0),l.editorConfigs){let e=l.editorConfigs;e.placeholder?.notAppendBeforeAfter&&(c["data-placeholder-not-append-before-after"]=!0),e.toolbar?.parent&&(c["data-toolbar-parent"]=!0),e.component?.noDelete&&(c["data-component-no-delete"]=!0),e.component?.noDuplicate&&(c["data-component-no-duplicate"]=!0),e.component?.noDragDrop&&(c["data-component-no-drag-drop"]=!0),e.component?.noSetting&&(c["data-component-no-setting"]=!0),e.component?.isThirdParty&&(c["data-component-is-third-party"]=!0),e.toolbar?.hide&&(c["data-toolbar-hide"]=!0),e.slots?.children&&(c["data-slots-children"]=!0),e.toolbar?.hide||(c["data-toolbar-wrap"]=!0)}l?.editorConfigs?.toolbar?.hide||(c["data-toolbar-wrap"]=!0);let s=n(l.advanced,l.tag),m=l.advanced,f={...c,"data-uid":l.uid,"data-component-type":"component","data-component-tag":l.tag,"data-component-label":l.label};return r.includes(l.tag)&&a(i)?e(o,{children:[t(d,{uid:l.uid,advanced:m}),e(i.type,{className:m?.cssClass,...i.props,style:s,builderAttrs:f,advanced:m,children:[i.props.children,t(p,{...l})]})]}):e(o,{children:[t(d,{uid:l.uid,advanced:m}),e("div",{style:l.editorConfigs?.component?.excludeApplyStyle?{}:s,className:`${l.uid} ${l.advanced?.cssClass?l.advanced?.cssClass:""}`,...f,children:[!l.editorConfigs?.component?.validate&&i,a(i)&&l.editorConfigs?.component?.validate&&t(i.type,{...i.props,style:s,advanced:m}),t(p,{...l})]})]})};export{ComponentWrapperPreview as default};
1
+ import{jsxs as e,Fragment as t,jsx as o}from"react/jsx-runtime";import{isValidElement as a}from"react";import{composeAdvanceStyle as n}from"../helpers/compose-advance-style.js";import{disableWrap as r,excludeApplyStyle as d}from"./constant.js";import p from"./RenderCustomCode.js";import{ComponentToolbarPreview as i}from"./ComponentToolbarPreview.js";let ComponentWrapperPreview=({children:c,...l})=>{if("section"===l.type)return null;let s={};if("Section"===l.tag&&l.isThemeSection&&(s["data-theme-section"]=!0),l.editorConfigs){let e=l.editorConfigs;e.placeholder?.notAppendBeforeAfter&&(s["data-placeholder-not-append-before-after"]=!0),e.toolbar?.parent&&(s["data-toolbar-parent"]=!0),e.component?.noDelete&&(s["data-component-no-delete"]=!0),e.component?.noDuplicate&&(s["data-component-no-duplicate"]=!0),e.component?.noDragDrop&&(s["data-component-no-drag-drop"]=!0),e.component?.noSetting&&(s["data-component-no-setting"]=!0),e.component?.isThirdParty&&(s["data-component-is-third-party"]=!0),e.toolbar?.hide&&(s["data-toolbar-hide"]=!0),e.slots?.children&&(s["data-slots-children"]=!0),e.toolbar?.hide||(s["data-toolbar-wrap"]=!0)}l?.editorConfigs?.toolbar?.hide||(s["data-toolbar-wrap"]=!0);let m=n(l.advanced,l.tag),u=l.advanced,h={...s,"data-uid":l.uid,"data-component-type":"component","data-component-tag":l.tag,"data-component-label":l.label};return r.includes(l.tag)&&a(c)?e(t,{children:[o(p,{uid:l.uid,advanced:u}),e(c.type,{className:u?.cssClass,...c.props,style:m,builderAttrs:h,advanced:u,children:[c.props.children,o(i,{...l})]})]}):e(t,{children:[o(p,{uid:l.uid,advanced:u}),e("div",{style:d.includes(l.tag)?{}:m,className:`${l.uid} ${l.advanced?.cssClass?l.advanced?.cssClass:""}`,...h,children:[!d.includes(l.tag)&&c,a(c)&&d.includes(l.tag)&&o(c.type,{...c.props,style:m,advanced:u}),o(i,{...l})]})]})};export{ComponentWrapperPreview as default};
@@ -1 +1 @@
1
- let disableWrap=["Col","CollectionBanner","Row","Section","Image","Text","Button","ProductButton","Cart","Tabs","TabItem","Carousel","CarouselItem","ShopPayButton","AccordionItem","Video","Header","HeroBanner","Icon","IconList","HTMLCode","IconListHoz","IconListItem","CSSCode","FormEmail","FormDropdown","SubmitButton","Dialog","TextField","FormTextarea","ProductPrice","Product","ProductImages","ProductImagesV2","Sticky"],customRenderChildren=["Accordion","AccordionItem","Row","IconList","Tabs"];export{customRenderChildren,disableWrap};
1
+ let disableWrap=["Col","CollectionBanner","Row","Section","Image","Text","Button","ProductButton","Cart","Tabs","TabItem","Carousel","CarouselItem","ShopPayButton","AccordionItem","Video","Header","HeroBanner","Icon","IconList","HTMLCode","IconListHoz","IconListItem","CSSCode","FormEmail","FormDropdown","SubmitButton","Dialog","TextField","FormTextarea","ProductPrice","Product","ProductImages","ProductImagesV2","Sticky"],customRenderChildren=["Accordion","AccordionItem","Row","IconList","Tabs"],excludeApplyStyle=["IconListV2","Accordion"];export{customRenderChildren,disableWrap,excludeApplyStyle};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/core",
3
- "version": "1.14.0-dev.373",
3
+ "version": "1.14.0-dev.377",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",