@ikas/storefront 6.1.0-beta.16 → 6.1.0-beta.17

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
- import{__extends as e,__assign as r}from'./../../ext/tslib/tslib.es6.js';import*as o from"react";import{makeObservable as t,computed as n}from"mobx";import{Observer as p}from"mobx-react-lite";import{IkasThemeJsonComponentPropType as i}from"@ikas/storefront-models";import{IkasStorefrontConfig as a}from"@ikas/storefront-config";import{IkasPageDataInit as s}from"../../page-data-init/index.js";import{IkasBaseStore as u}from"../../store/base.js";import"../../store/customer/index.js";import"../../store/cart/index.js";var l=function(l){function m(e){var r=l.call(this,e)||this;return r.state={hasError:!1},t(r,{hasNullValue:n,Component:n}),r}return e(m,l),m.getDerivedStateFromError=function(e){return console.error(e),{hasError:!0}},Object.defineProperty(m.prototype,"hasNullValue",{get:function(){var e=this.props.pageComponentPropValue,r=e.propValues;return e.component.props.some((function(o){if(o.isRequired){var t=(r||{})[o.name],n=null==e?void 0:e.component.props.find((function(e){return e.id===o.requiredPropId}));if(n){var p=(r||{})[n.name];if(n.type===i.BOOLEAN&&!p||n.type===i.CUSTOM&&p!==o.requiredEnumOptionValue)return!1}return null===t||null==t}}))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"Component",{get:function(){var e=this.props.pageComponentPropValue,r=a.getCurrentPageComponents(),o=e.pageComponent;return r?r[o.componentId]:null},enumerable:!1,configurable:!0}),m.prototype.render=function(){var e=this;return o.createElement(p,null,(function(){var t=e.props,n=t.index,p=t.pageComponentPropValue,i=t.settings,a=e.Component,l=p.pageComponent,m=p.propValues;return a?e.state.hasError?null:o.createElement("div",{id:n+""},e.hasNullValue?null:o.createElement(a,r({key:l.id},m,{settings:i,store:u.getInstance(),pageSpecificData:s.pageSpecificData}))):(console.error("COMPONENT NOT FOUND!"),null)}))},m}(o.Component);export{l as ThemeComponent};
1
+ import{__extends as e,__assign as r}from'./../../ext/tslib/tslib.es6.js';import*as o from"react";import{makeObservable as t,computed as n}from"mobx";import{Observer as p}from"mobx-react-lite";import{IkasThemeJsonComponentPropType as i}from"@ikas/storefront-models";import{IkasStorefrontConfig as a}from"@ikas/storefront-config";import{IkasPageDataInit as s}from"../../page-data-init/index.js";import{IkasBaseStore as u}from"../../store/base.js";import"../../store/customer/index.js";import"../../store/cart/index.js";var l=function(l){function m(e){var r=l.call(this,e)||this;return r.state={hasError:!1},t(r,{hasNullValue:n,Component:n}),r}return e(m,l),m.getDerivedStateFromError=function(e){return console.error(e),{hasError:!0}},Object.defineProperty(m.prototype,"hasNullValue",{get:function(){var e=this.props.pageComponentPropValue,r=e.propValues;return e.component.props.some((function(o){if(o.isRequired){var t=(r||{})[o.name],n=null==e?void 0:e.component.props.find((function(e){return e.id===o.requiredPropId}));if(n){var p=(r||{})[n.name];if(n.type===i.BOOLEAN&&!p||n.type===i.CUSTOM&&p!==o.requiredEnumOptionValue)return!1}return null===t||null==t}}))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"Component",{get:function(){var e=this.props.pageComponentPropValue,r=a.getCurrentPageComponents(),o=e.pageComponent;return r?r[o.componentId]:null},enumerable:!1,configurable:!0}),m.prototype.render=function(){var e=this;return o.createElement(p,null,(function(){var t=e.props,n=t.index,p=t.pageComponentPropValue,i=t.settings,a=e.Component,l=p.pageComponent,m=p.propValues;return a?e.state.hasError?null:o.createElement("div",{id:n+""},e.hasNullValue?null:o.createElement(a,r({key:l.id},m,{settings:i,store:u.getInstance(),pageSpecificData:s.pageSpecificData}))):(console.error("COMPONENT NOT FOUND!",l.componentId),null)}))},m}(o.Component);export{l as ThemeComponent};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ikas/storefront",
3
- "version": "6.1.0-beta.16",
3
+ "version": "6.1.0-beta.17",
4
4
  "description": "Storefront functionality for ikas storefront themes.",
5
5
  "author": "ikas",
6
6
  "license": "ISC",
@@ -21,11 +21,11 @@
21
21
  "swiper": "11.0.6"
22
22
  },
23
23
  "devDependencies": {
24
- "@ikas/storefront-api": "^6.1.0-beta.16",
25
- "@ikas/storefront-config": "^6.1.0-beta.16",
26
- "@ikas/storefront-model-functions": "^6.1.0-beta.16",
27
- "@ikas/storefront-models": "^6.1.0-beta.16",
28
- "@ikas/storefront-providers": "^6.1.0-beta.16",
24
+ "@ikas/storefront-api": "^6.1.0-beta.17",
25
+ "@ikas/storefront-config": "^6.1.0-beta.17",
26
+ "@ikas/storefront-model-functions": "^6.1.0-beta.17",
27
+ "@ikas/storefront-models": "^6.1.0-beta.17",
28
+ "@ikas/storefront-providers": "^6.1.0-beta.17",
29
29
  "@ikas/localized-address": "1.0.0-beta.6",
30
30
  "@adyen/adyen-web": "^5.57.0",
31
31
  "@rollup/plugin-commonjs": "^22.0.0",
@@ -60,11 +60,11 @@
60
60
  },
61
61
  "peerDependencies": {
62
62
  "@ikas/localized-address": "1.0.0-beta.6",
63
- "@ikas/storefront-api": "^6.1.0-beta.16",
64
- "@ikas/storefront-config": "^6.1.0-beta.16",
65
- "@ikas/storefront-model-functions": "^6.1.0-beta.16",
66
- "@ikas/storefront-models": "^6.1.0-beta.16",
67
- "@ikas/storefront-providers": "^6.1.0-beta.16",
63
+ "@ikas/storefront-api": "^6.1.0-beta.17",
64
+ "@ikas/storefront-config": "^6.1.0-beta.17",
65
+ "@ikas/storefront-model-functions": "^6.1.0-beta.17",
66
+ "@ikas/storefront-models": "^6.1.0-beta.17",
67
+ "@ikas/storefront-providers": "^6.1.0-beta.17",
68
68
  "mobx": "^6.1.3",
69
69
  "mobx-react-lite": "^3.1.5",
70
70
  "next": "12.2.0",