@planningcenter/react-beautiful-dnd 13.3.1-rc.1 → 13.4.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.
@@ -1,31 +1,26 @@
1
1
  'use strict';
2
2
 
3
- Object.defineProperty(exports, '__esModule', { value: true });
4
-
5
- function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
6
-
7
3
  var React = require('react');
8
- var React__default = _interopDefault(React);
9
- var _inheritsLoose = _interopDefault(require('@babel/runtime/helpers/inheritsLoose'));
10
- var _extends = _interopDefault(require('@babel/runtime/helpers/extends'));
4
+ var _inheritsLoose = require('@babel/runtime/helpers/inheritsLoose');
5
+ var _extends = require('@babel/runtime/helpers/extends');
11
6
  var redux = require('redux');
12
7
  var reactRedux = require('react-redux');
13
8
  var useMemoOne = require('use-memo-one');
14
9
  var cssBoxModel = require('css-box-model');
15
- var memoizeOne = _interopDefault(require('memoize-one'));
16
- var rafSchd = _interopDefault(require('raf-schd'));
17
- var ReactDOM = _interopDefault(require('react-dom'));
10
+ var memoizeOne = require('memoize-one');
11
+ var rafSchd = require('raf-schd');
12
+ var ReactDOM = require('react-dom');
18
13
 
19
- var isProduction = process.env.NODE_ENV === 'production';
14
+ var isProduction$1 = process.env.NODE_ENV === 'production';
20
15
  var spacesAndTabs = /[ \t]{2,}/g;
21
16
  var lineStartWithSpaces = /^[ \t]*/gm;
22
17
 
