@ikas/popup-renderer 1.0.33 → 1.0.35
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/build/popup-renderer/models/modal/step/elements/button/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/divider/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/form/form-settings/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/form/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/image/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/product/detail-settings/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/product/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/social/index.js +1 -1
- package/build/popup-renderer/models/modal/step/elements/space/index.js +1 -1
- package/build/popup-renderer/models/modal/step/index.js +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as o}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as i,observable as t}from"mobx";import{PopupElementTypeEnum as r,IkasPopupRendererFontFamily as l,BaseElement as n}from"../base/index.js";import{ButtonBorderStyle as d}from"../../../background-settings/index.js";var e=function(n){function e(o){var e,a,u,b,c,g,s,f,m=this;return(m=n.call(this,o)||this).text=o.text||"Button Text",m.type=r.BUTTON,m.color=o.color||"#FFFFFF",m.buttonBgColor=o.buttonBgColor||"
|
|
1
|
+
import{__extends as o}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as i,observable as t}from"mobx";import{PopupElementTypeEnum as r,IkasPopupRendererFontFamily as l,BaseElement as n}from"../base/index.js";import{ButtonBorderStyle as d}from"../../../background-settings/index.js";var e=function(n){function e(o){var e,a,u,b,c,g,s,f,m=this;return(m=n.call(this,o)||this).text=o.text||"Button Text",m.type=r.BUTTON,m.color=o.color||"#FFFFFF",m.buttonBgColor=o.buttonBgColor||"",m.bgColor=o.bgColor||"",m.fontFamily=new l(o.fontFamily||{name:"Poppins",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"]}),m.fontSize=null!==(e=o.fontSize)&&void 0!==e?e:16,m.fontWeight=null!==(a=o.fontWeight)&&void 0!==a?a:400,m.borderRadius=null!==(u=o.borderRadius)&&void 0!==u?u:4,m.borderColor=o.borderColor||"#000000",m.borderStyle=o.borderStyle||d.SOLID,m.borderWidth=null!==(b=o.borderWidth)&&void 0!==b?b:0,m.link=o.link||null,m.verticalPadding=null!==(c=o.verticalPadding)&&void 0!==c?c:12,m.horizontalPadding=null!==(g=o.horizontalPadding)&&void 0!==g?g:12,m.outerVerticalPadding=null!==(s=o.outerVerticalPadding)&&void 0!==s?s:12,m.outerHorizontalPadding=null!==(f=o.outerHorizontalPadding)&&void 0!==f?f:12,i(m,{text:t,color:t,buttonBgColor:t,bgColor:t,fontFamily:t,fontSize:t,fontWeight:t,borderRadius:t,borderColor:t,borderStyle:t,borderWidth:t,link:t}),m}return o(e,n),e}(n);export{e as ButtonElement};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as r}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as d}from"mobx";import{PopupElementTypeEnum as i,BaseElement as e}from"../base/index.js";import{ButtonBorderStyle as t}from"../../../background-settings/index.js";var l=function(e){function l(r){void 0===r&&(r={});var l,n,b,s,a=this;return(a=e.call(this,r)||this).type=i.DIVIDER,a.bgColor=r.bgColor||"
|
|
1
|
+
import{__extends as r}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as d}from"mobx";import{PopupElementTypeEnum as i,BaseElement as e}from"../base/index.js";import{ButtonBorderStyle as t}from"../../../background-settings/index.js";var l=function(e){function l(r){void 0===r&&(r={});var l,n,b,s,a=this;return(a=e.call(this,r)||this).type=i.DIVIDER,a.bgColor=r.bgColor||"",a.borderWidth=null!==(l=r.borderWidth)&&void 0!==l?l:1,a.borderRadius=null!==(n=r.borderRadius)&&void 0!==n?n:0,a.borderColor=r.borderColor||"#E3E8EF",a.borderStyle=r.borderStyle||t.SOLID,a.verticalPadding=null!==(b=r.verticalPadding)&&void 0!==b?b:24,a.horizontalPadding=null!==(s=r.horizontalPadding)&&void 0!==s?s:24,o(a,{bgColor:d,borderWidth:d,borderRadius:d,borderColor:d,borderStyle:d}),a}return r(l,e),l}(e);export{l as DividerElement};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{makeObservable as i,observable as o}from"mobx";import{IkasPopupRendererFontFamily as t}from"../../base/index.js";var r=function(r){var n,l;void 0===r&&(r={}),this.formInputSettings=r.formInputSettings?new e(r.formInputSettings):new e,this.gapBetweenItems=null!==(n=r.gapBetweenItems)&&void 0!==n?n:12,this.fontFamily=new t(r.fontFamily||{name:"Poppins",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"]}),this.fontSize=null!==(l=r.fontSize)&&void 0!==l?l:14,i(this,{formInputSettings:o,gapBetweenItems:o,fontFamily:o,fontSize:o})},e=function(t){var r,e,n;void 0===t&&(t={}),this.bgColor=t.bgColor||"
|
|
1
|
+
import{makeObservable as i,observable as o}from"mobx";import{IkasPopupRendererFontFamily as t}from"../../base/index.js";var r=function(r){var n,l;void 0===r&&(r={}),this.formInputSettings=r.formInputSettings?new e(r.formInputSettings):new e,this.gapBetweenItems=null!==(n=r.gapBetweenItems)&&void 0!==n?n:12,this.fontFamily=new t(r.fontFamily||{name:"Poppins",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"]}),this.fontSize=null!==(l=r.fontSize)&&void 0!==l?l:14,i(this,{formInputSettings:o,gapBetweenItems:o,fontFamily:o,fontSize:o})},e=function(t){var r,e,n;void 0===t&&(t={}),this.bgColor=t.bgColor||"",this.borderWidth=null!==(r=t.borderWidth)&&void 0!==r?r:1,this.borderRadius=null!==(e=t.borderRadius)&&void 0!==e?e:4,this.borderColor=t.borderColor||"#E3E8EF",this.focusBorderColor=t.focusBorderColor||"#000000",this.height=null!==(n=t.height)&&void 0!==n?n:40,i(this,{bgColor:o,borderWidth:o,borderRadius:o,borderColor:o,focusBorderColor:o,height:o})};export{e as FormInputSettings,r as FormSettings};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as t,__assign as r}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as e,action as n}from"mobx";import{PopupElementTypeEnum as i,BaseElement as s}from"../base/index.js";import{ButtonElement as d}from"../button/index.js";import{FormSettings as m}from"./form-settings/index.js";import{CustomerNameFormItem as u}from"./customer-name/index.js";import{CustomerSurnameFormItem as E}from"./customer-surname/index.js";import{CustomerEmailFormItem as a}from"./customer-email/index.js";import{CustomerPhoneFormItem as c}from"./customer-phone/index.js";import{CustomerBirthdayFormItem as l}from"./customer-birthday/index.js";import{CustomerGenderFormItem as h}from"./customer-gender/index.js";import{CheckboxFormItem as M}from"./checkbox/index.js";import{CustomerAttributeFormItem as f}from"./customer-attribute/index.js";var R;!function(t){t.CUSTOMER_NAME="CUSTOMER_NAME",t.CUSTOMER_SURNAME="CUSTOMER_SURNAME",t.CUSTOMER_EMAIL="CUSTOMER_EMAIL",t.CUSTOMER_PHONE="CUSTOMER_PHONE",t.CUSTOMER_BIRTHDAY="CUSTOMER_BIRTHDAY",t.CUSTOMER_GENDER="CUSTOMER_GENDER",t.CHECKBOX_FORM_ITEM="CHECKBOX_FORM_ITEM",t.CUSTOMER_ATTRIBUTE="CUSTOMER_ATTRIBUTE"}(R||(R={}));var T=function(r){function s(t){void 0===t&&(t={});var s,u,E=this;return(E=r.call(this,t)||this).type=i.FORM,E.rows=t.rows?t.rows.map((function(t){return new S(t)})):[],E.formSettings=t.formSettings||new m,E.buttonSettings=t.buttonSettings||new d({outerHorizontalPadding:0,outerVerticalPadding:0}),E.bgColor=t.bgColor||"
|
|
1
|
+
import{__extends as t,__assign as r}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as e,action as n}from"mobx";import{PopupElementTypeEnum as i,BaseElement as s}from"../base/index.js";import{ButtonElement as d}from"../button/index.js";import{FormSettings as m}from"./form-settings/index.js";import{CustomerNameFormItem as u}from"./customer-name/index.js";import{CustomerSurnameFormItem as E}from"./customer-surname/index.js";import{CustomerEmailFormItem as a}from"./customer-email/index.js";import{CustomerPhoneFormItem as c}from"./customer-phone/index.js";import{CustomerBirthdayFormItem as l}from"./customer-birthday/index.js";import{CustomerGenderFormItem as h}from"./customer-gender/index.js";import{CheckboxFormItem as M}from"./checkbox/index.js";import{CustomerAttributeFormItem as f}from"./customer-attribute/index.js";var R;!function(t){t.CUSTOMER_NAME="CUSTOMER_NAME",t.CUSTOMER_SURNAME="CUSTOMER_SURNAME",t.CUSTOMER_EMAIL="CUSTOMER_EMAIL",t.CUSTOMER_PHONE="CUSTOMER_PHONE",t.CUSTOMER_BIRTHDAY="CUSTOMER_BIRTHDAY",t.CUSTOMER_GENDER="CUSTOMER_GENDER",t.CHECKBOX_FORM_ITEM="CHECKBOX_FORM_ITEM",t.CUSTOMER_ATTRIBUTE="CUSTOMER_ATTRIBUTE"}(R||(R={}));var T=function(r){function s(t){void 0===t&&(t={});var s,u,E=this;return(E=r.call(this,t)||this).type=i.FORM,E.rows=t.rows?t.rows.map((function(t){return new S(t)})):[],E.formSettings=t.formSettings||new m,E.buttonSettings=t.buttonSettings||new d({outerHorizontalPadding:0,outerVerticalPadding:0,bgColor:"#000000"}),E.bgColor=t.bgColor||"",E.verticalPadding=null!==(s=t.verticalPadding)&&void 0!==s?s:12,E.horizontalPadding=null!==(u=t.horizontalPadding)&&void 0!==u?u:12,o(E,{rows:e,formSettings:e,buttonSettings:e,bgColor:e,addNewElement:n.bound}),0===E.rows.length&&E.addNewElement(R.CUSTOMER_EMAIL),E}return t(s,r),s.prototype.addNewElement=function(t){var r=new S({order:this.rows.length,columns:[new p({type:t,order:0})]});this.rows.push(r)},s}(s),S=function(){function t(t){void 0===t&&(t={}),this.id=t.id||Date.now().toString(),this.order=t.order||0,this.columns=t.columns?t.columns.map((function(t){return new p(t)})):[],o(this,{id:e,order:e,columns:e,addNewElement:n.bound,changeColumnSort:n.bound})}return t.prototype.addNewElement=function(t){this.columns.push(new p({type:t,order:this.columns.length}))},t.prototype.changeColumnSort=function(){this.columns.forEach((function(t,r){0===r?t.order=t.order+1:1===r&&(t.order=t.order-1)})),this.columns=this.columns.sort((function(t,r){return t.order-r.order}))},t}(),p=function(){function t(t){void 0===t&&(t={}),this.id=t.id||Date.now().toString(),this.order=t.order||0,this.type=t.type||R.CUSTOMER_NAME,this.formItem=this.setFormItems(t.formItem),o(this,{id:e,order:e,type:e,formItem:e,setFormItems:n.bound})}return t.prototype.setFormItems=function(t){switch(this.type){case R.CUSTOMER_NAME:return new u(r({},t));case R.CUSTOMER_SURNAME:return new E(r({},t));case R.CUSTOMER_EMAIL:return new a(r({},t));case R.CUSTOMER_PHONE:return new c(r({},t));case R.CUSTOMER_BIRTHDAY:return new l(r({},t));case R.CUSTOMER_GENDER:return new h(r({},t));case R.CHECKBOX_FORM_ITEM:return new M(r({},t));case R.CUSTOMER_ATTRIBUTE:return new f(r({},t))}},t}(),C=function(t){void 0===t&&(t={}),this.text=t.text||"Input Label",o(this,{text:e})},O=function(t){void 0===t&&(t={}),this.validationErrorMessage=t.validationErrorMessage||"It's required to fill this field",this.hasError=t.hasError||!1,o(this,{validationErrorMessage:e,hasError:e})};export{p as FormColumn,T as FormElement,R as FormItemTypeEnum,S as FormRow,C as InputLabel,O as RequiredInput};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as i}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as n,observable as o,computed as t}from"mobx";import{PopupElementTypeEnum as e,BaseElement as a}from"../base/index.js";var d,r=1080;!function(i){i.FLOAT_LEFT="FLOAT_LEFT",i.FLOAT_RIGHT="FLOAT_RIGHT",i.DISABLE_FLOAT="DISABLE_FLOAT"}(d||(d={}));var l=function(a){function r(i){var r,l,m,c,s=this;return(s=a.call(this,i)||this).type=e.IMAGE,s.imagePosition=i.imagePosition||d.DISABLE_FLOAT,s.imageId=i.imageId||null,s.bgColor=i.bgColor||"
|
|
1
|
+
import{__extends as i}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as n,observable as o,computed as t}from"mobx";import{PopupElementTypeEnum as e,BaseElement as a}from"../base/index.js";var d,r=1080;!function(i){i.FLOAT_LEFT="FLOAT_LEFT",i.FLOAT_RIGHT="FLOAT_RIGHT",i.DISABLE_FLOAT="DISABLE_FLOAT"}(d||(d={}));var l=function(a){function r(i){var r,l,m,c,s=this;return(s=a.call(this,i)||this).type=e.IMAGE,s.imagePosition=i.imagePosition||d.DISABLE_FLOAT,s.imageId=i.imageId||null,s.bgColor=i.bgColor||"",s.cdnURL=null,s.merchantId=null,s.link=i.link||null,s.maxWidth=null!==(r=i.maxWidth)&&void 0!==r?r:100,s.verticalPadding=null!==(l=i.verticalPadding)&&void 0!==l?l:24,s.horizontalPadding=null!==(m=i.horizontalPadding)&&void 0!==m?m:24,s.borderRadius=null!==(c=i.borderRadius)&&void 0!==c?c:0,n(s,{imagePosition:o,imageId:o,bgColor:o,cdnURL:o,merchantId:o,link:o,maxWidth:o,borderRadius:o,src:t}),s}return i(r,a),Object.defineProperty(r.prototype,"src",{get:function(){if(this.imageId)return this.imageId.includes("/")?"".concat(this.cdnURL,"images/").concat(this.merchantId,"/").concat(this.imageId,"/image_").concat(1080,".jpeg"):void 0},enumerable:!1,configurable:!0}),r}(a);export{r as IMAGE_SIZE,l as ImageElement,d as ImagePositionEnum};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{makeObservable as i,observable as t}from"mobx";import{TextElement as o}from"../../text/index.js";import{IkasPopupRendererFontFamily as n}from"../../base/index.js";var a,e=function(n){void 0===n&&(n={}),this.image=n.image?new r(n.image):new r({}),this.name=n.name?new o(n.name):new o({horizontalPadding:0,verticalPadding:6}),this.discountRatio=n.discountRatio?new o(n.discountRatio):new o({horizontalPadding:0,verticalPadding:8}),this.originalPrice=n.originalPrice?new o(n.originalPrice):new o({horizontalPadding:0,verticalPadding:2,fontSize:14,color:"#697586"}),this.finalPrice=n.finalPrice?new o(n.finalPrice):new o({horizontalPadding:0,verticalPadding:2}),this.button=n.button?new c(n.button):new c({}),i(this,{image:t,name:t,discountRatio:t,originalPrice:t,finalPrice:t,button:t})},r=function(o){var n,a;this.bgColor=o.bgColor||"
|
|
1
|
+
import{makeObservable as i,observable as t}from"mobx";import{TextElement as o}from"../../text/index.js";import{IkasPopupRendererFontFamily as n}from"../../base/index.js";var a,e=function(n){void 0===n&&(n={}),this.image=n.image?new r(n.image):new r({}),this.name=n.name?new o(n.name):new o({horizontalPadding:0,verticalPadding:6}),this.discountRatio=n.discountRatio?new o(n.discountRatio):new o({horizontalPadding:0,verticalPadding:8}),this.originalPrice=n.originalPrice?new o(n.originalPrice):new o({horizontalPadding:0,verticalPadding:2,fontSize:14,color:"#697586"}),this.finalPrice=n.finalPrice?new o(n.finalPrice):new o({horizontalPadding:0,verticalPadding:2}),this.button=n.button?new c(n.button):new c({}),i(this,{image:t,name:t,discountRatio:t,originalPrice:t,finalPrice:t,button:t})},r=function(o){var n,a;this.bgColor=o.bgColor||"",this.maxWidth=null!==(n=o.maxWidth)&&void 0!==n?n:100,this.borderRadius=null!==(a=o.borderRadius)&&void 0!==a?a:0,i(this,{bgColor:t,maxWidth:t,borderRadius:t})},l=function(o){var a;void 0===o&&(o={}),this.color=o.color||"#000000",this.bgColor=o.bgColor||"",this.fontFamily=new n(o.fontFamily||{name:"Poppins",variants:["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"]}),this.fontSize=null!==(a=o.fontSize)&&void 0!==a?a:24,i(this,{color:t,bgColor:t,fontFamily:t,fontSize:t})};!function(i){i.ADD_TO_CART="ADD_TO_CART",i.NAVIGATE_TO_PRODUCT_DETAIL="NAVIGATE_TO_PRODUCT_DETAIL"}(a||(a={}));var c=function(o){void 0===o&&(o={}),this.text=o.text||"Button Text",this.action=o.action||a.ADD_TO_CART,i(this,{text:t,action:t})};export{a as ProductActionTypeEnum,c as ProductButtonSettings,e as ProductDetailSettings,l as ProductDiscountRatioSettings,r as ProductImageSettings};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as t}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as
|
|
1
|
+
import{__extends as t}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as i}from"mobx";import{PopupElementTypeEnum as n,BaseElement as e}from"../base/index.js";import{ProductDetailSettings as r}from"./detail-settings/index.js";import{ButtonElement as d}from"../button/index.js";var u,a,E;!function(t){t.ASC_AVERAGE_RATING="ASC_AVERAGE_RATING",t.DESC_AVERAGE_RATING="DESC_AVERAGE_RATING",t.ASC_CREATED_AT="ASC_CREATED_AT",t.DESC_CREATED_AT="DESC_CREATED_AT",t.ASC_DISCOUNT_RATIO="ASC_DISCOUNT_RATIO",t.DESC_DISCOUNT_RATIO="DESC_DISCOUNT_RATIO",t.ASC_NAME="ASC_NAME",t.DESC_NAME="DESC_NAME",t.ASC_PRICE="ASC_PRICE",t.DESC_PRICE="DESC_PRICE",t.ASC_REVIEW_COUNT="ASC_REVIEW_COUNT",t.DESC_REVIEW_COUNT="DESC_REVIEW_COUNT",t.ASC_SALE_COUNT="ASC_SALE_COUNT",t.DESC_SALE_COUNT="DESC_SALE_COUNT"}(u||(u={})),function(t){t.ALL="ALL",t.SPECIFIC="SPECIFIC",t.CATEGORY="CATEGORY",t.LAST_VIEWED="LAST_VIEWED"}(a||(a={})),function(t){t.ONE_COLUMN="ONE_COLUMN",t.TWO_COLUMN="TWO_COLUMN",t.THREE_COLUMN="THREE_COLUMN"}(E||(E={}));var s=10,l=function(e){function s(t){void 0===t&&(t={});var s,l,C,_,c,A,S,T,I=this;return(I=e.call(this,t)||this).type=n.PRODUCT_LIST,I.listType=t.listType||a.ALL,I.sortType=t.sortType||u.ASC_CREATED_AT,I.maxProductsToShow=null!==(s=t.maxProductsToShow)&&void 0!==s?s:10,I.categoryId=null!==(l=t.categoryId)&&void 0!==l?l:null,I.variantPairs=null!==(C=t.variantPairs)&&void 0!==C?C:null,I.layout=null!==(_=t.layout)&&void 0!==_?_:E.TWO_COLUMN,I.productDetailSettings=t.productDetailSettings?new r(t.productDetailSettings):new r,I.buttonSettings=t.buttonSettings?new d(t.buttonSettings):new d({outerHorizontalPadding:0,bgColor:"#000000"}),I.productBgColor=t.productBgColor||"",I.gapBetweenProductElements=null!==(c=t.gapBetweenProductElements)&&void 0!==c?c:12,I.gapBetweenProducts=null!==(A=t.gapBetweenProducts)&&void 0!==A?A:12,I.verticalPadding=null!==(S=t.verticalPadding)&&void 0!==S?S:12,I.horizontalPadding=null!==(T=t.horizontalPadding)&&void 0!==T?T:12,o(I,{type:i,listType:i,sortType:i,maxProductsToShow:i,categoryId:i,variantPairs:i,layout:i,productDetailSettings:i,buttonSettings:i,productBgColor:i,gapBetweenProductElements:i,gapBetweenProducts:i}),I}return t(s,e),s}(e),C=function(t){var n;this.productId=t.productId,this.variantId=t.variantId,this.order=null!==(n=t.order)&&void 0!==n?n:0,this.productListElementId=t.productListElementId,o(this,{productId:i,variantId:i,order:i,productListElementId:i})},_=function(){function t(t){void 0===t&&(t={}),this.productId=t.productId||Date.now().toString(),this.variantId=t.variantId||Date.now().toString(),this.name=t.name||"",this.price=t.price||"",this.discountPrice=t.discountPrice||null,this.discountRatio=t.discountRatio||null,this.imageURL=t.imageURL?"".concat(t.imageURL,"/image_").concat(1080,".jpeg"):null,this.url=t.url||null,o(this,{productId:i,variantId:i,name:i,price:i,discountPrice:i,discountRatio:i,imageURL:i,url:i})}return Object.defineProperty(t.prototype,"$discountRatio",{get:function(){return this.discountRatio?"%"+this.discountRatio:null},enumerable:!1,configurable:!0}),t}();export{s as MAX_PRODUCT_COUNT,_ as PopupProduct,C as PopupVariantPair,l as ProductListElement,E as ProductListLayoutEnum,u as ProductListSortTypeEnum,a as ProductListTypeEnum};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as o}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as i,observable as n,action as t,computed as r}from"mobx";import{PopupElementTypeEnum as c,BaseElement as e}from"../base/index.js";var a,l=function(r){function e(o){void 0===o&&(o={});var e,l,s,u,g,p=this;return(p=r.call(this,o)||this).type=c.SOCIAL_MEDIA,p.logoColor=o.logoColor||"#000000",p.borderRadius=null!==(e=o.borderRadius)&&void 0!==e?e:0,p.bgColor=o.bgColor||"
|
|
1
|
+
import{__extends as o}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as i,observable as n,action as t,computed as r}from"mobx";import{PopupElementTypeEnum as c,BaseElement as e}from"../base/index.js";var a,l=function(r){function e(o){void 0===o&&(o={});var e,l,s,u,g,p=this;return(p=r.call(this,o)||this).type=c.SOCIAL_MEDIA,p.logoColor=o.logoColor||"#000000",p.borderRadius=null!==(e=o.borderRadius)&&void 0!==e?e:0,p.bgColor=o.bgColor||"",p.gapBetweenLogos=null!==(l=o.gapBetweenLogos)&&void 0!==l?l:8,p.verticalPadding=null!==(s=o.verticalPadding)&&void 0!==s?s:24,p.horizontalPadding=null!==(u=o.horizontalPadding)&&void 0!==u?u:24,p.socialMediaLinks=(null===(g=o.socialMediaLinks)||void 0===g?void 0:g.length)?o.socialMediaLinks.map((function(o){return new d(o)})):[new d({type:a.FACEBOOK,order:0,icon:"https://cdn.myikas.dev/social/facebook/1080/".concat(p.borderRadius,"/").concat(p.bgColor,"/").concat(p.logoColor)}),new d({type:a.TWITTER,order:1,icon:"https://cdn.myikas.dev/social/x/1080/".concat(p.borderRadius,"/").concat(p.bgColor,"/").concat(p.logoColor)}),new d({type:a.INSTAGRAM,order:2,icon:"https://cdn.myikas.dev/social/instagram/1080/".concat(p.borderRadius,"/").concat(p.bgColor,"/").concat(p.logoColor)}),new d({type:a.YOUTUBE,order:3,icon:"https://cdn.myikas.dev/social/youtube/1080/".concat(p.borderRadius,"/").concat(p.bgColor,"/").concat(p.logoColor)}),new d({type:a.TIKTOK,order:4,icon:"https://cdn.myikas.dev/social/tiktok/1080/".concat(p.borderRadius,"/").concat(p.bgColor,"/").concat(p.logoColor)}),new d({type:a.LINKEDIN,order:4,icon:"https://cdn.myikas.dev/social/linkedin/1080/".concat(p.borderRadius,"/").concat(p.bgColor,"/").concat(p.logoColor)})],i(p,{logoColor:n,borderRadius:n,bgColor:n,socialMediaLinks:n,gapBetweenLogos:n,updateIconLinks:t.bound}),p}return o(e,r),e.prototype.updateIconLinks=function(){var o=this;this.socialMediaLinks.forEach((function(i){i.icon="https://cdn.myikas.dev/social/".concat(i.type.toLowerCase(),"/1080/").concat(o.borderRadius,"/").concat(o.bgColor,"/").concat(o.logoColor)}))},e}(e),d=function(){function o(o){var t;void 0===o&&(o={}),this.id=o.id||Date.now().toString(),this.icon=o.icon||null,this.link=o.link||null,this.order=null!==(t=o.order)&&void 0!==t?t:0,this.type=o.type||a.FACEBOOK,i(this,{icon:n,link:n,order:n,type:n,iconUrlWithoutHash:r})}return Object.defineProperty(o.prototype,"iconUrlWithoutHash",{get:function(){var o;return null===(o=this.icon)||void 0===o?void 0:o.replace(/#/g,"")},enumerable:!1,configurable:!0}),o}();!function(o){o.FACEBOOK="FACEBOOK",o.TWITTER="TWITTER",o.INSTAGRAM="INSTAGRAM",o.YOUTUBE="YOUTUBE",o.TIKTOK="TIKTOK",o.LINKEDIN="LINKEDIN"}(a||(a={}));export{l as SocialMediaElement,d as SocialMediaLink,a as SocialMediaTypeEnum};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{__extends as i}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as t}from"mobx";import{PopupElementTypeEnum as r,BaseElement as l}from"../base/index.js";var n=function(l){function n(i){var n,d,e,a=this;return(a=l.call(this,i)||this).type=r.SPACE,a.bgColor=i.bgColor||"
|
|
1
|
+
import{__extends as i}from'./../../../../../../ext/tslib/tslib.es6.mjs.js';import{makeObservable as o,observable as t}from"mobx";import{PopupElementTypeEnum as r,BaseElement as l}from"../base/index.js";var n=function(l){function n(i){var n,d,e,a=this;return(a=l.call(this,i)||this).type=r.SPACE,a.bgColor=i.bgColor||"",a.height=null!==(n=i.height)&&void 0!==n?n:24,a.horizontalPadding=null!==(d=i.horizontalPadding)&&void 0!==d?d:0,a.verticalPadding=null!==(e=i.verticalPadding)&&void 0!==e?e:0,o(a,{bgColor:t,height:t}),a}return i(n,l),n}(l);export{n as SpaceElement};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{makeObservable as e,observable as t,action as s}from"mobx";import{TextElement as n}from"./elements/text/index.js";import{FormElement as r}from"./elements/form/index.js";import{ImageElement as i}from"./elements/image/index.js";import{ProductListElement as m}from"./elements/product/index.js";import{ButtonElement as o}from"./elements/button/index.js";import{SocialMediaElement as a}from"./elements/social/index.js";import{DividerElement as h}from"./elements/divider/index.js";import{SpaceElement as u}from"./elements/space/index.js";import{PopupElementTypeEnum as p}from"./elements/base/index.js";import{ImageColumnElement as l}from"./elements/image-column/index.js";var d=function(){function d(r){var i=this;this.id=r.id||Date.now().toString(),this.stepNumber=r.stepNumber||0,this.name=r.name||"",this.isThankYouStep=r.isThankYouStep||!1,this.isTeaser=r.isTeaser||!1,this.elements=r.elements&&r.elements.length?r.elements.map((function(e){return i.setContent(e)})):[],this.isTeaser&&(this.id=this.id+"-teaser"),this.isTeaser&&!this.elements.length&&this.elements.push(new n({order:0})),e(this,{stepNumber:t,name:t,isThankYouStep:t,isTeaser:t,elements:t,setContent:s.bound,addNewElement:s.bound})}return d.prototype.setContent=function(e){switch(e.type){case p.TEXT:return new n(e||{});case p.FORM:return new r(e||{});case p.IMAGE:return new i(e||{});case p.IMAGE_COLUMN:return new l(e||{});case p.PRODUCT_LIST:return new m(e||{});case p.BUTTON:return new o(e||{});case p.SOCIAL_MEDIA:return new a(e||{});case p.DIVIDER:return new h(e||{});case p.SPACE:return new u(e||{})}},d.prototype.addNewElement=function(e){var t=this.elements.length;switch(e){case p.TEXT:this.elements.push(new n({order:t}));break;case p.FORM:this.elements.push(new r({order:t}));break;case p.IMAGE:this.elements.push(new i({order:t}));break;case p.IMAGE_COLUMN:this.elements.push(new l({order:t}));break;case p.PRODUCT_LIST:this.elements.push(new m({order:t}));break;case p.BUTTON:this.elements.push(new o({order:t}));break;case p.SOCIAL_MEDIA:this.elements.push(new a({order:t}));break;case p.DIVIDER:this.elements.push(new h({order:t}));break;case p.SPACE:this.elements.push(new u({order:t}))}},d}();export{d as PopupStep};
|
|
1
|
+
import{makeObservable as e,observable as t,action as s}from"mobx";import{TextElement as n}from"./elements/text/index.js";import{FormElement as r}from"./elements/form/index.js";import{ImageElement as i}from"./elements/image/index.js";import{ProductListElement as m}from"./elements/product/index.js";import{ButtonElement as o}from"./elements/button/index.js";import{SocialMediaElement as a}from"./elements/social/index.js";import{DividerElement as h}from"./elements/divider/index.js";import{SpaceElement as u}from"./elements/space/index.js";import{PopupElementTypeEnum as p}from"./elements/base/index.js";import{ImageColumnElement as l}from"./elements/image-column/index.js";var d=function(){function d(r){var i=this;this.id=r.id||Date.now().toString(),this.stepNumber=r.stepNumber||0,this.name=r.name||"",this.isThankYouStep=r.isThankYouStep||!1,this.isTeaser=r.isTeaser||!1,this.elements=r.elements&&r.elements.length?r.elements.map((function(e){return i.setContent(e)})):[],this.isTeaser&&(this.id=this.id+"-teaser"),this.isTeaser&&!this.elements.length&&this.elements.push(new n({order:0})),e(this,{stepNumber:t,name:t,isThankYouStep:t,isTeaser:t,elements:t,setContent:s.bound,addNewElement:s.bound})}return d.prototype.setContent=function(e){switch(e.type){case p.TEXT:return new n(e||{});case p.FORM:return new r(e||{});case p.IMAGE:return new i(e||{});case p.IMAGE_COLUMN:return new l(e||{});case p.PRODUCT_LIST:return new m(e||{});case p.BUTTON:return new o(e||{});case p.SOCIAL_MEDIA:return new a(e||{});case p.DIVIDER:return new h(e||{});case p.SPACE:return new u(e||{})}},d.prototype.addNewElement=function(e){var t=this.elements.length;switch(e){case p.TEXT:this.elements.push(new n({order:t}));break;case p.FORM:this.elements.push(new r({order:t}));break;case p.IMAGE:this.elements.push(new i({order:t}));break;case p.IMAGE_COLUMN:this.elements.push(new l({order:t}));break;case p.PRODUCT_LIST:this.elements.push(new m({order:t}));break;case p.BUTTON:this.elements.push(new o({order:t,bgColor:"#000000"}));break;case p.SOCIAL_MEDIA:this.elements.push(new a({order:t}));break;case p.DIVIDER:this.elements.push(new h({order:t}));break;case p.SPACE:this.elements.push(new u({order:t}))}},d}();export{d as PopupStep};
|