"use strict";exports.__esModule=!0,exports.default=alert;var _invoker=_interopRequireWildcard(require("./invoker"));function _getRequireWildcardCache(e){if("function"!=typeof WeakMap)return null;var r=new WeakMap,t=new WeakMap;return(_getRequireWildcardCache=function(e){return e?t: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 t=_getRequireWildcardCache(r);if(t&&t.has(e))return t.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,t&&t.set(e,n),n}function alertHandler(e,r){var t=r.resolve,n=r.reject,a=r.context,o=r.containerType,i=r.appType,l=r.platformType;if(o){var u=function(e){_invoker.default.handleBridgeResponse(e,t,n)},c=function(e){_invoker.default.handleBridgeResponse(e,t,n)};i===_invoker.API_INVOKER_TYPE.MINI_APP?a&&a({m:"taurus.common.alert",args:e,onSuccess:u,onFail:c}):l===_invoker.PLATFORM_TYPE_ENUM.ANDROID?a&&a(u,c,"taurus.common","alert",e):l===_invoker.PLATFORM_TYPE_ENUM.IOS&&a.callHandler("taurus.common.alert",Object.assign({},e),(function(e){t(e)}))}else a&&a.call("alert",e,(function(){t()}))}function alert(e){return _invoker.default.invoke("alert",e)}_invoker.default.registerAPI("alert",{mini:alertHandler,mobile:alertHandler}),alert.version={android:"1.3.2",ios:"1.3.2"},module.exports=exports.default,module.exports.default=exports.default;