23
- var clean = function clean(value) {
18
+ var clean$2 = function clean(value) {
24
19
  return value.replace(spacesAndTabs, ' ').replace(lineStartWithSpaces, '').trim();
25
20
  };
26
21
 
27
22
  var getDevMessage = function getDevMessage(message) {
28
- return clean("\n %creact-beautiful-dnd\n\n %c" + clean(message) + "\n\n %c\uD83D\uDC77\u200D This is a development only message. It will be removed in production builds.\n");
23
+ return clean$2("\n %creact-beautiful-dnd\n\n %c" + clean$2(message) + "\n\n %c\uD83D\uDC77\u200D This is a development only message. It will be removed in production builds.\n");
29
24
  };
30
25
 
31
26
  var getFormattedMessage = function getFormattedMessage(message) {
@@ -35,7 +30,7 @@ var isDisabledFlag = '__react-beautiful-dnd-disable-dev-warnings';
35
30
  function log(type, message) {
36
31
  var _console;
37
32
 
38
- if (isProduction) {
33
+ if (isProduction$1) {
39
34
  return;
40
35
  }
41
36
 
@@ -48,7 +43,7 @@ function log(type, message) {
48
43
  var warning = log.bind(null, 'warn');
49
44
  var error = log.bind(null, 'error');
50
45
 
51
- function noop() {}
46
+ function noop$2() {}
52
47
 
53
48
  function getOptions(shared, fromBinding) {
54
49
  return _extends({}, shared, {}, fromBinding);
@@ -69,8 +64,8 @@ function bindEvents(el, bindings, sharedOptions) {
69
64
  };
70
65
  }
71
66
 
72
- var isProduction$1 = process.env.NODE_ENV === 'production';
73
- var prefix = 'Invariant failed';
67
+ var isProduction = process.env.NODE_ENV === 'production';
68
+ var prefix$1 = 'Invariant failed';
74
69
  function RbdInvariant(message) {
75
70
  this.message = message;
76
71
  }
@@ -84,10 +79,10 @@ function invariant(condition, message) {
84
79
  return;
85
80
  }
86
81
 
87
- if (isProduction$1) {
88
- throw new RbdInvariant(prefix);
82
+ if (isProduction) {
83
+ throw new RbdInvariant(prefix$1);
89
84
  } else {
90
- throw new RbdInvariant(prefix + ": " + (message || ''));
85
+ throw new RbdInvariant(prefix$1 + ": " + (message || ''));
91
86
  }
92
87
  }
93
88
 
@@ -103,7 +98,7 @@ var ErrorBoundary = function (_React$Component) {
103
98
 
104
99
  _this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;
105
100
  _this.callbacks = null;
106
- _this.unbind = noop;
101
+ _this.unbind = noop$2;
107
102
 
108
103
  _this.onWindowError = function (event) {
109
104
  var callbacks = _this.getCallbacks();
@@ -170,7 +165,7 @@ var ErrorBoundary = function (_React$Component) {
170
165
  };
171
166
 
172
167
  return ErrorBoundary;
173
- }(React__default.Component);
168
+ }(React.Component);
174
169
 
175
170
  var dragHandleUsageInstructions = "\n Press space bar to start a drag.\n When dragging you can use the arrow keys to move the item around and escape to cancel.\n Some screen readers may require you to be in focus mode or to use your pass through key\n";
176
171
 
@@ -249,6 +244,7 @@ var preset = {
249
244
  onDragUpdate: onDragUpdate,
250
245
  onDragEnd: onDragEnd
251
246
  };
247
+ var preset$1 = preset;
252
248
 
253
249
  var origin = {
254
250
  x: 0,
@@ -266,7 +262,7 @@ var subtract = function subtract(point1, point2) {
266
262
  y: point1.y - point2.y
267
263
  };
268
264
  };
269
- var isEqual = function isEqual(point1, point2) {
265
+ var isEqual$1 = function isEqual(point1, point2) {
270
266
  return point1.x === point2.x && point1.y === point2.y;
271
267
  };
272
268
  var negate = function negate(point) {
@@ -287,7 +283,7 @@ var patch = function patch(line, value, otherValue) {
287
283
  var distance = function distance(point1, point2) {
288
284
  return Math.sqrt(Math.pow(point2.x - point1.x, 2) + Math.pow(point2.y - point1.y, 2));
289
285
  };
290
- var closest = function closest(target, points) {
286
+ var closest$1 = function closest(target, points) {
291
287
  return Math.min.apply(Math, points.map(function (point) {
292
288
  return distance(target, point);
293
289
  }));
@@ -346,7 +342,7 @@ var noSpacing = {
346
342
  left: 0
347
343
  };
348
344
 
349
- var scroll = function scroll(target, frame) {
345
+ var scroll$1 = function scroll(target, frame) {
350
346
  if (!frame) {
351
347
  return target;
352
348
  }
@@ -377,7 +373,7 @@ var getSubject = (function (_ref) {
377
373
  withPlaceholder = _ref.withPlaceholder,
378
374
  axis = _ref.axis,
379
375
  frame = _ref.frame;
380
- var scrolled = scroll(page.marginBox, frame);
376
+ var scrolled = scroll$1(page.marginBox, frame);
381
377
  var increased = increase(scrolled, axis, withPlaceholder);
382
378
  var clipped = clip(increased, frame);
383
379
  return {
@@ -595,6 +591,7 @@ var noImpact = {
595
591
  displacedBy: noDisplacedBy,
596
592
  at: null
597
593
  };
594
+ var noImpact$1 = noImpact;
598
595
 
599
596
  var isWithin = (function (lowerBound, upperBound) {
600
597
  return function (value) {
@@ -696,7 +693,7 @@ var isVisibleInViewport = function isVisibleInViewport(target, viewport, isVisib
696
693
  return isVisibleThroughFrameFn(viewport)(target);
697
694
  };
698
695
 
699
- var isVisible = function isVisible(_ref) {
696
+ var isVisible$1 = function isVisible(_ref) {
700
697
  var toBeDisplaced = _ref.target,
701
698
  destination = _ref.destination,
702
699
  viewport = _ref.viewport,
@@ -707,17 +704,17 @@ var isVisible = function isVisible(_ref) {
707
704
  };
708
705
 
709
706
  var isPartiallyVisible = function isPartiallyVisible(args) {
710
- return isVisible(_extends({}, args, {
707
+ return isVisible$1(_extends({}, args, {
711
708
  isVisibleThroughFrameFn: isPartiallyVisibleThroughFrame
712
709
  }));
713
710
  };
714
711
  var isTotallyVisible = function isTotallyVisible(args) {
715
- return isVisible(_extends({}, args, {
712
+ return isVisible$1(_extends({}, args, {
716
713
  isVisibleThroughFrameFn: isTotallyVisibleThroughFrame
717
714
  }));
718
715
  };
719
716
  var isTotallyVisibleOnAxis = function isTotallyVisibleOnAxis(args) {
720
- return isVisible(_extends({}, args, {
717
+ return isVisible$1(_extends({}, args, {
721
718
  isVisibleThroughFrameFn: isTotallyVisibleThroughFrameOnAxis(args.destination.axis)
722
719
  }));
723
720
  };
@@ -1199,7 +1196,7 @@ var scrollViewport = (function (viewport, newScroll) {
1199
1196
  return updated;
1200
1197
  });
1201
1198
 
1202
- function getDraggables(ids, draggables) {
1199
+ function getDraggables$1(ids, draggables) {
1203
1200
  return ids.map(function (id) {
1204
1201
  return draggables[id];
1205
1202
  });
@@ -1227,7 +1224,7 @@ var speculativelyIncrease = (function (_ref) {
1227
1224
  var scrolledDroppable = destination.frame ? scrollDroppable(destination, add(destination.frame.scroll.current, maxScrollChange)) : destination;
1228
1225
  var last = impact.displaced;
1229
1226
  var withViewportScroll = getDisplacementGroups({
1230
- afterDragging: getDraggables(last.all, draggables),
1227
+ afterDragging: getDraggables$1(last.all, draggables),
1231
1228
  destination: destination,
1232
1229
  displacedBy: impact.displacedBy,
1233
1230
  viewport: scrolledViewport.frame,
@@ -1235,7 +1232,7 @@ var speculativelyIncrease = (function (_ref) {
1235
1232
  forceShouldAnimate: false
1236
1233
  });
1237
1234
  var withDroppableScroll = getDisplacementGroups({
1238
- afterDragging: getDraggables(last.all, draggables),
1235
+ afterDragging: getDraggables$1(last.all, draggables),
1239
1236
  destination: scrolledDroppable,
1240
1237
  displacedBy: impact.displacedBy,
1241
1238
  viewport: viewport.frame,
@@ -1459,8 +1456,8 @@ var getBestCrossAxisDroppable = (function (_ref) {
1459
1456
  }
1460
1457
 
1461
1458
  return candidates.sort(function (a, b) {
1462
- var first = closest(pageBorderBoxCenter, getCorners(getKnownActive(a)));
1463
- var second = closest(pageBorderBoxCenter, getCorners(getKnownActive(b)));
1459
+ var first = closest$1(pageBorderBoxCenter, getCorners(getKnownActive(a)));
1460
+ var second = closest$1(pageBorderBoxCenter, getCorners(getKnownActive(b)));
1464
1461
 
1465
1462
  if (first !== second) {
1466
1463
  return first - second;
@@ -1768,7 +1765,7 @@ var whatIsDraggedOver = (function (impact) {
1768
1765
  return at.combine.droppableId;
1769
1766
  });
1770
1767
 
1771
- var getDroppableOver = function getDroppableOver(impact, droppables) {
1768
+ var getDroppableOver$1 = function getDroppableOver(impact, droppables) {
1772
1769
  var id = whatIsDraggedOver(impact);
1773
1770
  return id ? droppables[id] : null;
1774
1771
  };
@@ -1776,7 +1773,7 @@ var getDroppableOver = function getDroppableOver(impact, droppables) {
1776
1773
  var moveInDirection = (function (_ref) {
1777
1774
  var state = _ref.state,
1778
1775
  type = _ref.type;
1779
- var isActuallyOver = getDroppableOver(state.impact, state.dimensions.droppables);
1776
+ var isActuallyOver = getDroppableOver$1(state.impact, state.dimensions.droppables);
1780
1777
  var isMainAxisMovementAllowed = Boolean(isActuallyOver);
1781
1778
  var home = state.dimensions.droppables[state.critical.droppable.id];
1782
1779
  var isOver = isActuallyOver || home;
@@ -1849,7 +1846,7 @@ function getFurthestAway(_ref) {
1849
1846
  return sorted[0] ? sorted[0].id : null;
1850
1847
  }
1851
1848
 
1852
- function getDroppableOver$1(_ref2) {
1849
+ function getDroppableOver(_ref2) {
1853
1850
  var pageBorderBox = _ref2.pageBorderBox,
1854
1851
  draggable = _ref2.draggable,
1855
1852
  droppables = _ref2.droppables;
@@ -2071,14 +2068,14 @@ var getDragImpact = (function (_ref) {
2071
2068
  viewport = _ref.viewport,
2072
2069
  afterCritical = _ref.afterCritical;
2073
2070
  var pageBorderBox = offsetRectByPosition(draggable.page.borderBox, pageOffset);
2074
- var destinationId = getDroppableOver$1({
2071
+ var destinationId = getDroppableOver({
2075
2072
  pageBorderBox: pageBorderBox,
2076
2073
  draggable: draggable,
2077
2074
  droppables: droppables
2078
2075
  });
2079
2076
 
2080
2077
  if (!destinationId) {
2081
- return noImpact;
2078
+ return noImpact$1;
2082
2079
  }
2083
2080
 
2084
2081
  var destination = droppables[destinationId];
@@ -2233,7 +2230,7 @@ var update = (function (_ref) {
2233
2230
  return result;
2234
2231
  });
2235
2232
 
2236
- function getDraggables$1(ids, draggables) {
2233
+ function getDraggables(ids, draggables) {
2237
2234
  return ids.map(function (id) {
2238
2235
  return draggables[id];
2239
2236
  });
@@ -2246,7 +2243,7 @@ var recompute = (function (_ref) {
2246
2243
  destination = _ref.destination,
2247
2244
  forceShouldAnimate = _ref.forceShouldAnimate;
2248
2245
  var last = impact.displaced;
2249
- var afterDragging = getDraggables$1(last.all, draggables);
2246
+ var afterDragging = getDraggables(last.all, draggables);
2250
2247
  var displaced = getDisplacementGroups({
2251
2248
  afterDragging: afterDragging,
2252
2249
  destination: destination,
@@ -2543,18 +2540,18 @@ function removeScrollJumpRequest(state) {
2543
2540
  return state;
2544
2541
  }
2545
2542
 
2546
- var idle = {
2543
+ var idle$2 = {
2547
2544
  phase: 'IDLE',
2548
2545
  completed: null,
2549
2546
  shouldFlush: false
2550
2547
  };
2551
2548
  var reducer = (function (state, action) {
2552
2549
  if (state === void 0) {
2553
- state = idle;
2550
+ state = idle$2;
2554
2551
  }
2555
2552
 
2556
2553
  if (action.type === 'FLUSH') {
2557
- return _extends({}, idle, {
2554
+ return _extends({}, idle$2, {
2558
2555
  shouldFlush: true
2559
2556
  });
2560
2557
  }
@@ -2646,7 +2643,7 @@ var reducer = (function (state, action) {
2646
2643
  !isMovementAllowed(state) ? process.env.NODE_ENV !== "production" ? invariant(false, action.type + " not permitted in phase " + state.phase) : invariant(false) : void 0;
2647
2644
  var _clientSelection = action.payload.client;
2648
2645
 
2649
- if (isEqual(_clientSelection, state.current.client.selection)) {
2646
+ if (isEqual$1(_clientSelection, state.current.client.selection)) {
2650
2647
  return state;
2651
2648
  }
2652
2649
 
@@ -2729,7 +2726,7 @@ var reducer = (function (state, action) {
2729
2726
  !state.isWindowScrollAllowed ? process.env.NODE_ENV !== "production" ? invariant(false, 'Window scrolling is currently not supported for fixed lists') : invariant(false) : void 0;
2730
2727
  var _newScroll = action.payload.newScroll;
2731
2728
 
2732
- if (isEqual(state.viewport.scroll.current, _newScroll)) {
2729
+ if (isEqual$1(state.viewport.scroll.current, _newScroll)) {
2733
2730
  return removeScrollJumpRequest(state);
2734
2731
  }
2735
2732
 
@@ -2755,7 +2752,7 @@ var reducer = (function (state, action) {
2755
2752
 
2756
2753
  var maxScroll = action.payload.maxScroll;
2757
2754
 
2758
- if (isEqual(maxScroll, state.viewport.scroll.max)) {
2755
+ if (isEqual$1(maxScroll, state.viewport.scroll.max)) {
2759
2756
  return state;
2760
2757
  }
2761
2758
 
@@ -2845,7 +2842,7 @@ var beforeInitialCapture = function beforeInitialCapture(args) {
2845
2842
  payload: args
2846
2843
  };
2847
2844
  };
2848
- var lift = function lift(args) {
2845
+ var lift$1 = function lift(args) {
2849
2846
  return {
2850
2847
  type: 'LIFT',
2851
2848
  payload: args
@@ -2947,7 +2944,7 @@ var completeDrop = function completeDrop(args) {
2947
2944
  payload: args
2948
2945
  };
2949
2946
  };
2950
- var drop = function drop(args) {
2947
+ var drop$1 = function drop(args) {
2951
2948
  return {
2952
2949
  type: 'DROP',
2953
2950
  payload: args
@@ -3003,7 +3000,7 @@ function validateDimensions(critical, dimensions) {
3003
3000
  }
3004
3001
  }
3005
3002
 
3006
- var lift$1 = (function (marshal) {
3003
+ var lift = (function (marshal) {
3007
3004
  return function (_ref) {
3008
3005
  var getState = _ref.getState,
3009
3006
  dispatch = _ref.dispatch;
@@ -3111,7 +3108,7 @@ var transitions = {
3111
3108
  };
3112
3109
 
3113
3110
  var moveTo = function moveTo(offset) {
3114
- return isEqual(offset, origin) ? null : "translate(" + offset.x + "px, " + offset.y + "px)";
3111
+ return isEqual$1(offset, origin) ? null : "translate(" + offset.x + "px, " + offset.y + "px)";
3115
3112
  };
3116
3113
 
3117
3114
  var transforms = {
@@ -3218,7 +3215,7 @@ var getDropImpact = (function (_ref) {
3218
3215
  };
3219
3216
  });
3220
3217
 
3221
- var drop$1 = (function (_ref) {
3218
+ var drop = (function (_ref) {
3222
3219
  var getState = _ref.getState,
3223
3220
  dispatch = _ref.dispatch;
3224
3221
  return function (next) {
@@ -3289,7 +3286,7 @@ var drop$1 = (function (_ref) {
3289
3286
  result: result,
3290
3287
  impact: impact
3291
3288
  };
3292
- var isAnimationRequired = !isEqual(state.current.client.offset, newHomeClientOffset) || Boolean(result.combine);
3289
+ var isAnimationRequired = !isEqual$1(state.current.client.offset, newHomeClientOffset) || Boolean(result.combine);
3293
3290
 
3294
3291
  if (!isAnimationRequired) {
3295
3292
  dispatch(completeDrop({
@@ -3346,10 +3343,10 @@ function getScrollListener(_ref) {
3346
3343
 
3347
3344
  var scheduled = rafSchd(updateScroll);
3348
3345
  var binding = getWindowScrollBinding(scheduled);
3349
- var unbind = noop;
3346
+ var unbind = noop$2;
3350
3347
 
3351
3348
  function isActive() {
3352
- return unbind !== noop;
3349
+ return unbind !== noop$2;
3353
3350
  }
3354
3351
 
3355
3352
  function start() {
@@ -3361,7 +3358,7 @@ function getScrollListener(_ref) {
3361
3358
  !isActive() ? process.env.NODE_ENV !== "production" ? invariant(false, 'Cannot stop scroll listener when not active') : invariant(false) : void 0;
3362
3359
  scheduled.cancel();
3363
3360
  unbind();
3364
- unbind = noop;
3361
+ unbind = noop$2;
3365
3362
  }
3366
3363
 
3367
3364
  return {
@@ -3581,7 +3578,7 @@ var getPublisher = (function (getResponders, announce) {
3581
3578
  };
3582
3579
  asyncMarshal.add(function () {
3583
3580
  withTimings('onDragStart', function () {
3584
- return execute(getResponders().onDragStart, data, announce, preset.onDragStart);
3581
+ return execute(getResponders().onDragStart, data, announce, preset$1.onDragStart);
3585
3582
  });
3586
3583
  });
3587
3584
  };
@@ -3619,7 +3616,7 @@ var getPublisher = (function (getResponders, announce) {
3619
3616
 
3620
3617
  asyncMarshal.add(function () {
3621
3618
  withTimings('onDragUpdate', function () {
3622
- return execute(getResponders().onDragUpdate, data, announce, preset.onDragUpdate);
3619
+ return execute(getResponders().onDragUpdate, data, announce, preset$1.onDragUpdate);
3623
3620
  });
3624
3621
  });
3625
3622
  };
@@ -3633,7 +3630,7 @@ var getPublisher = (function (getResponders, announce) {
3633
3630
  !dragging ? process.env.NODE_ENV !== "production" ? invariant(false, 'Cannot fire onDragEnd when there is no matching onDragStart') : invariant(false) : void 0;
3634
3631
  dragging = null;
3635
3632
  withTimings('onDragEnd', function () {
3636
- return execute(getResponders().onDragEnd, result, announce, preset.onDragEnd);
3633
+ return execute(getResponders().onDragEnd, result, announce, preset$1.onDragEnd);
3637
3634
  });
3638
3635
  };
3639
3636
 
@@ -3875,7 +3872,7 @@ var pendingDrop = (function (store) {
3875
3872
  return;
3876
3873
  }
3877
3874
 
3878
- store.dispatch(drop({
3875
+ store.dispatch(drop$1({
3879
3876
  reason: postActionState.reason
3880
3877
  }));
3881
3878
  };
@@ -3892,7 +3889,7 @@ var createStore = (function (_ref) {
3892
3889
  getResponders = _ref.getResponders,
3893
3890
  announce = _ref.announce,
3894
3891
  autoScroller = _ref.autoScroller;
3895
- return redux.createStore(reducer, composeEnhancers(redux.applyMiddleware(style(styleMarshal), dimensionMarshalStopper(dimensionMarshal), lift$1(dimensionMarshal), drop$1, dropAnimationFinish, dropAnimationFlushOnScroll, pendingDrop, autoScroll(autoScroller), scrollListener, focus(focusMarshal), responders(getResponders, announce))));
3892
+ return redux.createStore(reducer, composeEnhancers(redux.applyMiddleware(style(styleMarshal), dimensionMarshalStopper(dimensionMarshal), lift(dimensionMarshal), drop, dropAnimationFinish, dropAnimationFlushOnScroll, pendingDrop, autoScroll(autoScroller), scrollListener, focus(focusMarshal), responders(getResponders, announce))));
3896
3893
  });
3897
3894
 
3898
3895
  var clean$1 = function clean() {
@@ -4305,6 +4302,7 @@ var config = {
4305
4302
  accelerateAt: 360
4306
4303
  }
4307
4304
  };
4305
+ var config$1 = config;
4308
4306
 
4309
4307
  var minScroll = 1;
4310
4308
 
@@ -4313,7 +4311,7 @@ var getValueFromDistance = (function (distanceToEdge, thresholds, configOverride
4313
4311
  return 0;
4314
4312
  }
4315
4313
 
4316
- var maxSpeed = (configOverride == null ? void 0 : configOverride.maxPixelScroll) || config.maxPixelScroll;
4314
+ var maxSpeed = (configOverride == null ? void 0 : configOverride.maxPixelScroll) || config$1.maxPixelScroll;
4317
4315
 
4318
4316
  if (distanceToEdge <= thresholds.maxScrollValueAt) {
4319
4317
  return maxSpeed;
@@ -4329,18 +4327,18 @@ var getValueFromDistance = (function (distanceToEdge, thresholds, configOverride
4329
4327
  current: distanceToEdge
4330
4328
  });
4331
4329
  var percentageFromStartScrollingFrom = 1 - percentageFromMaxScrollValueAt;
4332
- var scroll = maxSpeed * config.ease(percentageFromStartScrollingFrom);
4330
+ var scroll = maxSpeed * config$1.ease(percentageFromStartScrollingFrom);
4333
4331
  return Math.ceil(scroll);
4334
4332
  });
4335
4333
 
4336
- var defaultAccelerateAt = config.durationDampening.accelerateAt;
4337
- var defaultStopAt = config.durationDampening.stopDampeningAt;
4334
+ var defaultAccelerateAt = config$1.durationDampening.accelerateAt;
4335
+ var defaultStopAt = config$1.durationDampening.stopDampeningAt;
4338
4336
  var dampenValueByTime = (function (proposedScroll, dragStartTime, configOverride) {
4339
4337
  var _configOverride$durat, _configOverride$durat2;
4340
4338
 
4341
4339
  var accelerateAt = (configOverride == null ? void 0 : (_configOverride$durat = configOverride.durationDampening) == null ? void 0 : _configOverride$durat.accelerateAt) || defaultAccelerateAt;
4342
4340
  var stopAt = (configOverride == null ? void 0 : (_configOverride$durat2 = configOverride.durationDampening) == null ? void 0 : _configOverride$durat2.stopDampeningAt) || defaultStopAt;
4343
- var ease = (configOverride == null ? void 0 : configOverride.ease) || config.ease;
4341
+ var ease = (configOverride == null ? void 0 : configOverride.ease) || config$1.ease;
4344
4342
  var startOfRange = dragStartTime;
4345
4343
  var endOfRange = stopAt;
4346
4344
  var now = Date.now();
@@ -4547,8 +4545,8 @@ var bufferThresholds = (function (_ref) {
4547
4545
  });
4548
4546
 
4549
4547
  var getDistanceThresholds = (function (container, axis, configOverride) {
4550
- var startFromPercentage = (configOverride == null ? void 0 : configOverride.startFromPercentage) || config.startFromPercentage;
4551
- var maxScrollAtPercentage = (configOverride == null ? void 0 : configOverride.maxScrollAtPercentage) || config.maxScrollAtPercentage;
4548
+ var startFromPercentage = (configOverride == null ? void 0 : configOverride.startFromPercentage) || config$1.startFromPercentage;
4549
+ var maxScrollAtPercentage = (configOverride == null ? void 0 : configOverride.maxScrollAtPercentage) || config$1.maxScrollAtPercentage;
4552
4550
  var startScrollingFrom = container[axis.size] * startFromPercentage;
4553
4551
  var maxScrollValueAt = container[axis.size] * maxScrollAtPercentage;
4554
4552
  var thresholds = {
@@ -4558,10 +4556,10 @@ var getDistanceThresholds = (function (container, axis, configOverride) {
4558
4556
  return thresholds;
4559
4557
  });
4560
4558
 
4561
- var clean$2 = apply(function (value) {
4559
+ var clean = apply(function (value) {
4562
4560
  return value === 0 ? 0 : value;
4563
4561
  });
4564
- var getScroll = (function (_ref) {
4562
+ var getScroll$1 = (function (_ref) {
4565
4563
  var dragStartTime = _ref.dragStartTime,
4566
4564
  container = _ref.container,
4567
4565
  containerScroll = _ref.containerScroll,
@@ -4596,12 +4594,12 @@ var getScroll = (function (_ref) {
4596
4594
  shouldUseTimeDampening: shouldUseTimeDampening,
4597
4595
  thresholds: thresholdsHorizontal
4598
4596
  });
4599
- var required = clean$2({
4597
+ var required = clean({
4600
4598
  x: x,
4601
4599
  y: y
4602
4600
  });
4603
4601
 
4604
- if (isEqual(required, origin)) {
4602
+ if (isEqual$1(required, origin)) {
4605
4603
  return null;
4606
4604
  }
4607
4605
 
@@ -4648,7 +4646,7 @@ var getScroll = (function (_ref) {
4648
4646
  }
4649
4647
  }
4650
4648
 
4651
- return isEqual(scroll, origin) ? null : scroll;
4649
+ return isEqual$1(scroll, origin) ? null : scroll;
4652
4650
  });
4653
4651
 
4654
4652
  var smallestSigned = apply(function (value) {
@@ -4681,7 +4679,7 @@ var getOverlap = function () {
4681
4679
  y: getRemainder(targetScroll.y, max.y)
4682
4680
  };
4683
4681
 
4684
- if (isEqual(overlap, origin)) {
4682
+ if (isEqual$1(overlap, origin)) {
4685
4683
  return null;
4686
4684
  }
4687
4685
 
@@ -4780,7 +4778,7 @@ var getWindowScrollChange = (function (_ref) {
4780
4778
  x: viewport.scroll.current.x,
4781
4779
  y: viewport.scroll.current.y
4782
4780
  };
4783
- var scroll = getScroll({
4781
+ var scroll = getScroll$1({
4784
4782
  dragStartTime: dragStartTime,
4785
4783
  container: viewport.frame,
4786
4784
  containerScroll: viewport.scroll,
@@ -4808,7 +4806,7 @@ var getDroppableScrollChange = (function (_ref) {
4808
4806
  return null;
4809
4807
  }
4810
4808
 
4811
- var scroll = getScroll({
4809
+ var scroll = getScroll$1({
4812
4810
  dragStartTime: dragStartTime,
4813
4811
  container: frame.pageMarginBox,
4814
4812
  containerScroll: frame.scroll,
@@ -4821,7 +4819,7 @@ var getDroppableScrollChange = (function (_ref) {
4821
4819
  return scroll && canScrollDroppable(droppable, scroll) ? scroll : null;
4822
4820
  });
4823
4821
 
4824
- var scroll$1 = (function (_ref) {
4822
+ var scroll = (function (_ref) {
4825
4823
  var state = _ref.state,
4826
4824
  dragStartTime = _ref.dragStartTime,
4827
4825
  shouldUseTimeDampening = _ref.shouldUseTimeDampening,
@@ -4890,7 +4888,7 @@ var createFluidScroller = (function (_ref) {
4890
4888
  var _dragging = dragging,
4891
4889
  shouldUseTimeDampening = _dragging.shouldUseTimeDampening,
4892
4890
  dragStartTime = _dragging.dragStartTime;
4893
- scroll$1({
4891
+ scroll({
4894
4892
  state: state,
4895
4893
  scrollWindow: scheduleWindowScroll,
4896
4894
  scrollDroppable: scheduleDroppableScroll,
@@ -4910,7 +4908,7 @@ var createFluidScroller = (function (_ref) {
4910
4908
  wasScrollNeeded = true;
4911
4909
  };
4912
4910
 
4913
- scroll$1({
4911
+ scroll({
4914
4912
  state: state,
4915
4913
  dragStartTime: 0,
4916
4914
  shouldUseTimeDampening: false,
@@ -5067,9 +5065,9 @@ var createAutoScroller = (function (_ref) {
5067
5065
  return scroller;
5068
5066
  });
5069
5067
 
5070
- var prefix$1 = 'data-rbd';
5068
+ var prefix = 'data-rbd';
5071
5069
  var dragHandle = function () {
5072
- var base = prefix$1 + "-drag-handle";
5070
+ var base = prefix + "-drag-handle";
5073
5071
  return {
5074
5072
  base: base,
5075
5073
  draggableId: base + "-draggable-id",
@@ -5077,7 +5075,7 @@ var dragHandle = function () {
5077
5075
  };
5078
5076
  }();
5079
5077
  var draggable = function () {
5080
- var base = prefix$1 + "-draggable";
5078
+ var base = prefix + "-draggable";
5081
5079
  return {
5082
5080
  base: base,
5083
5081
  contextId: base + "-context-id",
@@ -5085,7 +5083,7 @@ var draggable = function () {
5085
5083
  };
5086
5084
  }();
5087
5085
  var droppable = function () {
5088
- var base = prefix$1 + "-droppable";
5086
+ var base = prefix + "-droppable";
5089
5087
  return {
5090
5088
  base: base,
5091
5089
  contextId: base + "-context-id",
@@ -5093,7 +5091,7 @@ var droppable = function () {
5093
5091
  };
5094
5092
  }();
5095
5093
  var scrollContainer = {
5096
- contextId: prefix$1 + "-scroll-container-context-id"
5094
+ contextId: prefix + "-scroll-container-context-id"
5097
5095
  };
5098
5096
 
5099
5097
  var makeGetSelector = function makeGetSelector(context) {
@@ -5166,6 +5164,7 @@ var getStyles$1 = (function (contextId) {
5166
5164
  });
5167
5165
 
5168
5166
  var useIsomorphicLayoutEffect = typeof window !== 'undefined' && typeof window.document !== 'undefined' && typeof window.document.createElement !== 'undefined' ? React.useLayoutEffect : React.useEffect;
5167
+ var useLayoutEffect = useIsomorphicLayoutEffect;
5169
5168
 
5170
5169
  var getHead = function getHead() {
5171
5170
  var head = document.querySelector('head');
@@ -5200,14 +5199,14 @@ function useStyleMarshal(contextId, nonce) {
5200
5199
  !el ? process.env.NODE_ENV !== "production" ? invariant(false, 'Cannot set dynamic style element if it is not set') : invariant(false) : void 0;
5201
5200
  el.textContent = proposed;
5202
5201
  }, []);
5203
- useIsomorphicLayoutEffect(function () {
5202
+ useLayoutEffect(function () {
5204
5203
  !(!alwaysRef.current && !dynamicRef.current) ? process.env.NODE_ENV !== "production" ? invariant(false, 'style elements already mounted') : invariant(false) : void 0;
5205
5204
  var always = createStyleEl(nonce);
5206
5205
  var dynamic = createStyleEl(nonce);
5207
5206
  alwaysRef.current = always;
5208
5207
  dynamicRef.current = dynamic;
5209
- always.setAttribute(prefix$1 + "-always", contextId);
5210
- dynamic.setAttribute(prefix$1 + "-dynamic", contextId);
5208
+ always.setAttribute(prefix + "-always", contextId);
5209
+ dynamic.setAttribute(prefix + "-dynamic", contextId);
5211
5210
  getHead().appendChild(always);
5212
5211
  getHead().appendChild(dynamic);
5213
5212
  setAlwaysStyle(styles.always);
@@ -5350,7 +5349,7 @@ function useFocusMarshal(contextId) {
5350
5349
 
5351
5350
  recordRef.current = id;
5352
5351
  }, []);
5353
- useIsomorphicLayoutEffect(function () {
5352
+ useLayoutEffect(function () {
5354
5353
  isMountedRef.current = true;
5355
5354
  return function clearFrameOnUnmount() {
5356
5355
  isMountedRef.current = false;
@@ -5525,7 +5524,7 @@ function useRegistry() {
5525
5524
  return registry;
5526
5525
  }
5527
5526
 
5528
- var StoreContext = React__default.createContext(null);
5527
+ var StoreContext = React.createContext(null);
5529
5528
 
5530
5529
  var getBodyElement = (function () {
5531
5530
  var body = document.body;
@@ -5544,6 +5543,7 @@ var visuallyHidden = {
5544
5543
  clip: 'rect(0 0 0 0)',
5545
5544
  'clip-path': 'inset(100%)'
5546
5545
  };
5546
+ var visuallyHidden$1 = visuallyHidden;
5547
5547
 
5548
5548
  var getId = function getId(contextId) {
5549
5549
  return "rbd-announcement-" + contextId;
@@ -5560,7 +5560,7 @@ function useAnnouncer(contextId) {
5560
5560
  el.setAttribute('aria-live', 'assertive');
5561
5561
  el.setAttribute('aria-atomic', 'true');
5562
5562
 
5563
- _extends(el.style, visuallyHidden);
5563
+ _extends(el.style, visuallyHidden$1);
5564
5564
 
5565
5565
  getBodyElement().appendChild(el);
5566
5566
  return function cleanup() {
@@ -5590,12 +5590,12 @@ function useAnnouncer(contextId) {
5590
5590
  return announce;
5591
5591
  }
5592
5592
 
5593
- var count = 0;
5593
+ var count$1 = 0;
5594
5594
  var defaults = {
5595
5595
  separator: '::'
5596
5596
  };
5597
- function reset() {
5598
- count = 0;
5597
+ function reset$1() {
5598
+ count$1 = 0;
5599
5599
  }
5600
5600
  function useUniqueId(prefix, options) {
5601
5601
  if (options === void 0) {
@@ -5603,7 +5603,7 @@ function useUniqueId(prefix, options) {
5603
5603
  }
5604
5604
 
5605
5605
  return useMemoOne.useMemo(function () {
5606
- return "" + prefix + options.separator + count++;
5606
+ return "" + prefix + options.separator + count$1++;
5607
5607
  }, [options.separator, prefix]);
5608
5608
  }
5609
5609
 
@@ -5641,7 +5641,7 @@ function useHiddenTextElement(_ref2) {
5641
5641
  return id;
5642
5642
  }
5643
5643
 
5644
- var AppContext = React__default.createContext(null);
5644
+ var AppContext = React.createContext(null);
5645
5645
 
5646
5646
  var peerDependencies = {
5647
5647
  react: "^16.8.5 || ^17.0.0 || ^18.0.0",
@@ -5733,7 +5733,7 @@ function useDevSetupWarning(fn, inputs) {
5733
5733
 
5734
5734
  function useStartupValidation() {
5735
5735
  useDevSetupWarning(function () {
5736
- checkReactVersion(peerDependencies.react, React__default.version);
5736
+ checkReactVersion(peerDependencies.react, React.version);
5737
5737
  checkDoctype(document);
5738
5738
  }, []);
5739
5739
  }
@@ -5822,6 +5822,8 @@ var supportedEventName = function () {
5822
5822
  return supported || base;
5823
5823
  }();
5824
5824
 
5825
+ var supportedPageVisibilityEventName = supportedEventName;
5826
+
5825
5827
  var primaryButton = 0;
5826
5828
  var sloppyClickThreshold = 5;
5827
5829
 
@@ -5946,14 +5948,14 @@ function getCaptureBindings(_ref) {
5946
5948
  event.preventDefault();
5947
5949
  }
5948
5950
  }, {
5949
- eventName: supportedEventName,
5951
+ eventName: supportedPageVisibilityEventName,
5950
5952
  fn: cancel
5951
5953
  }];
5952
5954
  }
5953
5955
 
5954
5956
  function useMouseSensor(api) {
5955
5957
  var phaseRef = React.useRef(idle$1);
5956
- var unbindEventsRef = React.useRef(noop);
5958
+ var unbindEventsRef = React.useRef(noop$2);
5957
5959
  var startCaptureBinding = useMemoOne.useMemo(function () {
5958
5960
  return {
5959
5961
  eventName: 'mousedown',
@@ -6084,7 +6086,7 @@ function useMouseSensor(api) {
6084
6086
  };
6085
6087
  bindCapturingEvents();
6086
6088
  }, [bindCapturingEvents]);
6087
- useIsomorphicLayoutEffect(function mount() {
6089
+ useLayoutEffect(function mount() {
6088
6090
  listenForCapture();
6089
6091
  return function unmount() {
6090
6092
  unbindEventsRef.current();
@@ -6177,7 +6179,7 @@ function getDraggingBindings(actions, stop) {
6177
6179
  passive: true
6178
6180
  }
6179
6181
  }, {
6180
- eventName: supportedEventName,
6182
+ eventName: supportedPageVisibilityEventName,
6181
6183
  fn: cancel
6182
6184
  }];
6183
6185
  }
@@ -6236,7 +6238,7 @@ function useKeyboardSensor(api) {
6236
6238
  };
6237
6239
  unbindEventsRef.current = bindEvents(window, [startCaptureBinding], options);
6238
6240
  }, [startCaptureBinding]);
6239
- useIsomorphicLayoutEffect(function mount() {
6241
+ useLayoutEffect(function mount() {
6240
6242
  listenForCapture();
6241
6243
  return function unmount() {
6242
6244
  unbindEventsRef.current();
@@ -6244,7 +6246,7 @@ function useKeyboardSensor(api) {
6244
6246
  }, [listenForCapture]);
6245
6247
  }
6246
6248
 
6247
- var idle$2 = {
6249
+ var idle = {
6248
6250
  type: 'IDLE'
6249
6251
  };
6250
6252
  var timeForLongPress = 120;
@@ -6279,7 +6281,7 @@ function getWindowBindings(_ref) {
6279
6281
  cancel();
6280
6282
  }
6281
6283
  }, {
6282
- eventName: supportedEventName,
6284
+ eventName: supportedPageVisibilityEventName,
6283
6285
  fn: cancel
6284
6286
  }];
6285
6287
  }
@@ -6379,14 +6381,14 @@ function getHandleBindings(_ref2) {
6379
6381
  event.preventDefault();
6380
6382
  }
6381
6383
  }, {
6382
- eventName: supportedEventName,
6384
+ eventName: supportedPageVisibilityEventName,
6383
6385
  fn: cancel
6384
6386
  }];
6385
6387
  }
6386
6388
 
6387
6389
  function useTouchSensor(api) {
6388
- var phaseRef = React.useRef(idle$2);
6389
- var unbindEventsRef = React.useRef(noop);
6390
+ var phaseRef = React.useRef(idle);
6391
+ var unbindEventsRef = React.useRef(noop$2);
6390
6392
  var getPhase = useMemoOne.useCallback(function getPhase() {
6391
6393
  return phaseRef.current;
6392
6394
  }, []);
@@ -6447,7 +6449,7 @@ function useTouchSensor(api) {
6447
6449
  clearTimeout(current.longPressTimerId);
6448
6450
  }
6449
6451
 
6450
- setPhase(idle$2);
6452
+ setPhase(idle);
6451
6453
  unbindEventsRef.current();
6452
6454
  listenForCapture();
6453
6455
  }, [listenForCapture, setPhase]);
@@ -6504,7 +6506,7 @@ function useTouchSensor(api) {
6504
6506
  });
6505
6507
  bindCapturingEvents(target);
6506
6508
  }, [bindCapturingEvents, getPhase, setPhase, startDragging]);
6507
- useIsomorphicLayoutEffect(function mount() {
6509
+ useLayoutEffect(function mount() {
6508
6510
  listenForCapture();
6509
6511
  return function unmount() {
6510
6512
  unbindEventsRef.current();
@@ -6512,11 +6514,11 @@ function useTouchSensor(api) {
6512
6514
 
6513
6515
  if (phase.type === 'PENDING') {
6514
6516
  clearTimeout(phase.longPressTimerId);
6515
- setPhase(idle$2);
6517
+ setPhase(idle);
6516
6518
  }
6517
6519
  };
6518
6520
  }, [getPhase, listenForCapture, setPhase]);
6519
- useIsomorphicLayoutEffect(function webkitHack() {
6521
+ useLayoutEffect(function webkitHack() {
6520
6522
  var unbind = bindEvents(window, [{
6521
6523
  eventName: 'touchmove',
6522
6524
  fn: function fn() {},
@@ -6617,7 +6619,7 @@ function closestPonyfill(el, selector) {
6617
6619
  return closestPonyfill(el.parentElement, selector);
6618
6620
  }
6619
6621
 
6620
- function closest$1(el, selector) {
6622
+ function closest(el, selector) {
6621
6623
  if (el.closest) {
6622
6624
  return el.closest(selector);
6623
6625
  }
@@ -6638,7 +6640,7 @@ function findClosestDragHandleFromEvent(contextId, event) {
6638
6640
  }
6639
6641
 
6640
6642
  var selector = getSelector(contextId);
6641
- var handle = closest$1(target, selector);
6643
+ var handle = closest(target, selector);
6642
6644
 
6643
6645
  if (!handle) {
6644
6646
  return null;
@@ -6768,7 +6770,7 @@ function tryStart(_ref3) {
6768
6770
  return null;
6769
6771
  }
6770
6772
 
6771
- var lock = lockAPI.claim(forceSensorStop || noop);
6773
+ var lock = lockAPI.claim(forceSensorStop || noop$2);
6772
6774
  var phase = 'PRE_DRAG';
6773
6775
 
6774
6776
  function getShouldRespectForcePress() {
@@ -6792,7 +6794,7 @@ function tryStart(_ref3) {
6792
6794
 
6793
6795
  var tryDispatchWhenDragging = tryDispatch.bind(null, 'DRAGGING');
6794
6796
 
6795
- function lift$1(args) {
6797
+ function lift(args) {
6796
6798
  function completed() {
6797
6799
  lockAPI.release();
6798
6800
  phase = 'COMPLETED';
@@ -6803,7 +6805,7 @@ function tryStart(_ref3) {
6803
6805
  !(phase === 'PRE_DRAG') ? process.env.NODE_ENV !== "production" ? invariant(false, "Cannot lift in phase " + phase) : invariant(false) : void 0;
6804
6806
  }
6805
6807
 
6806
- store.dispatch(lift(args.liftActionArgs));
6808
+ store.dispatch(lift$1(args.liftActionArgs));
6807
6809
  phase = 'DRAGGING';
6808
6810
 
6809
6811
  function finish(reason, options) {
@@ -6829,7 +6831,7 @@ function tryStart(_ref3) {
6829
6831
  }
6830
6832
 
6831
6833
  completed();
6832
- store.dispatch(drop({
6834
+ store.dispatch(drop$1({
6833
6835
  reason: reason
6834
6836
  }));
6835
6837
  }
@@ -6861,7 +6863,7 @@ function tryStart(_ref3) {
6861
6863
  });
6862
6864
  });
6863
6865
  });
6864
- var api = lift$1({
6866
+ var api = lift({
6865
6867
  liftActionArgs: {
6866
6868
  id: draggableId,
6867
6869
  clientSelection: clientSelection,
@@ -6894,13 +6896,13 @@ function tryStart(_ref3) {
6894
6896
  return tryDispatchWhenDragging(moveLeft);
6895
6897
  }
6896
6898
  };
6897
- return lift$1({
6899
+ return lift({
6898
6900
  liftActionArgs: {
6899
6901
  id: draggableId,
6900
6902
  clientSelection: getBorderBoxCenterPosition(el),
6901
6903
  movementMode: 'SNAP'
6902
6904
  },
6903
- cleanup: noop,
6905
+ cleanup: noop$2,
6904
6906
  actions: actions
6905
6907
  });
6906
6908
  }
@@ -6951,7 +6953,7 @@ function useSensorMarshal(_ref4) {
6951
6953
  lockAPI.tryAbandon();
6952
6954
  }
6953
6955
  }, [lockAPI]);
6954
- useIsomorphicLayoutEffect(function listenToStore() {
6956
+ useLayoutEffect(function listenToStore() {
6955
6957
  var previous = store.getState();
6956
6958
  var unsubscribe = store.subscribe(function () {
6957
6959
  var current = store.getState();
@@ -6960,7 +6962,7 @@ function useSensorMarshal(_ref4) {
6960
6962
  });
6961
6963
  return unsubscribe;
6962
6964
  }, [lockAPI, store, tryAbandonLock]);
6963
- useIsomorphicLayoutEffect(function () {
6965
+ useLayoutEffect(function () {
6964
6966
  return lockAPI.tryAbandon;
6965
6967
  }, [lockAPI.tryAbandon]);
6966
6968
  var canGetLock = useMemoOne.useCallback(function (draggableId) {
@@ -7149,33 +7151,33 @@ function App(props) {
7149
7151
  React.useEffect(function () {
7150
7152
  return tryResetStore;
7151
7153
  }, [tryResetStore]);
7152
- return React__default.createElement(AppContext.Provider, {
7154
+ return React.createElement(AppContext.Provider, {
7153
7155
  value: appContext
7154
- }, React__default.createElement(reactRedux.Provider, {
7156
+ }, React.createElement(reactRedux.Provider, {
7155
7157
  context: StoreContext,
7156
7158
  store: store
7157
7159
  }, props.children));
7158
7160
  }
7159
7161
 
7160
- var count$1 = 0;
7161
- function reset$1() {
7162
- count$1 = 0;
7162
+ var count = 0;
7163
+ function reset() {
7164
+ count = 0;
7163
7165
  }
7164
7166
  function useInstanceCount() {
7165
7167
  return useMemoOne.useMemo(function () {
7166
- return "" + count$1++;
7168
+ return "" + count++;
7167
7169
  }, []);
7168
7170
  }
7169
7171
 
7170
7172
  function resetServerContext() {
7171
- reset$1();
7172
7173
  reset();
7174
+ reset$1();
7173
7175
  }
7174
7176
  function DragDropContext(props) {
7175
7177
  var contextId = useInstanceCount();
7176
- var dragHandleUsageInstructions = props.dragHandleUsageInstructions || preset.dragHandleUsageInstructions;
7177
- return React__default.createElement(ErrorBoundary, null, function (setCallbacks) {
7178
- return React__default.createElement(App, {
7178
+ var dragHandleUsageInstructions = props.dragHandleUsageInstructions || preset$1.dragHandleUsageInstructions;
7179
+ return React.createElement(ErrorBoundary, null, function (setCallbacks) {
7180
+ return React.createElement(App, {
7179
7181
  nonce: props.nonce,
7180
7182
  contextId: contextId,
7181
7183
  setCallbacks: setCallbacks,
@@ -7192,15 +7194,15 @@ function DragDropContext(props) {
7192
7194
  });
7193
7195
  }
7194
7196
 
7195
- var isEqual$1 = function isEqual(base) {
7197
+ var isEqual = function isEqual(base) {
7196
7198
  return function (value) {
7197
7199
  return base === value;
7198
7200
  };
7199
7201
  };
7200
7202
 
7201
- var isScroll = isEqual$1('scroll');
7202
- var isAuto = isEqual$1('auto');
7203
- var isVisible$1 = isEqual$1('visible');
7203
+ var isScroll = isEqual('scroll');
7204
+ var isAuto = isEqual('auto');
7205
+ var isVisible = isEqual('visible');
7204
7206
 
7205
7207
  var isEither = function isEither(overflow, fn) {
7206
7208
  return fn(overflow.overflowX) || fn(overflow.overflowY);
@@ -7243,7 +7245,7 @@ var isBodyScrollable = function isBodyScrollable() {
7243
7245
  overflowY: htmlStyle.overflowY
7244
7246
  };
7245
7247
 
7246
- if (isBoth(htmlOverflow, isVisible$1)) {
7248
+ if (isBoth(htmlOverflow, isVisible)) {
7247
7249
  return false;
7248
7250
  }
7249
7251
 
@@ -7271,12 +7273,14 @@ var getClosestScrollable = function getClosestScrollable(el) {
7271
7273
  return el;
7272
7274
  };
7273
7275
 
7276
+ var getClosestScrollable$1 = getClosestScrollable;
7277
+
7274
7278
  var checkForNestedScrollContainers = (function (scrollable) {
7275
7279
  if (!scrollable) {
7276
7280
  return;
7277
7281
  }
7278
7282
 
7279
- var anotherScrollParent = getClosestScrollable(scrollable.parentElement);
7283
+ var anotherScrollParent = getClosestScrollable$1(scrollable.parentElement);
7280
7284
 
7281
7285
  if (!anotherScrollParent) {
7282
7286
  return;
@@ -7285,7 +7289,7 @@ var checkForNestedScrollContainers = (function (scrollable) {
7285
7289
  process.env.NODE_ENV !== "production" ? warning("\n Droppable: unsupported nested scroll container detected.\n A Droppable can only have one scroll parent (which can be itself)\n Nested scroll containers are currently not supported.\n\n We hope to support nested scroll containers soon: https://github.com/atlassian/react-beautiful-dnd/issues/131\n ") : void 0;
7286
7290
  });
7287
7291
 
7288
- var getScroll$1 = (function (el) {
7292
+ var getScroll = (function (el) {
7289
7293
  return {
7290
7294
  x: el.scrollLeft,
7291
7295
  y: el.scrollTop
@@ -7307,7 +7311,7 @@ var getIsFixed = function getIsFixed(el) {
7307
7311
  };
7308
7312
 
7309
7313
  var getEnv = (function (start) {
7310
- var closestScrollable = getClosestScrollable(start);
7314
+ var closestScrollable = getClosestScrollable$1(start);
7311
7315
  var isFixedOnPage = getIsFixed(start);
7312
7316
  return {
7313
7317
  closestScrollable: closestScrollable,
@@ -7407,7 +7411,7 @@ var getClient = function getClient(targetRef, closestScrollable) {
7407
7411
  return client;
7408
7412
  };
7409
7413
 
7410
- var getDimension = (function (_ref) {
7414
+ var getDimension$1 = (function (_ref) {
7411
7415
  var ref = _ref.ref,
7412
7416
  descriptor = _ref.descriptor,
7413
7417
  env = _ref.env,
@@ -7433,7 +7437,7 @@ var getDimension = (function (_ref) {
7433
7437
  return {
7434
7438
  client: frameClient,
7435
7439
  page: cssBoxModel.withScroll(frameClient, windowScroll),
7436
- scroll: getScroll$1(closestScrollable),
7440
+ scroll: getScroll(closestScrollable),
7437
7441
  scrollSize: scrollSize,
7438
7442
  shouldClipSubject: shouldClipSubject
7439
7443
  };
@@ -7504,7 +7508,7 @@ function useDroppablePublisher(args) {
7504
7508
  return origin;
7505
7509
  }
7506
7510
 
7507
- return getScroll$1(dragging.env.closestScrollable);
7511
+ return getScroll(dragging.env.closestScrollable);
7508
7512
  }, []);
7509
7513
  var updateScroll = useMemoOne.useCallback(function () {
7510
7514
  var scroll = getClosestScroll();
@@ -7539,7 +7543,7 @@ function useDroppablePublisher(args) {
7539
7543
  scrollOptions: options
7540
7544
  };
7541
7545
  whileDraggingRef.current = dragging;
7542
- var dimension = getDimension({
7546
+ var dimension = getDimension$1({
7543
7547
  ref: ref,
7544
7548
  descriptor: descriptor,
7545
7549
  env: env,
@@ -7566,7 +7570,7 @@ function useDroppablePublisher(args) {
7566
7570
  var dragging = whileDraggingRef.current;
7567
7571
  var closest = getClosestScrollableFromDrag(dragging);
7568
7572
  !(dragging && closest) ? process.env.NODE_ENV !== "production" ? invariant(false, 'Can only recollect Droppable client for Droppables that have a scroll container') : invariant(false) : void 0;
7569
- return getScroll$1(closest);
7573
+ return getScroll(closest);
7570
7574
  }, []);
7571
7575
  var dragStopped = useMemoOne.useCallback(function () {
7572
7576
  var dragging = whileDraggingRef.current;
@@ -7605,7 +7609,7 @@ function useDroppablePublisher(args) {
7605
7609
  callbacks: callbacks
7606
7610
  };
7607
7611
  }, [callbacks, descriptor, uniqueId]);
7608
- useIsomorphicLayoutEffect(function () {
7612
+ useLayoutEffect(function () {
7609
7613
  publishedDescriptorRef.current = entry.descriptor;
7610
7614
  registry.droppable.register(entry);
7611
7615
  return function () {
@@ -7617,14 +7621,14 @@ function useDroppablePublisher(args) {
7617
7621
  registry.droppable.unregister(entry);
7618
7622
  };
7619
7623
  }, [callbacks, descriptor, dragStopped, entry, marshal, registry.droppable]);
7620
- useIsomorphicLayoutEffect(function () {
7624
+ useLayoutEffect(function () {
7621
7625
  if (!whileDraggingRef.current) {
7622
7626
  return;
7623
7627
  }
7624
7628
 
7625
7629
  marshal.updateDroppableIsEnabled(publishedDescriptorRef.current.id, !args.isDropDisabled);
7626
7630
  }, [args.isDropDisabled, marshal]);
7627
- useIsomorphicLayoutEffect(function () {
7631
+ useLayoutEffect(function () {
7628
7632
  if (!whileDraggingRef.current) {
7629
7633
  return;
7630
7634
  }
@@ -7633,7 +7637,7 @@ function useDroppablePublisher(args) {
7633
7637
  }, [args.isCombineEnabled, marshal]);
7634
7638
  }
7635
7639
 
7636
- function noop$2() {}
7640
+ function noop() {}
7637
7641
 
7638
7642
  var empty = {
7639
7643
  width: 0,
@@ -7661,7 +7665,7 @@ var getSize = function getSize(_ref) {
7661
7665
  };
7662
7666
  };
7663
7667
 
7664
- var getStyle = function getStyle(_ref2) {
7668
+ var getStyle$1 = function getStyle(_ref2) {
7665
7669
  var isAnimatingOpenOnMount = _ref2.isAnimatingOpenOnMount,
7666
7670
  placeholder = _ref2.placeholder,
7667
7671
  animate = _ref2.animate;
@@ -7707,17 +7711,17 @@ function Placeholder(props) {
7707
7711
 
7708
7712
  React.useEffect(function () {
7709
7713
  if (!isAnimatingOpenOnMount) {
7710
- return noop$2;
7714
+ return noop;
7711
7715
  }
7712
7716
 
7713
7717
  if (animate !== 'open') {
7714
7718
  tryClearAnimateOpenTimer();
7715
7719
  setIsAnimatingOpenOnMount(false);
7716
- return noop$2;
7720
+ return noop;
7717
7721
  }
7718
7722
 
7719
7723
  if (animateOpenTimerRef.current) {
7720
- return noop$2;
7724
+ return noop;
7721
7725
  }
7722
7726
 
7723
7727
  animateOpenTimerRef.current = setTimeout(function () {
@@ -7737,12 +7741,12 @@ function Placeholder(props) {
7737
7741
  onClose();
7738
7742
  }
7739
7743
  }, [animate, onClose, onTransitionEnd]);
7740
- var style = getStyle({
7744
+ var style = getStyle$1({
7741
7745
  isAnimatingOpenOnMount: isAnimatingOpenOnMount,
7742
7746
  animate: props.animate,
7743
7747
  placeholder: props.placeholder
7744
7748
  });
7745
- return React__default.createElement(props.placeholder.tagName, {
7749
+ return React.createElement(props.placeholder.tagName, {
7746
7750
  style: style,
7747
7751
  'data-rbd-placeholder-context-id': contextId,
7748
7752
  onTransitionEnd: onSizeChangeEnd,
@@ -7750,9 +7754,9 @@ function Placeholder(props) {
7750
7754
  });
7751
7755
  }
7752
7756
 
7753
- var Placeholder$1 = React__default.memo(Placeholder);
7757
+ var Placeholder$1 = React.memo(Placeholder);
7754
7758
 
7755
- var DroppableContext = React__default.createContext(null);
7759
+ var DroppableContext = React.createContext(null);
7756
7760
 
7757
7761
  function checkIsValidInnerRef(el) {
7758
7762
  !(el && isHtmlElement(el)) ? process.env.NODE_ENV !== "production" ? invariant(false, "\n provided.innerRef has not been provided with a HTMLElement.\n\n You can find a guide on using the innerRef callback functions at:\n https://github.com/atlassian/react-beautiful-dnd/blob/master/docs/guides/using-inner-ref.md\n ") : invariant(false) : void 0;
@@ -7804,7 +7808,7 @@ var virtual = [function hasClone(_ref5) {
7804
7808
  var getPlaceholderRef = _ref6.getPlaceholderRef;
7805
7809
  !!getPlaceholderRef() ? process.env.NODE_ENV !== "production" ? invariant(false, 'Expected virtual list to not have a placeholder') : invariant(false) : void 0;
7806
7810
  }];
7807
- function useValidation(args) {
7811
+ function useValidation$1(args) {
7808
7812
  useDevSetupWarning(function () {
7809
7813
  runChecks(args, shared);
7810
7814
 
@@ -7896,7 +7900,7 @@ var AnimateInOut = function (_React$PureComponent) {
7896
7900
  };
7897
7901
 
7898
7902
  return AnimateInOut;
7899
- }(React__default.PureComponent);
7903
+ }(React.PureComponent);
7900
7904
 
7901
7905
  var zIndexOptions = {
7902
7906
  dragging: 5000,
@@ -7964,11 +7968,11 @@ function getSecondaryStyle(secondary) {
7964
7968
  };
7965
7969
  }
7966
7970
 
7967
- function getStyle$1(mapped) {
7971
+ function getStyle(mapped) {
7968
7972
  return mapped.type === 'DRAGGING' ? getDraggingStyle(mapped) : getSecondaryStyle(mapped);
7969
7973
  }
7970
7974
 
7971
- function getDimension$1(descriptor, el, windowScroll) {
7975
+ function getDimension(descriptor, el, windowScroll) {
7972
7976
  if (windowScroll === void 0) {
7973
7977
  windowScroll = origin;
7974
7978
  }
@@ -8011,28 +8015,28 @@ function useDraggablePublisher(args) {
8011
8015
  isEnabled: isEnabled
8012
8016
  };
8013
8017
  }, [canDragInteractiveElements, isEnabled, shouldRespectForcePress]);
8014
- var getDimension = useMemoOne.useCallback(function (windowScroll) {
8018
+ var getDimension$1 = useMemoOne.useCallback(function (windowScroll) {
8015
8019
  var el = getDraggableRef();
8016
8020
  !el ? process.env.NODE_ENV !== "production" ? invariant(false, 'Cannot get dimension when no ref is set') : invariant(false) : void 0;
8017
- return getDimension$1(descriptor, el, windowScroll);
8021
+ return getDimension(descriptor, el, windowScroll);
8018
8022
  }, [descriptor, getDraggableRef]);
8019
8023
  var entry = useMemoOne.useMemo(function () {
8020
8024
  return {
8021
8025
  uniqueId: uniqueId,
8022
8026
  descriptor: descriptor,
8023
8027
  options: options,
8024
- getDimension: getDimension
8028
+ getDimension: getDimension$1
8025
8029
  };
8026
- }, [descriptor, getDimension, options, uniqueId]);
8030
+ }, [descriptor, getDimension$1, options, uniqueId]);
8027
8031
  var publishedRef = React.useRef(entry);
8028
8032
  var isFirstPublishRef = React.useRef(true);
8029
- useIsomorphicLayoutEffect(function () {
8033
+ useLayoutEffect(function () {
8030
8034
  registry.draggable.register(publishedRef.current);
8031
8035
  return function () {
8032
8036
  return registry.draggable.unregister(publishedRef.current);
8033
8037
  };
8034
8038
  }, [registry.draggable]);
8035
- useIsomorphicLayoutEffect(function () {
8039
+ useLayoutEffect(function () {
8036
8040
  if (isFirstPublishRef.current) {
8037
8041
  isFirstPublishRef.current = false;
8038
8042
  return;
@@ -8044,7 +8048,7 @@ function useDraggablePublisher(args) {
8044
8048
  }, [entry, registry.draggable]);
8045
8049
  }
8046
8050
 
8047
- function useValidation$1(props, contextId, getRef) {
8051
+ function useValidation(props, contextId, getRef) {
8048
8052
  useDevSetupWarning(function () {
8049
8053
  function prefix(id) {
8050
8054
  return "Draggable[id: " + id + "]: ";
@@ -8113,7 +8117,7 @@ function Draggable(props) {
8113
8117
  isClone = props.isClone,
8114
8118
  mapped = props.mapped,
8115
8119
  dropAnimationFinishedAction = props.dropAnimationFinished;
8116
- useValidation$1(props, contextId, getRef);
8120
+ useValidation(props, contextId, getRef);
8117
8121
  useClonePropValidation(isClone);
8118
8122
 
8119
8123
  if (!isClone) {
@@ -8157,7 +8161,7 @@ function Draggable(props) {
8157
8161
  dropAnimationFinishedAction();
8158
8162
  }, [dropAnimationFinishedAction, mapped]);
8159
8163
  var provided = useMemoOne.useMemo(function () {
8160
- var style = getStyle$1(mapped);
8164
+ var style = getStyle(mapped);
8161
8165
  var onTransitionEnd = mapped.type === 'DRAGGING' && mapped.dropping ? onMoveEnd : null;
8162
8166
  var result = {
8163
8167
  innerRef: setRef,
@@ -8412,7 +8416,7 @@ function getSecondarySelector() {
8412
8416
  return selector;
8413
8417
  }
8414
8418
 
8415
- var makeMapStateToProps = function makeMapStateToProps() {
8419
+ var makeMapStateToProps$1 = function makeMapStateToProps() {
8416
8420
  var draggingSelector = getDraggableSelector();
8417
8421
  var secondarySelector = getSecondarySelector();
8418
8422
 
@@ -8422,14 +8426,15 @@ var makeMapStateToProps = function makeMapStateToProps() {
8422
8426
 
8423
8427
  return selector;
8424
8428
  };
8425
- var mapDispatchToProps = {
8429
+ var mapDispatchToProps$1 = {
8426
8430
  dropAnimationFinished: dropAnimationFinished
8427
8431
  };
8428
- var ConnectedDraggable = reactRedux.connect(makeMapStateToProps, mapDispatchToProps, null, {
8432
+ var ConnectedDraggable = reactRedux.connect(makeMapStateToProps$1, mapDispatchToProps$1, null, {
8429
8433
  context: StoreContext,
8430
8434
  pure: true,
8431
8435
  areStatePropsEqual: isStrictEqual
8432
8436
  })(Draggable);
8437
+ var ConnectedDraggable$1 = ConnectedDraggable;
8433
8438
 
8434
8439
  function PrivateDraggable(props) {
8435
8440
  var droppableContext = useRequiredContext(DroppableContext);
@@ -8439,13 +8444,13 @@ function PrivateDraggable(props) {
8439
8444
  return null;
8440
8445
  }
8441
8446
 
8442
- return React__default.createElement(ConnectedDraggable, props);
8447
+ return React.createElement(ConnectedDraggable$1, props);
8443
8448
  }
8444
8449
  function PublicDraggable(props) {
8445
8450
  var isEnabled = typeof props.isDragDisabled === 'boolean' ? !props.isDragDisabled : true;
8446
8451
  var canDragInteractiveElements = Boolean(props.disableInteractiveElementBlocking);
8447
8452
  var shouldRespectForcePress = Boolean(props.shouldRespectForcePress);
8448
- return React__default.createElement(PrivateDraggable, _extends({}, props, {
8453
+ return React.createElement(PrivateDraggable, _extends({}, props, {
8449
8454
  isClone: false,
8450
8455
  isEnabled: isEnabled,
8451
8456
  canDragInteractiveElements: canDragInteractiveElements,
@@ -8484,7 +8489,7 @@ function Droppable(props) {
8484
8489
  var setPlaceholderRef = useMemoOne.useCallback(function (value) {
8485
8490
  placeholderRef.current = value;
8486
8491
  }, []);
8487
- useValidation({
8492
+ useValidation$1({
8488
8493
  props: props,
8489
8494
  getDroppableRef: getDroppableRef,
8490
8495
  getPlaceholderRef: getPlaceholderRef
@@ -8506,14 +8511,14 @@ function Droppable(props) {
8506
8511
  ignoreContainerClipping: ignoreContainerClipping,
8507
8512
  getDroppableRef: getDroppableRef
8508
8513
  });
8509
- var placeholder = React__default.createElement(AnimateInOut, {
8514
+ var placeholder = React.createElement(AnimateInOut, {
8510
8515
  on: props.placeholder,
8511
8516
  shouldAnimate: props.shouldAnimatePlaceholder
8512
8517
  }, function (_ref) {
8513
8518
  var onClose = _ref.onClose,
8514
8519
  data = _ref.data,
8515
8520
  animate = _ref.animate;
8516
- return React__default.createElement(Placeholder$1, {
8521
+ return React.createElement(Placeholder$1, {
8517
8522
  placeholder: data,
8518
8523
  onClose: onClose,
8519
8524
  innerRef: setPlaceholderRef,
@@ -8548,7 +8553,7 @@ function Droppable(props) {
8548
8553
 
8549
8554
  var dragging = useClone.dragging,
8550
8555
  render = useClone.render;
8551
- var node = React__default.createElement(PrivateDraggable, {
8556
+ var node = React.createElement(PrivateDraggable, {
8552
8557
  draggableId: dragging.draggableId,
8553
8558
  index: dragging.source.index,
8554
8559
  isClone: true,
@@ -8561,11 +8566,43 @@ function Droppable(props) {
8561
8566
  return ReactDOM.createPortal(node, getContainerForClone());
8562
8567
  }
8563
8568
 
8564
- return React__default.createElement(DroppableContext.Provider, {
8569
+ return React.createElement(DroppableContext.Provider, {
8565
8570
  value: droppableContext
8566
8571
  }, children(provided, snapshot), getClone());
8567
8572
  }
8568
8573
 
8574
+ function getBody() {
8575
+ !document.body ? process.env.NODE_ENV !== "production" ? invariant(false, 'document.body is not ready') : invariant(false) : void 0;
8576
+ return document.body;
8577
+ }
8578
+
8579
+ var defaultProps = {
8580
+ mode: 'standard',
8581
+ type: 'DEFAULT',
8582
+ direction: 'vertical',
8583
+ isDropDisabled: false,
8584
+ isCombineEnabled: false,
8585
+ ignoreContainerClipping: false,
8586
+ renderClone: null,
8587
+ getContainerForClone: getBody
8588
+ };
8589
+
8590
+ var attachDefaultPropsToOwnProps = function attachDefaultPropsToOwnProps(ownProps) {
8591
+ var mergedProps = _extends({}, ownProps);
8592
+
8593
+ var defaultPropKey;
8594
+
8595
+ for (defaultPropKey in defaultProps) {
8596
+ if (ownProps[defaultPropKey] === undefined) {
8597
+ var _extends2;
8598
+
8599
+ mergedProps = _extends({}, mergedProps, (_extends2 = {}, _extends2[defaultPropKey] = defaultProps[defaultPropKey], _extends2));
8600
+ }
8601
+ }
8602
+
8603
+ return mergedProps;
8604
+ };
8605
+
8569
8606
  var isMatchingType = function isMatchingType(type, critical) {
8570
8607
  return type === critical.droppable.type;
8571
8608
  };
@@ -8574,7 +8611,7 @@ var getDraggable = function getDraggable(critical, dimensions) {
8574
8611
  return dimensions.draggables[critical.draggable.id];
8575
8612
  };
8576
8613
 
8577
- var makeMapStateToProps$1 = function makeMapStateToProps() {
8614
+ var makeMapStateToProps = function makeMapStateToProps() {
8578
8615
  var idleWithAnimation = {
8579
8616
  placeholder: null,
8580
8617
  shouldAnimatePlaceholder: true,
@@ -8647,10 +8684,11 @@ var makeMapStateToProps$1 = function makeMapStateToProps() {
8647
8684
  });
8648
8685
 
8649
8686
  var selector = function selector(state, ownProps) {
8650
- var id = ownProps.droppableId;
8651
- var type = ownProps.type;
8652
- var isEnabled = !ownProps.isDropDisabled;
8653
- var renderClone = ownProps.renderClone;
8687
+ var ownPropsWithDefaultProps = attachDefaultPropsToOwnProps(ownProps);
8688
+ var id = ownPropsWithDefaultProps.droppableId;
8689
+ var type = ownPropsWithDefaultProps.type;
8690
+ var isEnabled = !ownPropsWithDefaultProps.isDropDisabled;
8691
+ var renderClone = ownPropsWithDefaultProps.renderClone;
8654
8692
 
8655
8693
  if (state.isDragging) {
8656
8694
  var critical = state.critical;
@@ -8703,35 +8741,21 @@ var makeMapStateToProps$1 = function makeMapStateToProps() {
8703
8741
 
8704
8742
  return selector;
8705
8743
  };
8706
- var mapDispatchToProps$1 = {
8744
+ var mapDispatchToProps = {
8707
8745
  updateViewportMaxScroll: updateViewportMaxScroll
8708
8746
  };
8709
-
8710
- function getBody() {
8711
- !document.body ? process.env.NODE_ENV !== "production" ? invariant(false, 'document.body is not ready') : invariant(false) : void 0;
8712
- return document.body;
8713
- }
8714
-
8715
- var defaultProps = {
8716
- mode: 'standard',
8717
- type: 'DEFAULT',
8718
- direction: 'vertical',
8719
- isDropDisabled: false,
8720
- isCombineEnabled: false,
8721
- ignoreContainerClipping: false,
8722
- renderClone: null,
8723
- getContainerForClone: getBody
8724
- };
8725
- var ConnectedDroppable = reactRedux.connect(makeMapStateToProps$1, mapDispatchToProps$1, null, {
8747
+ var ConnectedDroppable = reactRedux.connect(makeMapStateToProps, mapDispatchToProps, function (stateProps, dispatchProps, ownProps) {
8748
+ return _extends({}, attachDefaultPropsToOwnProps(ownProps), {}, stateProps, {}, dispatchProps);
8749
+ }, {
8726
8750
  context: StoreContext,
8727
8751
  pure: true,
8728
8752
  areStatePropsEqual: isStrictEqual
8729
8753
  })(Droppable);
8730
- ConnectedDroppable.defaultProps = defaultProps;
8754
+ var ConnectedDroppable$1 = ConnectedDroppable;
8731
8755
 
8732
8756
  exports.DragDropContext = DragDropContext;
8733
8757
  exports.Draggable = PublicDraggable;
8734
- exports.Droppable = ConnectedDroppable;
8758
+ exports.Droppable = ConnectedDroppable$1;
8735
8759
  exports.resetServerContext = resetServerContext;
8736
8760
  exports.useKeyboardSensor = useKeyboardSensor;
8737
8761
  exports.useMouseSensor = useMouseSensor;