!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):e.uni=n()}(this,function(){"use strict";var e={},a=[],n=function(e,n){if(0===a.length){var i=plus.webview.currentWebview();if(!i)throw new Error("plus.webview.currentWebview() is undefined");var t=i.parent();if(!t)throw new Error("plus.webview.currentWebview().parent() is undefined");a.push(t.id)}var r=JSON.stringify({options:{timestamp:+new Date},name:e,arg:n});plus.webview.getLaunchWebview().evalJS('UniPlusBridge.subscribeHandler("WEB_INVOKE_APPSERVICE",'+r+","+JSON.stringify(a)+");")};e.navigateTo=function(){var e=(0