Liferay.Loader.define("data-engine-taglib@3.3.26/data_layout_builder/js/drag-and-drop/DragLayer.es",["module","exports","require","liferay!frontend-js-react-web$react","liferay!frontend-js-react-web$react-dnd"],(function(e,t,r){var n;window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=(n=r("liferay!frontend-js-react-web$react"))&&n.__esModule?n:{default:n},a=r("liferay!frontend-js-react-web$react-dnd");function o(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?o(Object(r),!0).forEach((function(t){f(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function f(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const e={cursor:"grabbing",height:"100%",left:0,pointerEvents:"none",position:"fixed",top:0,width:"100%",zIndex:150};function s(e,t){if(!e||!t)return{display:"none"};const{x:r,y:n}=t,i="translate(".concat(r,"px, ").concat(n,"px)");return{WebkitTransform:i,transform:i}}var l=()=>{const{currentOffset:t,initialOffset:r,isDragging:n,item:o}=(0,a.useDragLayer)((e=>({currentOffset:e.getSourceClientOffset(),initialOffset:e.getInitialSourceClientOffset(),isDragging:e.isDragging(),item:e.getItem(),itemType:e.getItemType()})));if(!n)return null;const{preview:f}=o;return i.default.createElement("div",{style:c(c({},e),{},{zIndex:200})},i.default.createElement("div",{style:s(r,t)},f&&f()))};t.default=l}}));
//# sourceMappingURL=DragLayer.es.js.map