publ-echo-test 0.0.207 → 0.0.209

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.
@@ -14,9 +14,11 @@ var OutsideClickHandler = function (_a) {
14
14
  var handleClickOutside = function (e) {
15
15
  var target = e.target;
16
16
  console.log(target);
17
+ console.log('closest to group?', target.closest('.group'));
17
18
  if (target.closest('.editable-grid-item') ||
18
19
  target.closest('.group') ||
19
- target.closest('.placeholder')) {
20
+ target.closest('.placeholder') ||
21
+ target.closest('.react-group-block')) {
20
22
  return;
21
23
  }
22
24
  if (wrapperRef.current &&
@@ -31,7 +33,7 @@ var OutsideClickHandler = function (_a) {
31
33
  }
32
34
  return function () {
33
35
  if (selectedSection) {
34
- selectedSection.addEventListener('dblclick', handleClickOutside);
36
+ selectedSection.removeEventListener('dblclick', handleClickOutside);
35
37
  }
36
38
  };
37
39
  }, [onOutsideClick]);
@@ -43,7 +43,7 @@ import OutsideClickHandler from '../GridItem/OutsideClickHandler';
43
43
  var layoutClassName = 'react-grid-layout';
44
44
  var ReactGridLayout = function (_a) {
45
45
  var children = _a.children, props = __rest(_a, ["children"]);
46
- var _b = props.autoSize, autoSize = _b === void 0 ? true : _b, _c = props.cols, cols = _c === void 0 ? 12 : _c, _d = props.className, className = _d === void 0 ? '' : _d, _e = props.style, style = _e === void 0 ? {} : _e, _f = props.draggableHandle, draggableHandle = _f === void 0 ? '' : _f, _g = props.draggableCancel, draggableCancel = _g === void 0 ? '' : _g, _h = props.containerPadding, containerPadding = _h === void 0 ? undefined : _h, _j = props.rowHeight, rowHeight = _j === void 0 ? 150 : _j, _k = props.maxRows, maxRows = _k === void 0 ? Infinity : _k, _l = props.margin, margin = _l === void 0 ? [10, 10] : _l, _m = props.isBounded, isBounded = _m === void 0 ? false : _m, _o = props.isDraggable, isDraggable = _o === void 0 ? true : _o, _p = props.isResizable, isResizable = _p === void 0 ? true : _p, _q = props.allowOverlap, allowOverlap = _q === void 0 ? false : _q, _r = props.isDroppable, isDroppable = _r === void 0 ? false : _r, _s = props.useCSSTransforms, useCSSTransforms = _s === void 0 ? true : _s, _t = props.transformScale, transformScale = _t === void 0 ? 1 : _t, _u = props.compactType, compactType = _u === void 0 ? 'vertical' : _u, _v = props.preventCollision, preventCollision = _v === void 0 ? false : _v, _w = props.droppingItem, droppingItem = _w === void 0 ? {
46
+ var sectionId = props.sectionId, _b = props.autoSize, autoSize = _b === void 0 ? true : _b, _c = props.cols, cols = _c === void 0 ? 12 : _c, _d = props.className, className = _d === void 0 ? '' : _d, _e = props.style, style = _e === void 0 ? {} : _e, _f = props.draggableHandle, draggableHandle = _f === void 0 ? '' : _f, _g = props.draggableCancel, draggableCancel = _g === void 0 ? '' : _g, _h = props.containerPadding, containerPadding = _h === void 0 ? undefined : _h, _j = props.rowHeight, rowHeight = _j === void 0 ? 150 : _j, _k = props.maxRows, maxRows = _k === void 0 ? Infinity : _k, _l = props.margin, margin = _l === void 0 ? [10, 10] : _l, _m = props.isBounded, isBounded = _m === void 0 ? false : _m, _o = props.isDraggable, isDraggable = _o === void 0 ? true : _o, _p = props.isResizable, isResizable = _p === void 0 ? true : _p, _q = props.allowOverlap, allowOverlap = _q === void 0 ? false : _q, _r = props.isDroppable, isDroppable = _r === void 0 ? false : _r, _s = props.useCSSTransforms, useCSSTransforms = _s === void 0 ? true : _s, _t = props.transformScale, transformScale = _t === void 0 ? 1 : _t, _u = props.compactType, compactType = _u === void 0 ? 'vertical' : _u, _v = props.preventCollision, preventCollision = _v === void 0 ? false : _v, _w = props.droppingItem, droppingItem = _w === void 0 ? {
47
47
  i: '__dropping-elem__',
48
48
  h: 1,
49
49
  w: 1,
@@ -739,7 +739,7 @@ var ReactGridLayout = function (_a) {
739
739
  var currentGroupBlocks = blockStructure
740
740
  ? findGroupBlocks(blockStructure, editingGroupBlock)
741
741
  : [];
742
- return (_jsxs("div", { ref: innerRef, className: mergedClassName, style: mergedStyle, onDrop: isDroppable ? onDropHandler : noop, onDragLeave: isDroppable ? onDragLeaveHandler : noop, onDragEnter: isDroppable ? onDragEnterHandler : noop, onDragOver: isDroppable ? onDragOverHandler : noop, "data-grid-row-height": rowHeight, "data-grid-cols": cols, children: [currentGroupBlocks.map(function (each) { return processGroup(each); }), React.Children.map(children, function (child) { return processGridItem(child); }), placeholder(), activeDrag && _jsx("div", { className: 'grid-guide-line-center' }), activeDrag && (_jsx("div", { className: 'grid-placeholder', style: {
742
+ return (_jsxs("div", { ref: innerRef, className: mergedClassName, style: mergedStyle, onDrop: isDroppable ? onDropHandler : noop, onDragLeave: isDroppable ? onDragLeaveHandler : noop, onDragEnter: isDroppable ? onDragEnterHandler : noop, onDragOver: isDroppable ? onDragOverHandler : noop, "data-grid-row-height": rowHeight, "data-grid-cols": cols, "data-section-id": sectionId, children: [currentGroupBlocks.map(function (each) { return processGroup(each); }), React.Children.map(children, function (child) { return processGridItem(child); }), placeholder(), activeDrag && _jsx("div", { className: 'grid-guide-line-center' }), activeDrag && (_jsx("div", { className: 'grid-placeholder', style: {
743
743
  marginTop: margin[1] + 'px',
744
744
  marginBottom: margin[1] + 'px',
745
745
  marginLeft: margin[0] + 'px',
@@ -1,8 +1,8 @@
1
- import { DragEvent, ReactElement, RefObject } from "react";
2
- import { ResizeHandleAxis, ResizeHandleType } from "../Resizable/types";
3
- import { ResizeEventType } from "../GridItem/types";
4
- import { Block } from "./group";
5
- export type CompactType = "vertical" | "horizontal";
1
+ import { DragEvent, ReactElement, RefObject } from 'react';
2
+ import { ResizeHandleAxis, ResizeHandleType } from '../Resizable/types';
3
+ import { ResizeEventType } from '../GridItem/types';
4
+ import { Block } from './group';
5
+ export type CompactType = 'vertical' | 'horizontal';
6
6
  export type LayoutItem = {
7
7
  w: number;
8
8
  h: number;
@@ -35,6 +35,7 @@ export type UpdatedItem = {
35
35
  y: number;
36
36
  };
37
37
  export type ReactGridLayoutProps = {
38
+ sectionId: string;
38
39
  children: ReactElement<any> | ReactElement[];
39
40
  className?: string;
40
41
  style?: Object;
@@ -142,7 +143,7 @@ export type ResponsiveGridLayoutStateType = {
142
143
  layout: Layout;
143
144
  layouts?: ResponsiveLayout<string>;
144
145
  };
145
- type CoreType = Omit<ReactGridLayoutProps, "cols" | "layout" | "margin" | "containerPadding" | "transformScale" | "onLayoutChange" | "isHiddenVisibility">;
146
+ type CoreType = Omit<ReactGridLayoutProps, 'cols' | 'layout' | 'margin' | 'containerPadding' | 'transformScale' | 'onLayoutChange' | 'isHiddenVisibility'>;
146
147
  export type ResponsiveGridLayoutProps = {
147
148
  breakpoint?: Breakpoint;
148
149
  breakpoints?: Breakpoints<Breakpoint>;
@@ -156,7 +157,7 @@ export type ResponsiveGridLayoutProps = {
156
157
  zoom?: number;
157
158
  } & CoreType;
158
159
  export type Breakpoint = string;
159
- export type DefaultBreakpoints = "lg" | "md" | "sm" | "xs" | "xxs";
160
+ export type DefaultBreakpoints = 'lg' | 'md' | 'sm' | 'xs' | 'xxs';
160
161
  export type ResponsiveLayout<T extends Breakpoint> = Record<T, Layout>;
161
162
  export type Breakpoints<T extends Breakpoint> = Record<T, number>;
162
163
  export type OnLayoutChangeCallback = (properties: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "publ-echo-test",
3
- "version": "0.0.207",
3
+ "version": "0.0.209",
4
4
  "private": false,
5
5
  "main": "dist/lib/index.js",
6
6
  "types": "dist/lib/index.d.js",