pds-dev-kit-web-test 2.5.297 → 2.5.299

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.
@@ -1003,6 +1003,8 @@ var CustomSection = (0, react_1.forwardRef)(function CustomSection(props, ref) {
1003
1003
  innerRef.current.setAttribute('data-section-id', props.id.toString());
1004
1004
  }
1005
1005
  }, []);
1006
+ var editableCBIDs = (0, group_1.findDirectChildrenCbIds)(newblock, editingGroupBlock);
1007
+ console.log('editableCBIDs', editableCBIDs);
1006
1008
  return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsxs)(gleStyles_1.S_gleStyles, __assign({ isBulkMode: shortcutKeyMode === 'BULK_SELECT' }, { children: [showSectionHiddenCover && (0, jsx_runtime_1.jsx)(S_HiddenCover_1.S_HiddenCover, {}), (0, jsx_runtime_1.jsx)(S_SectionWrapper, __assign({ ref: gleRef, "x-dlayout-section-type": "NO_NAME", onClick: onClickSection, onContextMenu: function (e) {
1007
1009
  e.stopPropagation();
1008
1010
  e.preventDefault();
@@ -1030,23 +1032,28 @@ var CustomSection = (0, react_1.forwardRef)(function CustomSection(props, ref) {
1030
1032
  }
1031
1033
  return ((0, jsx_runtime_1.jsx)("div", __assign({ className: (0, clsx_1.clsx)({
1032
1034
  'react-grid-item-selected': selectedBlockId === (0, group_1.formatCbIdToBlockId)(matchedCB.id)
1033
- }), onClick: function (e) {
1034
- e.stopPropagation();
1035
- console.dir(e.target);
1036
- if (isInBulk) {
1037
- clickOneCBInBulk(matchedCB.id);
1038
- return;
1039
- }
1040
- onClickCB(matchedCB.id);
1041
- }, onContextMenu: function (e) {
1042
- e.stopPropagation();
1043
- e.preventDefault();
1044
- onContextMenuCB(matchedCB.id, e);
1045
- } }, { children: (0, jsx_runtime_1.jsx)("div", __assign({ className: (0, clsx_1.clsx)({
1035
+ }) }, { children: (0, jsx_runtime_1.jsx)("div", __assign({ className: (0, clsx_1.clsx)({
1046
1036
  'grid-item-child': true
1047
1037
  }), style: {
1048
1038
  width: '100%',
1049
1039
  height: '100%'
1040
+ }, onClick: function (e) {
1041
+ e.stopPropagation();
1042
+ if (editingGroupBlock !== 'ROOT') {
1043
+ if (!editableCBIDs.includes(matchedCB.id)) {
1044
+ e.preventDefault();
1045
+ return;
1046
+ }
1047
+ }
1048
+ if (isInBulk) {
1049
+ clickOneCBInBulk(matchedCB.id);
1050
+ return;
1051
+ }
1052
+ onClickCB(matchedCB.id);
1053
+ }, onContextMenu: function (e) {
1054
+ e.stopPropagation();
1055
+ e.preventDefault();
1056
+ onContextMenuCB(matchedCB.id, e);
1050
1057
  } }, { children: (0, jsx_runtime_1.jsxs)(ErrorBoundary_1.ErrorBoundary, { children: [(0, jsx_runtime_1.jsx)(ComponentBlockMatcher_1.default, { cbProps: matchedCB, device: device, rowHeight: rowHeight, index: index }), each.x < 0 && (0, jsx_runtime_1.jsx)("div", __assign({ className: "error-start-x" }, { children: "X" })), each.y < 0 && (0, jsx_runtime_1.jsx)("div", __assign({ className: "error-start-y" }, { children: "Y" })), (device === 'MOBILE' ? each.x + each.w > 8 : each.x + each.w > 24) && ((0, jsx_runtime_1.jsx)("div", __assign({ className: "error-cols" }, { children: "C" }))), each.h < 0 && (0, jsx_runtime_1.jsx)("div", __assign({ className: "error-rows" }, { children: "R" })), (each.x < 0 ||
1051
1058
  each.y < 0 ||
1052
1059
  each.x + each.w > (device === 'MOBILE' ? 8 : 24) ||
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pds-dev-kit-web-test",
3
- "version": "2.5.297",
3
+ "version": "2.5.299",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "main": "dist/index.js",