"use strict";exports.__esModule=!0,exports.default=showLoading;var _invoker=_interopRequireWildcard(require("./invoker"));function _getRequireWildcardCache(e){if("function"!=typeof WeakMap)return null;var r=new WeakMap,o=new WeakMap;return(_getRequireWildcardCache=function(e){return e?o:r})(e)}function _interopRequireWildcard(e,r){if(!r&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var o=_getRequireWildcardCache(r);if(o&&o.has(e))return o.get(e);var n={},t=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var a=t?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(n,i,a):n[i]=e[i]}return n.default=e,o&&o.set(e,n),n}function showLoadingMenuHandler(e,r){var o=r.resolve,n=r.reject,t=r.context,i=r.containerType,a=r.appType,d=r.platformType;if(i){var u=function(e){_invoker.default.handleBridgeResponse(e,o,n)},l=function(e){_invoker.default.handleBridgeResponse(e,o,n)};a===_invoker.API_INVOKER_TYPE.MINI_APP?t&&t({m:"device.notification.showPreloader",args:e,onSuccess:u,onFail:l}):d===_invoker.PLATFORM_TYPE_ENUM.ANDROID?t&&t(u,l,"device.notification","showPreloader",e):d===_invoker.PLATFORM_TYPE_ENUM.IOS&&t.callHandler("device.notification.showPreloader",Object.assign({},e),(function(e){o(e)}))}else t&&t.call("showLoading",e,(function(){o()}))}function showLoading(e){return _invoker.default.invoke("showLoading",e)}_invoker.default.registerAPI("showLoading",{mini:showLoadingMenuHandler,mobile:showLoadingMenuHandler}),showLoading.version={android:"1.3.2",ios:"1.3.2"},module.exports=exports.default,module.exports.default=exports.default;