react-grid-layout 2.2.0 → 2.2.1

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.
Files changed (59) hide show
  1. package/README.md +14 -55
  2. package/dist/{ResponsiveGridLayout-BkHF9YHa.d.mts → ResponsiveGridLayout-DqK__izz.d.mts} +1 -1
  3. package/dist/{ResponsiveGridLayout-CLn16-X3.d.ts → ResponsiveGridLayout-MbDNfJ8M.d.ts} +1 -1
  4. package/dist/{calculate-DsVTldEE.d.ts → calculate-9RxGrt-U.d.ts} +1 -1
  5. package/dist/{calculate-DwbL1D06.d.mts → calculate-FbCWy8x1.d.mts} +1 -1
  6. package/dist/{chunk-2TEFHZC4.js → chunk-2DDROKB2.js} +10 -153
  7. package/dist/chunk-2DDROKB2.js.map +1 -0
  8. package/dist/{chunk-NQUM7RXX.js → chunk-3CEWSUXL.js} +52 -46
  9. package/dist/chunk-3CEWSUXL.js.map +1 -0
  10. package/dist/{chunk-OWK47QTG.mjs → chunk-AZ6K3JIJ.mjs} +22 -16
  11. package/dist/chunk-AZ6K3JIJ.mjs.map +1 -0
  12. package/dist/chunk-PBQSHIID.js +4 -0
  13. package/dist/{chunk-7ELO5FRW.js.map → chunk-PBQSHIID.js.map} +1 -1
  14. package/dist/{chunk-43GDBEG4.js → chunk-QGXQSZII.js} +34 -39
  15. package/dist/chunk-QGXQSZII.js.map +1 -0
  16. package/dist/{chunk-OH26KG7Y.mjs → chunk-XYPIYYYQ.mjs} +12 -153
  17. package/dist/chunk-XYPIYYYQ.mjs.map +1 -0
  18. package/dist/{chunk-MUNIXYTV.mjs → chunk-YFVX5RDK.mjs} +27 -32
  19. package/dist/chunk-YFVX5RDK.mjs.map +1 -0
  20. package/dist/chunk-ZWN22PS2.mjs +3 -0
  21. package/dist/{chunk-526JND3R.mjs.map → chunk-ZWN22PS2.mjs.map} +1 -1
  22. package/dist/core.d.mts +6 -32
  23. package/dist/core.d.ts +6 -32
  24. package/dist/core.js +41 -49
  25. package/dist/core.mjs +2 -2
  26. package/dist/extras.d.mts +2 -2
  27. package/dist/extras.d.ts +2 -2
  28. package/dist/extras.js +0 -72
  29. package/dist/extras.js.map +1 -1
  30. package/dist/extras.mjs +0 -72
  31. package/dist/extras.mjs.map +1 -1
  32. package/dist/index.d.mts +5 -5
  33. package/dist/index.d.ts +5 -5
  34. package/dist/index.js +24 -24
  35. package/dist/index.mjs +4 -4
  36. package/dist/legacy.d.mts +2 -2
  37. package/dist/legacy.d.ts +2 -2
  38. package/dist/legacy.js +13 -13
  39. package/dist/legacy.mjs +2 -2
  40. package/dist/{position-CXNzFxI0.d.mts → position-CetgOHhD.d.mts} +1 -1
  41. package/dist/{position-Dk0FRWA9.d.ts → position-DhZqWO1-.d.ts} +1 -1
  42. package/dist/react.d.mts +11 -14
  43. package/dist/react.d.ts +11 -14
  44. package/dist/react.js +18 -18
  45. package/dist/react.mjs +4 -4
  46. package/dist/{responsive-BB5d98xz.d.mts → responsive-DLRtE8v8.d.ts} +3 -3
  47. package/dist/{responsive-BXI-GCXG.d.ts → responsive-T0N0GmBB.d.mts} +3 -3
  48. package/dist/{types-CokovIMH.d.mts → types-BiXsdXr7.d.mts} +5 -16
  49. package/dist/{types-CokovIMH.d.ts → types-BiXsdXr7.d.ts} +5 -16
  50. package/index-dev.js +2 -3
  51. package/package.json +1 -1
  52. package/dist/chunk-2TEFHZC4.js.map +0 -1
  53. package/dist/chunk-43GDBEG4.js.map +0 -1
  54. package/dist/chunk-526JND3R.mjs +0 -3
  55. package/dist/chunk-7ELO5FRW.js +0 -4
  56. package/dist/chunk-MUNIXYTV.mjs.map +0 -1
  57. package/dist/chunk-NQUM7RXX.js.map +0 -1
  58. package/dist/chunk-OH26KG7Y.mjs.map +0 -1
  59. package/dist/chunk-OWK47QTG.mjs.map +0 -1
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  export { DEFAULT_BREAKPOINTS, DEFAULT_COLS, DefaultBreakpoints, DragState, DropState, GridItem, GridItemCallback, GridItemProps, ResizeHandle, ResizeState, UseContainerWidthOptions, UseContainerWidthResult, UseGridLayoutOptions, UseGridLayoutResult, UseResponsiveLayoutOptions, UseResponsiveLayoutResult, useContainerWidth, useGridLayout, useResponsiveLayout } from './react.js';
2
- export { G as GridLayout, a as GridLayoutProps, G as ReactGridLayout, a as ReactGridLayoutProps, R as Responsive, R as ResponsiveGridLayout, b as ResponsiveGridLayoutProps, b as ResponsiveProps, G as default } from './ResponsiveGridLayout-CLn16-X3.js';
3
- export { B as Breakpoint, b as Breakpoints, C as CompactType, c as Compactor, D as DroppingPosition, E as EventCallback, G as GridDragEvent, e as GridResizeEvent, L as Layout, a as LayoutItem, P as Position, d as ResizeHandleAxis, R as ResponsiveLayouts } from './types-CokovIMH.js';
4
- export { c as collides, h as findOrGenerateResponsiveLayout, a as getAllCollisions, e as getBreakpointFromWidth, f as getColsFromBreakpoint, g as getFirstCollision, s as sortLayoutItems, d as sortLayoutItemsByColRow, b as sortLayoutItemsByRowCol } from './responsive-BXI-GCXG.js';
5
- export { b as bottom, c as cloneLayout, a as cloneLayoutItem, d as getCompactor, g as getLayoutItem, h as horizontalCompactor, m as moveElement, n as noCompactor, f as setTopLeft, s as setTransform, v as validateLayout, e as verticalCompactor } from './position-Dk0FRWA9.js';
6
- export { c as calcGridItemPosition, b as calcWH, a as calcXY } from './calculate-DsVTldEE.js';
2
+ export { G as GridLayout, a as GridLayoutProps, G as ReactGridLayout, a as ReactGridLayoutProps, R as Responsive, R as ResponsiveGridLayout, b as ResponsiveGridLayoutProps, b as ResponsiveProps, G as default } from './ResponsiveGridLayout-MbDNfJ8M.js';
3
+ export { B as Breakpoint, b as Breakpoints, C as CompactType, c as Compactor, D as DroppingPosition, E as EventCallback, G as GridDragEvent, e as GridResizeEvent, L as Layout, a as LayoutItem, P as Position, d as ResizeHandleAxis, R as ResponsiveLayouts } from './types-BiXsdXr7.js';
4
+ export { c as collides, h as findOrGenerateResponsiveLayout, a as getAllCollisions, e as getBreakpointFromWidth, f as getColsFromBreakpoint, g as getFirstCollision, s as sortLayoutItems, d as sortLayoutItemsByColRow, b as sortLayoutItemsByRowCol } from './responsive-DLRtE8v8.js';
5
+ export { b as bottom, c as cloneLayout, a as cloneLayoutItem, d as getCompactor, g as getLayoutItem, h as horizontalCompactor, m as moveElement, n as noCompactor, f as setTopLeft, s as setTransform, v as validateLayout, e as verticalCompactor } from './position-DhZqWO1-.js';
6
+ export { c as calcGridItemPosition, b as calcWH, a as calcXY } from './calculate-9RxGrt-U.js';
7
7
  import 'react';
