@gem-sdk/core 1.8.10 → 1.8.13

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.
@@ -8,6 +8,10 @@ const ModalContext = /*#__PURE__*/ react.createContext(null);
8
8
  const createModalProvider = (data)=>zustand.createStore((set)=>({
9
9
  activeId: data,
10
10
  setModalActive: (id)=>{
11
+ window?.parent?.postMessage?.(JSON.stringify({
12
+ type: 'active-element',
13
+ uid: id
14
+ }), '*');
11
15
  set({
12
16
  activeId: id
13
17
  });
@@ -121,6 +121,13 @@ function composeAdvanceStyle(data, tag) {
121
121
  if (attr === 'rounded') {
122
122
  Object.assign(styles, radius.getCornerCSSFromGlobal(value));
123
123
  }
124
+ if (attr === 'boxShadow') {
125
+ Object.assign(styles, shadow.getStyleShadow({
126
+ value: value,
127
+ styleAppliedFor: 'box-shadow',
128
+ isEnableShadow: data.hasBoxShadow
129
+ }));
130
+ }
124
131
  }
125
132
  });
126
133
  } else {
@@ -6,6 +6,10 @@ const ModalContext = /*#__PURE__*/ createContext(null);
6
6
  const createModalProvider = (data)=>createStore((set)=>({
7
7
  activeId: data,
8
8
  setModalActive: (id)=>{
9
+ window?.parent?.postMessage?.(JSON.stringify({
10
+ type: 'active-element',
11
+ uid: id
12
+ }), '*');
9
13
  set({
10
14
  activeId: id
11
15
  });
@@ -2,7 +2,7 @@ import { handleConvertBorderStyle, handleConvertBorderWidth, handleConvertBorder
2
2
  import { isColor } from './colors.js';
3
3
  import { layoutComponent } from './constant.js';
4
4
  import { composeRadius, getCornerCSSFromGlobal } from './radius.js';
5
- import { getStyleShadowState } from './shadow.js';
5
+ import { getStyleShadowState, getStyleShadow } from './shadow.js';
6
6
 
7
7
  const composeSpacing = ({ source , spacing , type , suffix ='' })=>{
8
8
  const { top , left , bottom , right } = spacing;
@@ -119,6 +119,13 @@ function composeAdvanceStyle(data, tag) {
119
119
  if (attr === 'rounded') {
120
120
  Object.assign(styles, getCornerCSSFromGlobal(value));
121
121
  }
122
+ if (attr === 'boxShadow') {
123
+ Object.assign(styles, getStyleShadow({
124
+ value: value,
125
+ styleAppliedFor: 'box-shadow',
126
+ isEnableShadow: data.hasBoxShadow
127
+ }));
128
+ }
122
129
  }
123
130
  });
124
131
  } else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gem-sdk/core",
3
- "version": "1.8.10",
3
+ "version": "1.8.13",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "main": "dist/cjs/index.js",