Liferay.Loader.define("@liferay/layout-content-page-editor-web@3.0.132/page_editor/app/thunks/undo",["module","exports","require","../actions/types","../components/undo/undoActions"],(function(e,t,r){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({store:t}){return r=>{if(!t.undoHistory||!t.undoHistory.length)return;const[i,...u]=t.undoHistory||[];r({type:n.UPDATE_UNDO_ACTIONS,undoHistory:u});const s=e=>r(c(c({},e),{},{isUndo:!0,originalType:i.originalType||i.type}));e=e.then((()=>(0,o.undoAction)({action:i,store:t})(s,(()=>t))))}};var n=r("../actions/types"),o=r("../components/undo/undoActions");function i(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?i(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let e=Promise.resolve()}}));
//# sourceMappingURL=undo.js.map