"use strict";Liferay.Loader.define("@liferay!analytics-settings-web$testing-library/react@12.1.2/dist/act-compat",["module","exports","require","@liferay!analytics-settings-web$babel/runtime/helpers/interopRequireDefault","liferay!frontend-js-react-web$react","liferay!frontend-js-react-web$react-dom","liferay!frontend-js-react-web$react-dom/test-utils"],(function(e,t,r){window;{var n=r("@liferay!analytics-settings-web$babel/runtime/helpers/interopRequireDefault");Object.defineProperty(t,"__esModule",{value:!0}),t.asyncAct=function asyncAct(t){if(!0===l){if(null===u)return new Promise(((r,n)=>{const a=console.error;let o,i;console.error=function error(...e){const t="string"==typeof e[0];t&&0===e[0].indexOf("Warning: Do not await the result of calling ReactTestUtils.act")?u=!1:t&&0===e[0].indexOf("Warning: The callback passed to ReactTestUtils.act(...) function must not return anything")||a.apply(console,e)};try{i=e((()=>(o=t(),o)))}catch(e){return console.error=a,void n(e)}i.then((()=>{console.error=a,u=!0,r()}),(e=>{console.error=a,u=!0,n(e)})),!1===u&&(console.error=a,s||(console.error('It looks like you\'re using a version of react-dom that supports the "act" function, but not an awaitable version of "act" which you will need. Please upgrade to at least react-dom@16.9.0 to remove this warning.'),s=!0),o.then((()=>{Promise.resolve().then((()=>{c((()=>{})),r()}))}),n))}));if(!1===u){let e;return c((()=>{e=t()})),e.then((()=>Promise.resolve().then((()=>{c((()=>{}))}))))}return c(t)}let r;return c((()=>{r=t()})),r.then((()=>Promise.resolve().then((()=>{c((()=>{}))}))))},t.default=void 0;var a=_interopRequireWildcard(r("liferay!frontend-js-react-web$react")),o=n(r("liferay!frontend-js-react-web$react-dom"));function _getRequireWildcardCache(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,r=new WeakMap;return(_getRequireWildcardCache=function(e){return e?r:t})(e)}function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var r=_getRequireWildcardCache(t);if(r&&r.has(e))return r.get(e);var n={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&Object.prototype.hasOwnProperty.call(e,o)){var i=a?Object.getOwnPropertyDescriptor(e,o):null;i&&(i.get||i.set)?Object.defineProperty(n,o,i):n[o]=e[o]}return n.default=e,r&&r.set(e,n),n}const e=_interopRequireWildcard(r("liferay!frontend-js-react-web$react-dom/test-utils")).act,l=void 0!==e;const c=e||function actPolyfill(e){o.default.unstable_batchedUpdates(e),o.default.render(a.createElement("div",null),document.createElement("div"))};let s=!1,u=null;var i=c;t.default=i}}));
//# sourceMappingURL=act-compat.js.map