package/dist/index.js CHANGED
@@ -2,93 +2,93 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var chunk43GDBEG4_js = require('./chunk-43GDBEG4.js');
6
- require('./chunk-7ELO5FRW.js');
7
- var chunkNQUM7RXX_js = require('./chunk-NQUM7RXX.js');
8
- var chunk2TEFHZC4_js = require('./chunk-2TEFHZC4.js');
5
+ var chunkQGXQSZII_js = require('./chunk-QGXQSZII.js');
6
+ require('./chunk-PBQSHIID.js');
7
+ var chunk3CEWSUXL_js = require('./chunk-3CEWSUXL.js');
8
+ var chunk2DDROKB2_js = require('./chunk-2DDROKB2.js');
9
9
  var chunkBJFPTW5Q_js = require('./chunk-BJFPTW5Q.js');
10
10
 
11
11
 
12
12
 
13
13
  Object.defineProperty(exports, "DEFAULT_BREAKPOINTS", {
14
14
  enumerable: true,
15
- get: function () { return chunk43GDBEG4_js.DEFAULT_BREAKPOINTS; }
15
+ get: function () { return chunkQGXQSZII_js.DEFAULT_BREAKPOINTS; }
16
16
  });
17
17
  Object.defineProperty(exports, "DEFAULT_COLS", {
18
18
  enumerable: true,
19
- get: function () { return chunk43GDBEG4_js.DEFAULT_COLS; }
19
+ get: function () { return chunkQGXQSZII_js.DEFAULT_COLS; }
20
20
  });
21
21
  Object.defineProperty(exports, "useContainerWidth", {
22
22
  enumerable: true,
23
- get: function () { return chunk43GDBEG4_js.useContainerWidth; }
23
+ get: function () { return chunkQGXQSZII_js.useContainerWidth; }
24
24
  });
25
25
  Object.defineProperty(exports, "useGridLayout", {
26
26
  enumerable: true,
27
- get: function () { return chunk43GDBEG4_js.useGridLayout; }
27
+ get: function () { return chunkQGXQSZII_js.useGridLayout; }
28
28
  });
29
29
  Object.defineProperty(exports, "useResponsiveLayout", {
30
30
  enumerable: true,
31
- get: function () { return chunk43GDBEG4_js.useResponsiveLayout; }
31
+ get: function () { return chunkQGXQSZII_js.useResponsiveLayout; }
32
32
  });
33
33
  Object.defineProperty(exports, "GridItem", {
34
34
  enumerable: true,
35
- get: function () { return chunkNQUM7RXX_js.GridItem; }
35
+ get: function () { return chunk3CEWSUXL_js.GridItem; }
36
36
  });
37
37
  Object.defineProperty(exports, "GridLayout", {
38
38
  enumerable: true,
39
- get: function () { return chunkNQUM7RXX_js.GridLayout; }
39
+ get: function () { return chunk3CEWSUXL_js.GridLayout; }
40
40
  });
41
41
  Object.defineProperty(exports, "ReactGridLayout", {
42
42
  enumerable: true,
43
- get: function () { return chunkNQUM7RXX_js.GridLayout; }
43
+ get: function () { return chunk3CEWSUXL_js.GridLayout; }
44
44
  });
45
45
  Object.defineProperty(exports, "Responsive", {
46
46
  enumerable: true,
47
- get: function () { return chunkNQUM7RXX_js.ResponsiveGridLayout; }
47
+ get: function () { return chunk3CEWSUXL_js.ResponsiveGridLayout; }
48
48
  });
49
49
  Object.defineProperty(exports, "ResponsiveGridLayout", {
50
50
  enumerable: true,
51
- get: function () { return chunkNQUM7RXX_js.ResponsiveGridLayout; }
51
+ get: function () { return chunk3CEWSUXL_js.ResponsiveGridLayout; }
52
52
  });
53
53
  Object.defineProperty(exports, "default", {
54
54
  enumerable: true,
55
- get: function () { return chunkNQUM7RXX_js.GridLayout; }
55
+ get: function () { return chunk3CEWSUXL_js.GridLayout; }
56
56
  });
57
57
  Object.defineProperty(exports, "findOrGenerateResponsiveLayout", {
58
58
  enumerable: true,
59
- get: function () { return chunk2TEFHZC4_js.findOrGenerateResponsiveLayout; }
59
+ get: function () { return chunk2DDROKB2_js.findOrGenerateResponsiveLayout; }
60
60
  });
