"use strict";

exports.__esModule = true;
exports.TableDragAndDrop = void 0;
exports.setStateObject = setStateObject;
var _TableDragAndDropContext = require("./TableDragAndDropContext");
var _dragAndDrop = require("@wix/wix-style-react-incubator/drag-and-drop");
var _minimalRequiredWdsRuntimeCheck = require("../minimalRequiredWdsRuntimeCheck");
var _TableDragAndDropState = require("./DragAndDrop/TableDragAndDropState");
if (process.env.NODE_ENV !== 'production') {
  (0, _minimalRequiredWdsRuntimeCheck.minimalRequiredWdsRuntimeCheck)({
    required: '^1.64.1',
    requiredBy: 'WixPatterns/TableDragAndDrop'
  });
}
function setStateObject({
  state,
  modalsContainerRef
}) {
  state.tableDragAndDropState ?? (state.tableDragAndDropState = new _TableDragAndDropState.TableDragAndDropState({
    tableState: state,
    modalsContainerRef
  }));
  state.toolbar._dnd = state.tableDragAndDropState.dnd;
}
const TableDragAndDrop = exports.TableDragAndDrop = {
  ..._dragAndDrop.TableDragAndDrop,
  TableDragAndDropContext: _TableDragAndDropContext.TableDragAndDropContext,
  setStateObject
};
//# sourceMappingURL=TableDragAndDrop.js.map