pds-dev-kit-web-test 2.7.173 → 2.7.174
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/src/sub/DynamicLayout/CompositionRenderer/FlexGridItem.d.ts +3 -1
- package/dist/src/sub/DynamicLayout/CompositionRenderer/FlexGridItem.js +3 -3
- package/dist/src/sub/DynamicLayout/GridAutoRowEditor/GridAutoRowEditor.js +1 -1
- package/dist/src/sub/DynamicLayout/utils/groupUtils.js +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import type { ComponentBlock } from '../sections/CustomSection/types';
|
|
3
3
|
import type { CB_PLACEMENT_PROP_SPECS, Device } from '../sections/CustomSection/util/types';
|
|
4
|
+
import type { Block } from 'publ-echo-test/dist/lib/GridLayoutEditor/group';
|
|
4
5
|
type Props = {
|
|
5
6
|
cb: ComponentBlock;
|
|
6
7
|
index: number;
|
|
@@ -10,7 +11,8 @@ type Props = {
|
|
|
10
11
|
showPinned?: boolean;
|
|
11
12
|
style?: React.CSSProperties;
|
|
12
13
|
isParentGroupPinned: boolean;
|
|
14
|
+
block: Block;
|
|
13
15
|
};
|
|
14
|
-
declare function FlexGridItem({ cb, index, device, rowHeight, zIndex, showPinned, style, isParentGroupPinned }: Props): JSX.Element;
|
|
16
|
+
declare function FlexGridItem({ cb, index, device, rowHeight, zIndex, showPinned, block, style, isParentGroupPinned }: Props): JSX.Element;
|
|
15
17
|
export declare function getGridAreaFromCB(props: CB_PLACEMENT_PROP_SPECS, device: Device): string;
|
|
16
18
|
export default FlexGridItem;
|
|
@@ -20,16 +20,16 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
20
20
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
21
|
exports.getGridAreaFromCB = void 0;
|
|
22
22
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
23
|
-
|
|
23
|
+
require("react");
|
|
24
24
|
var styled_components_1 = __importDefault(require("styled-components"));
|
|
25
25
|
var ComponentBlockMatcherWithCCB_1 = __importDefault(require("../sections/CustomSection/components/ComponentBlock/ComponentBlockMatcherWithCCB"));
|
|
26
26
|
var gap = 10;
|
|
27
27
|
function FlexGridItem(_a) {
|
|
28
|
-
var cb = _a.cb, index = _a.index, device = _a.device, rowHeight = _a.rowHeight, zIndex = _a.zIndex, showPinned = _a.showPinned, style = _a.style, isParentGroupPinned = _a.isParentGroupPinned;
|
|
28
|
+
var cb = _a.cb, index = _a.index, device = _a.device, rowHeight = _a.rowHeight, zIndex = _a.zIndex, showPinned = _a.showPinned, block = _a.block, style = _a.style, isParentGroupPinned = _a.isParentGroupPinned;
|
|
29
29
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
30
30
|
var defaultHeight = getMaxHeight(cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT, device, rowHeight);
|
|
31
31
|
var gridArea = getGridAreaFromCB(cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT, device);
|
|
32
|
-
var
|
|
32
|
+
var isCBPinned = device === 'DESKTOP' ? block.isPinnedDesktop : block.isPinnedMobile;
|
|
33
33
|
var isPinned = isParentGroupPinned || isCBPinned;
|
|
34
34
|
return ((0, jsx_runtime_1.jsx)(GridItem, __assign({ style: __assign({ zIndex: zIndex, gridArea: gridArea, position: 'relative', maxHeight: isPinned ? defaultHeight : 'none' }, style) }, { children: (0, jsx_runtime_1.jsx)(ComponentBlockMatcherWithCCB_1.default, { rowHeight: rowHeight, cbProps: cb, device: device, index: index }) })));
|
|
35
35
|
}
|
|
@@ -313,7 +313,7 @@ function GroupBlockRender(_a) {
|
|
|
313
313
|
right: 0,
|
|
314
314
|
bottom: 0,
|
|
315
315
|
boxShadow: '0 0 0 3px #e602ff'
|
|
316
|
-
} }), children === null || children === void 0 ? void 0 : children.map(function (cb, index) { return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(FlexGridItem_1.default, { cb: cb, index: index, device: "DESKTOP", rowHeight: 50, zIndex: 0, style: { pointerEvents: 'none', opacity: isEditing ? 1 : 0.3 }, showPinned: isEditing, isParentGroupPinned: isPinned }) }, cb.id)); })] })));
|
|
316
|
+
} }), children === null || children === void 0 ? void 0 : children.map(function (cb, index) { return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(FlexGridItem_1.default, { cb: cb, index: index, device: "DESKTOP", rowHeight: 50, zIndex: 0, style: { pointerEvents: 'none', opacity: isEditing ? 1 : 0.3 }, showPinned: isEditing, block: block, isParentGroupPinned: isPinned }) }, cb.id)); })] })));
|
|
317
317
|
}
|
|
318
318
|
var S_Pinned = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n pointer-events: auto;\n position: absolute;\n right: 0;\n top: 0;\n z-index: 9999999;\n"], ["\n pointer-events: auto;\n position: absolute;\n right: 0;\n top: 0;\n z-index: 9999999;\n"])));
|
|
319
319
|
function getGridAreaFromGroup(position) {
|
|
@@ -137,7 +137,7 @@ function RenderPedigreeRecursively(_a) {
|
|
|
137
137
|
// data-og-grid-area={originalGridAreaString}
|
|
138
138
|
// data-rel-grid-area={gridAreaObjToString(relativeGridArea)}
|
|
139
139
|
// >
|
|
140
|
-
(0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(FlexGridItem_1.default, { cb: cb, index: cbIndex, device: device, rowHeight: rowHeight, zIndex: device === 'DESKTOP'
|
|
140
|
+
(0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(FlexGridItem_1.default, { cb: cb, index: cbIndex, device: device, rowHeight: rowHeight, block: block, zIndex: device === 'DESKTOP'
|
|
141
141
|
? block.zOrderDesktopInternal
|
|
142
142
|
: block.zOrderMobileInternal, style: {
|
|
143
143
|
gridArea: gridAreaObjToString(relativeGridArea),
|