function hookNavigation(){if(global.__minium__.navigationHooked)return!0;global.__minium__.navigationHooked=!0;const e="global",a=Object.defineProperties;function o(e){switch(e){case"navigateTo_before_global":return"function"==typeof navigateTo_before_global?navigateTo_before_global:void 0;case"redirectTo_before_global":return"function"==typeof redirectTo_before_global?redirectTo_before_global:void 0;case"switchTab_before_global":return"function"==typeof switchTab_before_global?switchTab_before_global:void 0;case"navigateBack_before_global":return"function"==typeof navigateBack_before_global?navigateBack_before_global:void 0;case"reLaunch_before_global":return"function"==typeof reLaunch_before_global?reLaunch_before_global:void 0;default:return}}function t(e){const a=o(e);return a||function(){const a=o(e);return a&&a(...arguments)}}global.__minium__.getRealBindingMethod=o,global.__minium__.getBindingMethod=t;["navigateTo","redirectTo","switchTab","navigateBack","reLaunch"].forEach((a=>{global.__minium__.setCall(a,e,{before:t(`${a}_before_${e}`)})})),wx.onAppRouteDone((function(){const o=getCurrentPages().pop();o&&function(o,r){if(!o||!0===o.__page_router_rewrited__)return;const n={navigateTo:o.navigateTo,redirectTo:o.redirectTo,switchTab:o.switchTab,navigateBack:o.navigateBack,reLaunch:o.reLaunch};a(o,{__page_router_rewrited__:{value:!0,writable:!0},navigateTo:{value(a={}){const i=t(`navigateTo_before_${e}`);return i&&i(Object.assign({oriPath:r},a)),n.navigateTo.call(o,a)},writable:!0},redirectTo:{value(a={}){const i=t(`redirectTo_before_${e}`);return i&&i(Object.assign({oriPath:r},a)),n.redirectTo.call(o,a)},writable:!0},switchTab:{value(a={}){const i=t(`switchTab_before_${e}`);return i&&i(Object.assign({oriPath:r},a)),n.switchTab.call(o,a)},writable:!0},navigateBack:{value(a={}){const r=t(`navigateBack_before_${e}`);return r&&r(a),n.navigateBack.call(o,a)},writable:!0},reLaunch:{value(a={}){const i=t(`reLaunch_before_${e}`);return i&&i(Object.assign({oriPath:r},a)),n.reLaunch.call(o,a)},writable:!0}}),console.warn("hook pageRouter succ")}(o.pageRouter,o.route||o.__route__)}))}
