pds-dev-kit-web-test 2.5.29 → 2.5.31

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.
@@ -79,13 +79,6 @@ type ActionHandlerPayload = {
79
79
  '@CUSTOMSECTION/ESCAPE_ONE_FROM_GROUP': {
80
80
  id: string;
81
81
  };
82
- '@CUSTOMSECTION/ON_DROP_FROM_OUTSIDE': {
83
- layout: Layout;
84
- layoutItem: LayoutItem;
85
- };
86
- '@CUSTOMSECTION/ON_DROP_DRAG_OVER': {
87
- e: any;
88
- };
89
82
  };
90
83
  type ActionMap<M extends {
91
84
  [index: string]: any;
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import type { ISection } from '../../types';
3
- import type { Layout } from 'publ-echo-test/dist/lib/GridLayoutEditor/types';
3
+ import type { Layout } from 'publ-echo/dist/lib/GridLayoutEditor/types';
4
4
  export type LayoutsType = {
5
5
  sm: Layout;
6
6
  lg: Layout;
@@ -53,7 +53,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
53
53
  exports.S_gleStyles = void 0;
54
54
  var jsx_runtime_1 = require("react/jsx-runtime");
55
55
  var publ_echo_test_1 = require("publ-echo-test");
56
- var ReactGridLayout_1 = __importDefault(require("publ-echo-test/dist/lib/GridLayoutEditor/ReactGridLayout"));
56
+ var ReactGridLayout_1 = __importDefault(require("publ-echo/dist/lib/GridLayoutEditor/ReactGridLayout"));
57
57
  var react_1 = __importStar(require("react"));
58
58
  var ErrorBoundary_1 = require("../../../DynamicLayout/components/Section/ErrorBoundary");
59
59
  var dynamicLayoutContext_1 = require("../../../DynamicLayout/dynamicLayoutContext");
@@ -445,48 +445,18 @@ var CustomSection = (0, react_1.forwardRef)(function CustomSection(props, ref) {
445
445
  }
446
446
  return false;
447
447
  })();
448
- var _j = (0, react_1.useState)(), droppingItem = _j[0], setDroppingItem = _j[1];
449
- var onDrop = function (layout, layoutItem, _event) {
450
- // const data = _event.dataTransfer.getData('text/plain');
451
- // setDroppingItem(data);
452
- // alert(`Dropped element props:\n${JSON.stringify(layoutItem, ['x', 'y', 'w', 'h'], 2)}`);
453
- if (!isEditMode) {
454
- return;
455
- }
456
- sectionActionHandler &&
457
- sectionActionHandler({
458
- type: '@CUSTOMSECTION/ON_DROP_FROM_OUTSIDE',
459
- payload: {
460
- layout: layout,
461
- layoutItem: layoutItem
462
- }
463
- });
464
- };
465
- var onDropDragOver = function (e) {
466
- if (!sectionActionHandler) {
467
- return null;
468
- }
469
- // return sectionActionHandler({
470
- // type: '@CUSTOMSECTION/ON_DROP_FROM_OUTSIDE',
471
- // payload: {
472
- // e
473
- // }
474
- // });
475
- return null;
476
- };
477
448
  return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsxs)(exports.S_gleStyles, { 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 }, { children: (0, jsx_runtime_1.jsx)(components_1.CustomSection, __assign({}, props, { isMobile: isMobile, overrideStyles: {
478
449
  minHeight: customSectionStyles.minHeight,
479
450
  paddingTop: padding.top,
480
451
  paddingBottom: padding.bottom,
481
452
  paddingRight: padding.right,
482
453
  paddingLeft: padding.left
483
- } }, { children: (0, jsx_runtime_1.jsx)(Responsive, __assign({ innerRef: innerRef, allowOverlap: true, isDroppable: true, layouts: layouts, resizeHandles: ['nw', 'e', 'n', 'ne', 's', 'se', 'sw', 'w'], breakpoints: breakpoints, breakpoint: breakpoint, cols: { lg: 24, sm: 8 }, rowHeight: rowHeight, margin: [10, 10], style: {
454
+ } }, { children: (0, jsx_runtime_1.jsx)(Responsive, __assign({ innerRef: innerRef, allowOverlap: true, layouts: layouts, resizeHandles: ['nw', 'e', 'n', 'ne', 's', 'se', 'sw', 'w'], breakpoints: breakpoints, breakpoint: breakpoint, cols: { lg: 24, sm: 8 }, rowHeight: rowHeight, margin: [10, 10], style: {
484
455
  width: customSectionStyles.width,
485
456
  maxWidth: customSectionStyles.maxWidth,
486
457
  minWidth: isMobile ? GLE_MIN_WIDTH_MOBILE_PX : GLE_MIN_WIDTH_DESKTOP_PX,
487
458
  fontSize: "".concat(baseFontSize, "px")
488
- }, onLayoutChange: onLayoutChange, onDragStart: onDragStart, onDragStop: onDragStop, onDrop: onDrop, onResizeStop: onResizeStop, onDropDragOver: onDropDragOver,
489
- // droppingItem={droppingItem}
459
+ }, onLayoutChange: onLayoutChange, onDragStart: onDragStart, onDragStop: onDragStop, onResizeStop: onResizeStop,
490
460
  // onFitToContent={onAutoFitContent}
491
461
  onWidthChange: onWidthChange, minNbRow: rows, isDraggable: isEditMode, isResizable: isEditMode }, { children: keepSimilarOrderToPreventRerender(layouts[layoutByDevice]).map(function (each, index) {
492
462
  var _a;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pds-dev-kit-web-test",
3
- "version": "2.5.29",
3
+ "version": "2.5.31",
4
4
  "license": "MIT",
5
5
  "private": false,
6
6
  "main": "dist/index.js",
@@ -23,7 +23,7 @@
23
23
  "lottie-react": "^2.3.1",
24
24
  "nuka-carousel": "^4.8.4",
25
25
  "publ-echo": "^0.0.45",
26
- "publ-echo-test": "^0.0.38",
26
+ "publ-echo-test": "^0.0.39",
27
27
  "react-hook-form": "^7.28.1",
28
28
  "react-i18next": "^11.12.0",
29
29
  "react-router-dom": "^5.2.0",