61
61
  Object.defineProperty(exports, "getBreakpointFromWidth", {
62
62
  enumerable: true,
63
- get: function () { return chunk2TEFHZC4_js.getBreakpointFromWidth; }
63
+ get: function () { return chunk2DDROKB2_js.getBreakpointFromWidth; }
64
64
  });
65
65
  Object.defineProperty(exports, "getColsFromBreakpoint", {
66
66
  enumerable: true,
67
- get: function () { return chunk2TEFHZC4_js.getColsFromBreakpoint; }
67
+ get: function () { return chunk2DDROKB2_js.getColsFromBreakpoint; }
68
68
  });
69
69
  Object.defineProperty(exports, "getCompactor", {
70
70
  enumerable: true,
71
- get: function () { return chunk2TEFHZC4_js.getCompactor; }
71
+ get: function () { return chunk2DDROKB2_js.getCompactor; }
72
72
  });
73
73
  Object.defineProperty(exports, "horizontalCompactor", {
74
74
  enumerable: true,
75
- get: function () { return chunk2TEFHZC4_js.horizontalCompactor; }
75
+ get: function () { return chunk2DDROKB2_js.horizontalCompactor; }
76
76
  });
77
77
  Object.defineProperty(exports, "noCompactor", {
78
78
  enumerable: true,
79
- get: function () { return chunk2TEFHZC4_js.noCompactor; }
79
+ get: function () { return chunk2DDROKB2_js.noCompactor; }
80
80
  });
81
81
  Object.defineProperty(exports, "setTopLeft", {
82
82
  enumerable: true,
83
- get: function () { return chunk2TEFHZC4_js.setTopLeft; }
83
+ get: function () { return chunk2DDROKB2_js.setTopLeft; }
84
84
  });
85
85
  Object.defineProperty(exports, "setTransform", {
86
86
  enumerable: true,
87
- get: function () { return chunk2TEFHZC4_js.setTransform; }
87
+ get: function () { return chunk2DDROKB2_js.setTransform; }
88
88
  });
89
89
  Object.defineProperty(exports, "verticalCompactor", {
90
90
  enumerable: true,
91
- get: function () { return chunk2TEFHZC4_js.verticalCompactor; }
91
+ get: function () { return chunk2DDROKB2_js.verticalCompactor; }
92
92
  });
93
93
  Object.defineProperty(exports, "bottom", {
94
94
  enumerable: true,
package/dist/index.mjs CHANGED
@@ -1,7 +1,7 @@
1
- export { DEFAULT_BREAKPOINTS, DEFAULT_COLS, useContainerWidth, useGridLayout, useResponsiveLayout } from './chunk-MUNIXYTV.mjs';
2
- import './chunk-526JND3R.mjs';
3
- export { GridItem, GridLayout, GridLayout as ReactGridLayout, ResponsiveGridLayout as Responsive, ResponsiveGridLayout, GridLayout as default } from './chunk-OWK47QTG.mjs';
4
- export { findOrGenerateResponsiveLayout, getBreakpointFromWidth, getColsFromBreakpoint, getCompactor, horizontalCompactor, noCompactor, setTopLeft, setTransform, verticalCompactor } from './chunk-OH26KG7Y.mjs';
1
+ export { DEFAULT_BREAKPOINTS, DEFAULT_COLS, useContainerWidth, useGridLayout, useResponsiveLayout } from './chunk-YFVX5RDK.mjs';
2
+ import './chunk-ZWN22PS2.mjs';
3
+ export { GridItem, GridLayout, GridLayout as ReactGridLayout, ResponsiveGridLayout as Responsive, ResponsiveGridLayout, GridLayout as default } from './chunk-AZ6K3JIJ.mjs';
4
+ export { findOrGenerateResponsiveLayout, getBreakpointFromWidth, getColsFromBreakpoint, getCompactor, horizontalCompactor, noCompactor, setTopLeft, setTransform, verticalCompactor } from './chunk-XYPIYYYQ.mjs';
5
5
  export { bottom, calcGridItemPosition, calcWH, calcXY, cloneLayout, cloneLayoutItem, collides, getAllCollisions, getFirstCollision, getLayoutItem, moveElement, sortLayoutItems, sortLayoutItemsByColRow, sortLayoutItemsByRowCol, validateLayout } from './chunk-AWM66AWF.mjs';
6
6
  //# sourceMappingURL=index.mjs.map
7
7
  //# sourceMappingURL=index.mjs.map
package/dist/legacy.d.mts CHANGED
@@ -1,7 +1,7 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React__default, { ComponentType } from 'react';
3
- import { a as GridLayoutProps, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-BkHF9YHa.mjs';
4
- import { L as Layout, a as LayoutItem, C as CompactType, d as ResizeHandleAxis, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-CokovIMH.mjs';
3
+ import { a as GridLayoutProps, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-DqK__izz.mjs';
4
+ import { L as Layout, a as LayoutItem, C as CompactType, d as ResizeHandleAxis, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-BiXsdXr7.mjs';
5
5
 
6
6
  /**
7
7
  * Legacy props interface for backwards compatibility with v1 API.
package/dist/legacy.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
  import React__default, { ComponentType } from 'react';
3
- import { a as GridLayoutProps, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-CLn16-X3.js';
4
- import { L as Layout, a as LayoutItem, C as CompactType, d as ResizeHandleAxis, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-CokovIMH.js';
3
+ import { a as GridLayoutProps, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-MbDNfJ8M.js';
4
+ import { L as Layout, a as LayoutItem, C as CompactType, d as ResizeHandleAxis, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-BiXsdXr7.js';
5
5
 
6
6
  /**
7
7
  * Legacy props interface for backwards compatibility with v1 API.
package/dist/legacy.js CHANGED
@@ -2,8 +2,8 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var chunkNQUM7RXX_js = require('./chunk-NQUM7RXX.js');
6
- var chunk2TEFHZC4_js = require('./chunk-2TEFHZC4.js');
5
+ var chunk3CEWSUXL_js = require('./chunk-3CEWSUXL.js');
6
+ var chunk2DDROKB2_js = require('./chunk-2DDROKB2.js');
7
7
  require('./chunk-BJFPTW5Q.js');
8
8
  var react = require('react');
9
9
  var jsxRuntime = require('react/jsx-runtime');
@@ -97,16 +97,16 @@ function ReactGridLayout(props) {
97
97
  };
98
98
  let positionStrategy;
99
99
  if (!useCSSTransforms) {
100
- positionStrategy = chunk2TEFHZC4_js.absoluteStrategy;
100
+ positionStrategy = chunk2DDROKB2_js.absoluteStrategy;
101
101
  } else if (transformScale !== 1) {
102
- positionStrategy = chunk2TEFHZC4_js.createScaledStrategy(transformScale);
102
+ positionStrategy = chunk2DDROKB2_js.createScaledStrategy(transformScale);
103
103
  } else {
104
- positionStrategy = chunk2TEFHZC4_js.transformStrategy;
104
+ positionStrategy = chunk2DDROKB2_js.transformStrategy;
105
105
  }
106
- const compactor = chunk2TEFHZC4_js.getCompactor(compactType, allowOverlap, preventCollision);
107
- const constraints = isBounded ? [...chunk2TEFHZC4_js.defaultConstraints, chunk2TEFHZC4_js.containerBounds] : chunk2TEFHZC4_js.defaultConstraints;
106
+ const compactor = chunk2DDROKB2_js.getCompactor(compactType, allowOverlap, preventCollision);
107
+ const constraints = isBounded ? [...chunk2DDROKB2_js.defaultConstraints, chunk2DDROKB2_js.containerBounds] : chunk2DDROKB2_js.defaultConstraints;
108
108
  return /* @__PURE__ */ jsxRuntime.jsx(
109
- chunkNQUM7RXX_js.GridLayout,
109
+ chunk3CEWSUXL_js.GridLayout,
110
110
  {
111
111
  width,
112
112
  gridConfig,
@@ -216,15 +216,15 @@ function ResponsiveReactGridLayout(props) {
216
216
  };
217
217
  let positionStrategy;
218
218
  if (!useCSSTransforms) {
219
- positionStrategy = chunk2TEFHZC4_js.absoluteStrategy;
219
+ positionStrategy = chunk2DDROKB2_js.absoluteStrategy;
220
220
  } else if (transformScale !== 1) {
221
- positionStrategy = chunk2TEFHZC4_js.createScaledStrategy(transformScale);
221
+ positionStrategy = chunk2DDROKB2_js.createScaledStrategy(transformScale);
222
222
  } else {
223
- positionStrategy = chunk2TEFHZC4_js.transformStrategy;
223
+ positionStrategy = chunk2DDROKB2_js.transformStrategy;
224
224
  }
225
- const compactor = chunk2TEFHZC4_js.getCompactor(compactType, allowOverlap, preventCollision);
225
+ const compactor = chunk2DDROKB2_js.getCompactor(compactType, allowOverlap, preventCollision);
226
226
  return /* @__PURE__ */ jsxRuntime.jsx(
227
- chunkNQUM7RXX_js.ResponsiveGridLayout,
227
+ chunk3CEWSUXL_js.ResponsiveGridLayout,
228
228
  {
229
229
  width,
230
230
  breakpoint,
package/dist/legacy.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { GridLayout, ResponsiveGridLayout } from './chunk-OWK47QTG.mjs';
2
- import { createScaledStrategy, getCompactor, defaultConstraints, containerBounds, absoluteStrategy, transformStrategy } from './chunk-OH26KG7Y.mjs';
1
+ import { GridLayout, ResponsiveGridLayout } from './chunk-AZ6K3JIJ.mjs';
2
+ import { createScaledStrategy, getCompactor, defaultConstraints, containerBounds, absoluteStrategy, transformStrategy } from './chunk-XYPIYYYQ.mjs';
3
3
  import './chunk-AWM66AWF.mjs';
4
4
  import { useState, useRef, useEffect } from 'react';
5
5
  import { jsx } from 'react/jsx-runtime';
@@ -1,4 +1,4 @@
1
- import { L as Layout, a as LayoutItem, C as CompactType, M as Mutable, c as Compactor, P as Position, d as ResizeHandleAxis, k as PositionStrategy } from './types-CokovIMH.mjs';
1
+ import { L as Layout, a as LayoutItem, C as CompactType, M as Mutable, c as Compactor, P as Position, d as ResizeHandleAxis, k as PositionStrategy } from './types-BiXsdXr7.mjs';
2
2
 
3
3
  /**
4
4
  * Core layout manipulation utilities.
@@ -1,4 +1,4 @@
1
- import { L as Layout, a as LayoutItem, C as CompactType, M as Mutable, c as Compactor, P as Position, d as ResizeHandleAxis, k as PositionStrategy } from './types-CokovIMH.js';
1
+ import { L as Layout, a as LayoutItem, C as CompactType, M as Mutable, c as Compactor, P as Position, d as ResizeHandleAxis, k as PositionStrategy } from './types-BiXsdXr7.js';
2
2
 
3
3
  /**
4
4
  * Core layout manipulation utilities.
package/dist/react.d.mts CHANGED
@@ -1,9 +1,9 @@
1
1
  import React__default, { ReactElement, CSSProperties, RefObject } from 'react';
2
- import { k as PositionStrategy, D as DroppingPosition, d as ResizeHandleAxis, f as LayoutConstraint, a as LayoutItem, L as Layout, G as GridDragEvent, e as GridResizeEvent, C as CompactType, c as Compactor, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-CokovIMH.mjs';
3
- export { P as Position } from './types-CokovIMH.mjs';
4
- export { E as EventCallback, G as GridLayout, a as GridLayoutProps, R as ResponsiveGridLayout, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-BkHF9YHa.mjs';
5
- export { b as bottom, c as cloneLayout, a as cloneLayoutItem, d as getCompactor, g as getLayoutItem, h as horizontalCompactor, n as noCompactor, f as setTopLeft, s as setTransform, e as verticalCompactor } from './position-CXNzFxI0.mjs';
6
- export { c as calcGridItemPosition, b as calcWH, a as calcXY } from './calculate-DwbL1D06.mjs';
2
+ import { k as PositionStrategy, D as DroppingPosition, d as ResizeHandleAxis, f as LayoutConstraint, a as LayoutItem, L as Layout, G as GridDragEvent, e as GridResizeEvent, c as Compactor, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-BiXsdXr7.mjs';
3
+ export { C as CompactType, P as Position } from './types-BiXsdXr7.mjs';
4
+ export { E as EventCallback, G as GridLayout, a as GridLayoutProps, R as ResponsiveGridLayout, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-DqK__izz.mjs';
5
+ export { b as bottom, c as cloneLayout, a as cloneLayoutItem, d as getCompactor, g as getLayoutItem, h as horizontalCompactor, n as noCompactor, f as setTopLeft, s as setTransform, e as verticalCompactor } from './position-CetgOHhD.mjs';
6
+ export { c as calcGridItemPosition, b as calcWH, a as calcXY } from './calculate-FbCWy8x1.mjs';
7
7
 
8
8
  /**
9
9
  * GridItem component
@@ -196,14 +196,12 @@ interface UseGridLayoutOptions {
196
196
  layout: Layout;
197
197
  /** Number of columns */
198
198
  cols: number;
199
- /** Compaction type: 'vertical', 'horizontal', or null */
200
- compactType?: CompactType;
201
- /** Allow items to overlap */
202
- allowOverlap?: boolean;
203
199
  /** Prevent collisions when moving items */
204
200
  preventCollision?: boolean;
205
201
  /** Called when layout changes */
206
202
  onLayoutChange?: (layout: Layout) => void;
203
+ /** Compactor for layout compaction (default: verticalCompactor) */
204
+ compactor?: Compactor;
207
205
  }
208
206
  interface UseGridLayoutResult {
209
207
  /** Current layout */
@@ -258,8 +256,7 @@ interface UseGridLayoutResult {
258
256
  * containerHeight
259
257
  * } = useGridLayout({
260
258
  * layout: initialLayout,
261
- * cols: 12,
262
- * compactType: 'vertical'
259
+ * cols: 12
263
260
  * });
264
261
  *
265
262
  * return (
@@ -300,8 +297,8 @@ interface UseResponsiveLayoutOptions<B extends Breakpoint = DefaultBreakpoints>
300
297
  cols?: Breakpoints<B>;
301
298
  /** Layouts for each breakpoint */
302
299
  layouts?: ResponsiveLayouts<B>;
303
- /** Compaction type */
304
- compactType?: CompactType;
300
+ /** Compactor for layout compaction (default: verticalCompactor) */
301
+ compactor?: Compactor;
305
302
  /** Called when breakpoint changes */
306
303
  onBreakpointChange?: (newBreakpoint: B, cols: number) => void;
307
304
  /** Called when layout changes */
@@ -358,4 +355,4 @@ interface UseResponsiveLayoutResult<B extends Breakpoint = DefaultBreakpoints> {
358
355
  */
359
356
  declare function useResponsiveLayout<B extends Breakpoint = DefaultBreakpoints>(options: UseResponsiveLayoutOptions<B>): UseResponsiveLayoutResult<B>;
360
357
 
361
- export { Breakpoint, Breakpoints, CompactType, Compactor, DEFAULT_BREAKPOINTS, DEFAULT_COLS, type DefaultBreakpoints, type DragState, type DropState, DroppingPosition, GridDragEvent, GridItem, type GridItemCallback, type GridItemProps, GridResizeEvent, Layout, LayoutItem, type ResizeHandle, ResizeHandleAxis, type ResizeState, ResponsiveLayouts, type UseContainerWidthOptions, type UseContainerWidthResult, type UseGridLayoutOptions, type UseGridLayoutResult, type UseResponsiveLayoutOptions, type UseResponsiveLayoutResult, useContainerWidth, useGridLayout, useResponsiveLayout };
358
+ export { Breakpoint, Breakpoints, Compactor, DEFAULT_BREAKPOINTS, DEFAULT_COLS, type DefaultBreakpoints, type DragState, type DropState, DroppingPosition, GridDragEvent, GridItem, type GridItemCallback, type GridItemProps, GridResizeEvent, Layout, LayoutItem, type ResizeHandle, ResizeHandleAxis, type ResizeState, ResponsiveLayouts, type UseContainerWidthOptions, type UseContainerWidthResult, type UseGridLayoutOptions, type UseGridLayoutResult, type UseResponsiveLayoutOptions, type UseResponsiveLayoutResult, useContainerWidth, useGridLayout, useResponsiveLayout };
package/dist/react.d.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  import React__default, { ReactElement, CSSProperties, RefObject } from 'react';
2
- import { k as PositionStrategy, D as DroppingPosition, d as ResizeHandleAxis, f as LayoutConstraint, a as LayoutItem, L as Layout, G as GridDragEvent, e as GridResizeEvent, C as CompactType, c as Compactor, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-CokovIMH.js';
3
- export { P as Position } from './types-CokovIMH.js';
4
- export { E as EventCallback, G as GridLayout, a as GridLayoutProps, R as ResponsiveGridLayout, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-CLn16-X3.js';
5
- export { b as bottom, c as cloneLayout, a as cloneLayoutItem, d as getCompactor, g as getLayoutItem, h as horizontalCompactor, n as noCompactor, f as setTopLeft, s as setTransform, e as verticalCompactor } from './position-Dk0FRWA9.js';
6
- export { c as calcGridItemPosition, b as calcWH, a as calcXY } from './calculate-DsVTldEE.js';
2
+ import { k as PositionStrategy, D as DroppingPosition, d as ResizeHandleAxis, f as LayoutConstraint, a as LayoutItem, L as Layout, G as GridDragEvent, e as GridResizeEvent, c as Compactor, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-BiXsdXr7.js';
3
+ export { C as CompactType, P as Position } from './types-BiXsdXr7.js';
4
+ export { E as EventCallback, G as GridLayout, a as GridLayoutProps, R as ResponsiveGridLayout, b as ResponsiveGridLayoutProps } from './ResponsiveGridLayout-MbDNfJ8M.js';
5
+ export { b as bottom, c as cloneLayout, a as cloneLayoutItem, d as getCompactor, g as getLayoutItem, h as horizontalCompactor, n as noCompactor, f as setTopLeft, s as setTransform, e as verticalCompactor } from './position-DhZqWO1-.js';
6
+ export { c as calcGridItemPosition, b as calcWH, a as calcXY } from './calculate-9RxGrt-U.js';
7
7
 
8
8
  /**
9
9
  * GridItem component
@@ -196,14 +196,12 @@ interface UseGridLayoutOptions {
196
196
  layout: Layout;
197
197
  /** Number of columns */
198
198
  cols: number;
199
- /** Compaction type: 'vertical', 'horizontal', or null */
200
- compactType?: CompactType;
201
- /** Allow items to overlap */
202
- allowOverlap?: boolean;
203
199
  /** Prevent collisions when moving items */
204
200
  preventCollision?: boolean;
205
201
  /** Called when layout changes */
206
202
  onLayoutChange?: (layout: Layout) => void;
203
+ /** Compactor for layout compaction (default: verticalCompactor) */
204
+ compactor?: Compactor;
207
205
  }
208
206
  interface UseGridLayoutResult {
209
207
  /** Current layout */
@@ -258,8 +256,7 @@ interface UseGridLayoutResult {
258
256
  * containerHeight
259
257
  * } = useGridLayout({
260
258
  * layout: initialLayout,
261
- * cols: 12,
262
- * compactType: 'vertical'
259
+ * cols: 12
263
260
  * });
264
261
  *
265
262
  * return (
@@ -300,8 +297,8 @@ interface UseResponsiveLayoutOptions<B extends Breakpoint = DefaultBreakpoints>
300
297
  cols?: Breakpoints<B>;
301
298
  /** Layouts for each breakpoint */
302
299
  layouts?: ResponsiveLayouts<B>;
303
- /** Compaction type */
304
- compactType?: CompactType;
300
+ /** Compactor for layout compaction (default: verticalCompactor) */
301
+ compactor?: Compactor;
305
302
  /** Called when breakpoint changes */
306
303
  onBreakpointChange?: (newBreakpoint: B, cols: number) => void;
307
304
  /** Called when layout changes */
@@ -358,4 +355,4 @@ interface UseResponsiveLayoutResult<B extends Breakpoint = DefaultBreakpoints> {
358
355
  */
359
356
  declare function useResponsiveLayout<B extends Breakpoint = DefaultBreakpoints>(options: UseResponsiveLayoutOptions<B>): UseResponsiveLayoutResult<B>;
360
357
 
361
- export { Breakpoint, Breakpoints, CompactType, Compactor, DEFAULT_BREAKPOINTS, DEFAULT_COLS, type DefaultBreakpoints, type DragState, type DropState, DroppingPosition, GridDragEvent, GridItem, type GridItemCallback, type GridItemProps, GridResizeEvent, Layout, LayoutItem, type ResizeHandle, ResizeHandleAxis, type ResizeState, ResponsiveLayouts, type UseContainerWidthOptions, type UseContainerWidthResult, type UseGridLayoutOptions, type UseGridLayoutResult, type UseResponsiveLayoutOptions, type UseResponsiveLayoutResult, useContainerWidth, useGridLayout, useResponsiveLayout };
358
+ export { Breakpoint, Breakpoints, Compactor, DEFAULT_BREAKPOINTS, DEFAULT_COLS, type DefaultBreakpoints, type DragState, type DropState, DroppingPosition, GridDragEvent, GridItem, type GridItemCallback, type GridItemProps, GridResizeEvent, Layout, LayoutItem, type ResizeHandle, ResizeHandleAxis, type ResizeState, ResponsiveLayouts, type UseContainerWidthOptions, type UseContainerWidthResult, type UseGridLayoutOptions, type UseGridLayoutResult, type UseResponsiveLayoutOptions, type UseResponsiveLayoutResult, useContainerWidth, useGridLayout, useResponsiveLayout };
package/dist/react.js CHANGED
@@ -1,68 +1,68 @@
1
1
  'use strict';
2
2
 
3
- var chunk43GDBEG4_js = require('./chunk-43GDBEG4.js');
4
- require('./chunk-7ELO5FRW.js');
5
- var chunkNQUM7RXX_js = require('./chunk-NQUM7RXX.js');
6
- var chunk2TEFHZC4_js = require('./chunk-2TEFHZC4.js');
3
+ var chunkQGXQSZII_js = require('./chunk-QGXQSZII.js');
4
+ require('./chunk-PBQSHIID.js');
5
+ var chunk3CEWSUXL_js = require('./chunk-3CEWSUXL.js');
6
+ var chunk2DDROKB2_js = require('./chunk-2DDROKB2.js');
7
7
  var chunkBJFPTW5Q_js = require('./chunk-BJFPTW5Q.js');
8
8
 
9
9
 
10
10
 
11
11
  Object.defineProperty(exports, "DEFAULT_BREAKPOINTS", {
12
12
  enumerable: true,
13
- get: function () { return chunk43GDBEG4_js.DEFAULT_BREAKPOINTS; }
13
+ get: function () { return chunkQGXQSZII_js.DEFAULT_BREAKPOINTS; }
14
14
  });
15
15
  Object.defineProperty(exports, "DEFAULT_COLS", {
16
16
  enumerable: true,
17
- get: function () { return chunk43GDBEG4_js.DEFAULT_COLS; }
17
+ get: function () { return chunkQGXQSZII_js.DEFAULT_COLS; }
18
18
  });
19
19
  Object.defineProperty(exports, "useContainerWidth", {
20
20
  enumerable: true,
21
- get: function () { return chunk43GDBEG4_js.useContainerWidth; }
21
+ get: function () { return chunkQGXQSZII_js.useContainerWidth; }
22
22
  });
23
23
  Object.defineProperty(exports, "useGridLayout", {
24
24
  enumerable: true,
25
- get: function () { return chunk43GDBEG4_js.useGridLayout; }
25
+ get: function () { return chunkQGXQSZII_js.useGridLayout; }
26
26
  });
27
27
  Object.defineProperty(exports, "useResponsiveLayout", {
28
28
  enumerable: true,
29
- get: function () { return chunk43GDBEG4_js.useResponsiveLayout; }
29
+ get: function () { return chunkQGXQSZII_js.useResponsiveLayout; }
30
30
  });
31
31
  Object.defineProperty(exports, "GridItem", {
32
32
  enumerable: true,
33
- get: function () { return chunkNQUM7RXX_js.GridItem; }
33
+ get: function () { return chunk3CEWSUXL_js.GridItem; }
34
34
  });
35
35
  Object.defineProperty(exports, "GridLayout", {
36
36
  enumerable: true,
37
- get: function () { return chunkNQUM7RXX_js.GridLayout; }
37
+ get: function () { return chunk3CEWSUXL_js.GridLayout; }
38
38
  });
39
39
  Object.defineProperty(exports, "ResponsiveGridLayout", {
40
40
  enumerable: true,
41
- get: function () { return chunkNQUM7RXX_js.ResponsiveGridLayout; }
41
+ get: function () { return chunk3CEWSUXL_js.ResponsiveGridLayout; }
42
42
  });
43
43
  Object.defineProperty(exports, "getCompactor", {
44
44
  enumerable: true,
45
- get: function () { return chunk2TEFHZC4_js.getCompactor; }
45
+ get: function () { return chunk2DDROKB2_js.getCompactor; }
46
46
  });
47
47
  Object.defineProperty(exports, "horizontalCompactor", {
48
48
  enumerable: true,
49
- get: function () { return chunk2TEFHZC4_js.horizontalCompactor; }
49
+ get: function () { return chunk2DDROKB2_js.horizontalCompactor; }
50
50
  });
51
51
  Object.defineProperty(exports, "noCompactor", {
52
52
  enumerable: true,
53
- get: function () { return chunk2TEFHZC4_js.noCompactor; }
53
+ get: function () { return chunk2DDROKB2_js.noCompactor; }
54
54
  });
55
55
  Object.defineProperty(exports, "setTopLeft", {
56
56
  enumerable: true,
57
- get: function () { return chunk2TEFHZC4_js.setTopLeft; }
57
+ get: function () { return chunk2DDROKB2_js.setTopLeft; }
58
58
  });
59
59
  Object.defineProperty(exports, "setTransform", {
60
60
  enumerable: true,
61
- get: function () { return chunk2TEFHZC4_js.setTransform; }
61
+ get: function () { return chunk2DDROKB2_js.setTransform; }
62
62
  });
63
63
  Object.defineProperty(exports, "verticalCompactor", {
64
64
  enumerable: true,
65
- get: function () { return chunk2TEFHZC4_js.verticalCompactor; }
65
+ get: function () { return chunk2DDROKB2_js.verticalCompactor; }
66
66
  });
67
67
  Object.defineProperty(exports, "bottom", {
68
68
  enumerable: true,
package/dist/react.mjs CHANGED
@@ -1,7 +1,7 @@
1
- export { DEFAULT_BREAKPOINTS, DEFAULT_COLS, useContainerWidth, useGridLayout, useResponsiveLayout } from './chunk-MUNIXYTV.mjs';
2
- import './chunk-526JND3R.mjs';
3
- export { GridItem, GridLayout, ResponsiveGridLayout } from './chunk-OWK47QTG.mjs';
4
- export { getCompactor, horizontalCompactor, noCompactor, setTopLeft, setTransform, verticalCompactor } from './chunk-OH26KG7Y.mjs';
1
+ export { DEFAULT_BREAKPOINTS, DEFAULT_COLS, useContainerWidth, useGridLayout, useResponsiveLayout } from './chunk-YFVX5RDK.mjs';
2
+ import './chunk-ZWN22PS2.mjs';
3
+ export { GridItem, GridLayout, ResponsiveGridLayout } from './chunk-AZ6K3JIJ.mjs';
4
+ export { getCompactor, horizontalCompactor, noCompactor, setTopLeft, setTransform, verticalCompactor } from './chunk-XYPIYYYQ.mjs';
5
5
  export { bottom, calcGridItemPosition, calcWH, calcXY, cloneLayout, cloneLayoutItem, getLayoutItem } from './chunk-AWM66AWF.mjs';
6
6
  //# sourceMappingURL=react.mjs.map
7
7
  //# sourceMappingURL=react.mjs.map
@@ -1,4 +1,4 @@
1
- import { a as LayoutItem, L as Layout, C as CompactType, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-CokovIMH.mjs';
1
+ import { a as LayoutItem, L as Layout, C as CompactType, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts, c as Compactor } from './types-BiXsdXr7.js';
2
2
 
3
3
  /**
4
4
  * Collision detection utilities for grid layouts.
@@ -125,10 +125,10 @@ declare function getColsFromBreakpoint<B extends Breakpoint>(breakpoint: B, cols
125
125
  * @param breakpoint - Target breakpoint
126
126
  * @param lastBreakpoint - Previous breakpoint (for fallback)
127
127
  * @param cols - Column count for the target breakpoint
128
- * @param compactType - Compaction type
128
+ * @param compactTypeOrCompactor - Compaction type string (legacy) or Compactor object
129
129
  * @returns Layout for the breakpoint
130
130
  */
131
- declare function findOrGenerateResponsiveLayout<B extends Breakpoint>(layouts: ResponsiveLayouts<B>, breakpoints: Breakpoints<B>, breakpoint: B, lastBreakpoint: B, cols: number, compactType: CompactType): Layout;
131
+ declare function findOrGenerateResponsiveLayout<B extends Breakpoint>(layouts: ResponsiveLayouts<B>, breakpoints: Breakpoints<B>, breakpoint: B, lastBreakpoint: B, cols: number, compactTypeOrCompactor: CompactType | Compactor): Layout;
132
132
  type IndentationValue<B extends Breakpoint> = readonly [number, number] | Partial<Record<B, readonly [number, number]>>;
133
133
  /**
134
134
  * Get margin or padding value for a breakpoint.
@@ -1,4 +1,4 @@
1
- import { a as LayoutItem, L as Layout, C as CompactType, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts } from './types-CokovIMH.js';
1
+ import { a as LayoutItem, L as Layout, C as CompactType, B as Breakpoint, b as Breakpoints, R as ResponsiveLayouts, c as Compactor } from './types-BiXsdXr7.mjs';
2
2
 
3
3
  /**
4
4
  * Collision detection utilities for grid layouts.
@@ -125,10 +125,10 @@ declare function getColsFromBreakpoint<B extends Breakpoint>(breakpoint: B, cols
125
125
  * @param breakpoint - Target breakpoint
126
126
  * @param lastBreakpoint - Previous breakpoint (for fallback)
127
127
  * @param cols - Column count for the target breakpoint
128
- * @param compactType - Compaction type
128
+ * @param compactTypeOrCompactor - Compaction type string (legacy) or Compactor object
129
129
  * @returns Layout for the breakpoint
130
130
  */
131
- declare function findOrGenerateResponsiveLayout<B extends Breakpoint>(layouts: ResponsiveLayouts<B>, breakpoints: Breakpoints<B>, breakpoint: B, lastBreakpoint: B, cols: number, compactType: CompactType): Layout;
131
+ declare function findOrGenerateResponsiveLayout<B extends Breakpoint>(layouts: ResponsiveLayouts<B>, breakpoints: Breakpoints<B>, breakpoint: B, lastBreakpoint: B, cols: number, compactTypeOrCompactor: CompactType | Compactor): Layout;
132
132
  type IndentationValue<B extends Breakpoint> = readonly [number, number] | Partial<Record<B, readonly [number, number]>>;
133
133
  /**
134
134
  * Get margin or padding value for a breakpoint.
@@ -182,10 +182,6 @@ type OnLayoutChangeCallback = (layout: Layout) => void;
182
182
  * compact(layout, cols) {
183
183
  * // Custom compaction logic
184
184
  * return compactedLayout;
185
- * },
186
- * onMove(layout, item, x, y, cols) {
187
- * // Handle item movement
188
- * return updatedLayout;
189
185
  * }
190
186
  * };
191
187
  * ```
@@ -221,17 +217,6 @@ interface Compactor {
221
217
  * @returns The compacted layout
222
218
  */
223
219
  compact(layout: Layout, cols: number): Layout;
224
- /**
225
- * Handle item movement, returning the updated layout.
226
- *
227
- * @param layout - Current layout
228
- * @param item - The item being moved
229
- * @param x - New x position
230
- * @param y - New y position
231
- * @param cols - Number of columns
232
- * @returns Updated layout after the move
233
- */
234
- onMove(layout: Layout, item: LayoutItem, x: number, y: number, cols: number): Layout;
235
220
  }
236
221
  /**
237
222
  * Interface for CSS positioning strategies.
@@ -266,13 +251,17 @@ interface PositionStrategy {
266
251
  /**
267
252
  * Calculate position during drag operations, accounting for transforms and scale.
268
253
  *
254
+ * This method is optional. When not provided, react-draggable uses its built-in
255
+ * parent-relative coordinate calculation. Only override this when you need custom
256
+ * coordinate handling, such as for scaled containers.
257
+ *
269
258
  * @param clientX - Mouse client X position
270
259
  * @param clientY - Mouse client Y position
271
260
  * @param offsetX - Offset from element origin X
272
261
  * @param offsetY - Offset from element origin Y
273
262
  * @returns Adjusted left/top position
274
263
  */
275
- calcDragPosition(clientX: number, clientY: number, offsetX: number, offsetY: number): PartialPosition;
264
+ calcDragPosition?(clientX: number, clientY: number, offsetX: number, offsetY: number): PartialPosition;
276
265
  }
277
266
  /**
278
267
  * Context provided to constraint functions during drag/resize operations.
@@ -182,10 +182,6 @@ type OnLayoutChangeCallback = (layout: Layout) => void;
182
182
  * compact(layout, cols) {
183
183
  * // Custom compaction logic
184
184
  * return compactedLayout;
185
- * },
186
- * onMove(layout, item, x, y, cols) {
187
- * // Handle item movement
188
- * return updatedLayout;
189
185
  * }
190
186
  * };
191
187
  * ```
@@ -221,17 +217,6 @@ interface Compactor {
221
217
  * @returns The compacted layout
222
218
  */
223
219
  compact(layout: Layout, cols: number): Layout;
224
- /**
225
- * Handle item movement, returning the updated layout.
226
- *
227
- * @param layout - Current layout
228
- * @param item - The item being moved
229
- * @param x - New x position
230
- * @param y - New y position
231
- * @param cols - Number of columns
232
- * @returns Updated layout after the move
233
- */
234
- onMove(layout: Layout, item: LayoutItem, x: number, y: number, cols: number): Layout;
235
220
  }
236
221
  /**
237
222
  * Interface for CSS positioning strategies.
@@ -266,13 +251,17 @@ interface PositionStrategy {
266
251
  /**
267
252
  * Calculate position during drag operations, accounting for transforms and scale.
268
253
  *
254
+ * This method is optional. When not provided, react-draggable uses its built-in
255
+ * parent-relative coordinate calculation. Only override this when you need custom
256
+ * coordinate handling, such as for scaled containers.
257
+ *
269
258
  * @param clientX - Mouse client X position
270
259
  * @param clientY - Mouse client Y position
271
260
  * @param offsetX - Offset from element origin X
272
261
  * @param offsetY - Offset from element origin Y
273
262
  * @returns Adjusted left/top position
274
263
  */
275
- calcDragPosition(clientX: number, clientY: number, offsetX: number, offsetY: number): PartialPosition;
264
+ calcDragPosition?(clientX: number, clientY: number, offsetX: number, offsetY: number): PartialPosition;
276
265
  }
277
266
  /**
278
267
  * Context provided to constraint functions during drag/resize operations.
package/index-dev.js CHANGED
@@ -2,11 +2,10 @@
2
2
 
3
3
  // Legacy API (default)
4
4
  module.exports = require("./src/legacy/ReactGridLayout").default;
5
- module.exports.utils = require("./src/legacy/utils-compat");
6
- module.exports.calculateUtils = require("./src/legacy/calculate-compat");
5
+ // Note: utils, calculateUtils, responsive-utils are NOT exported (#2213)
6
+ // They were never part of the official public API
7
7
  module.exports.Responsive =
8
8
  require("./src/legacy/ResponsiveReactGridLayout").default;
9
- module.exports.Responsive.utils = require("./src/legacy/responsive-compat");
10
9
  module.exports.WidthProvider = require("./src/legacy/WidthProvider").default;
11
10
 
12
11
  // v2 API additions
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-grid-layout",
3
- "version": "2.2.0",
3
+ "version": "2.2.1",
4
4
  "description": "A draggable and resizable grid layout with responsive breakpoints, for React.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",