PageSourceSearch

https://zeromanual.ai/8975/bundles/plugin/urlForwarding/urlForwarding.plugin.js

js zeromanual.ai collected 2026-10-05 13:32:09 UTC 14,768 bytes, 1 lines download raw bytes

1(function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId]){return installedModules[moduleId].exports}var module=installedModules[moduleId]={i:moduleId,l:false,exports:{}};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.l=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.d=function(exports,name,getter){if(!__webpack_require__.o(exports,name)){Object.defineProperty(exports,name,{enumerable:true,get:getter})}};__webpack_require__.r=function(exports){if(typeof Symbol!=="undefined"&&Symbol.toStringTag){Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"})}Object.defineProperty(exports,"__esModule",{value:true})};__webpack_require__.t=function(value,mode){if(mode&1)value=__webpack_require__(value);if(mode&8)return value;if(mode&4&&typeof value==="object"&&value&&value.__esModule)return value;var ns=Object.create(null);__webpack_require__.r(ns);Object.defineProperty(ns,"default",{enumerable:true,value:value});if(mode&2&&typeof value!="string")for(var key in value)__webpack_require__.d(ns,key,function(key){return value[key]}.bind(null,key));return ns};__webpack_require__.n=function(module){var getter=module&&module.__esModule?function getDefault(){return module["default"]}:function getModuleExports(){return module};__webpack_require__.d(getter,"a",getter);return getter};__webpack_require__.o=function(object,property){return Object.prototype.hasOwnProperty.call(object,property)};__webpack_require__.p="";return __webpack_require__(__webpack_require__.s=2)})([function(module,exports,__webpack_require__){(function(process){function normalizeArray(parts,allowAboveRoot){var up=0;for(var i=parts.length-1;i>=0;i--){var last=parts[i];if(last==="."){parts.splice(i,1)}else if(last===".."){parts.splice(i,1);up++}else if(up){parts.splice(i,1);up--}}if(allowAboveRoot){for(;up--;up){parts.unshift("..")}}return parts}exports.resolve=function(){var resolvedPath="",resolvedAbsolute=false;for(var i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:process.cwd();if(typeof path!=="string"){throw new TypeError("Arguments to path.resolve must be strings")}else if(!path){continue}resolvedPath=path+"/"+resolvedPath;resolvedAbsolute=path.charAt(0)==="/"}resolvedPath=normalizeArray(filter(resolvedPath.split("/"),(function(p){return!!p})),!resolvedAbsolute).join("/");return(resolvedAbsolute?"/":"")+resolvedPath||"."};exports.normalize=function(path){var isAbsolute=exports.isAbsolute(path),trailingSlash=substr(path,-1)==="/";path=normalizeArray(filter(path.split("/"),(function(p){return!!p})),!isAbsolute).join("/");if(!path&&!isAbsolute){path="."}if(path&&trailingSlash){path+="/"}return(isAbsolute?"/":"")+path};exports.isAbsolute=function(path){return path.charAt(0)==="/"};exports.join=function(){var paths=Array.prototype.slice.call(arguments,0);return exports.normalize(filter(paths,(function(p,index){if(typeof p!=="string"){throw new TypeError("Arguments to path.join must be strings")}return p})).join("/"))};exports.relative=function(from,to){from=exports.resolve(from).substr(1);to=exports.resolve(to).substr(1);function trim(arr){var start=0;for(;start<arr.length;start++){if(arr[start]!=="")break}var end=arr.length-1;for(;end>=0;end--){if(arr[end]!=="")break}if(start>end)return[];return arr.slice(start,end-start+1)}var fromParts=trim(from.split("/"));var toParts=trim(to.split("/"));var length=Math.min(fromParts.length,toParts.length);var samePartsLength=length;for(var i=0;i<length;i++){if(fromParts[i]!==toParts[i]){samePartsLength=i;break}}var outputParts=[];for(var i=samePartsLength;i<fromParts.length;i++){outputParts.push("..")}outputParts=outputParts.concat(toParts.slice(samePartsLength));return outputParts.join("/")};exports.sep="/";exports.delimiter=":";exports.dirname=function(path){if(typeof path!=="string")path=path+"";if(path.length===0)return".";var code=path.charCodeAt(0);var hasRoot=code===47;var end=-1;var matchedSlash=true;for(var i=path.length-1;i>=1;--i){code=path.charCodeAt(i);if(code===47){if(!matchedSlash){end=i;break}}else{matchedSlash=false}}if(end===-1)return hasRoot?"/":".";if(hasRoot&&end===1){return"/"}return path.slice(0,end)};
1function basename(path){if(typeof path!=="string")path=path+"";var start=0;var end=-1;var matchedSlash=true;var i;for(i=path.length-1;i>=0;--i){if(path.charCodeAt(i)===47){if(!matchedSlash){start=i+1;break}}else if(end===-1){matchedSlash=false;end=i+1}}if(end===-1)return"";return path.slice(start,end)}exports.basename=function(path,ext){var f=basename(path);if(ext&&f.substr(-1*ext.length)===ext){f=f.substr(0,f.length-ext.length)}return f};exports.extname=function(path){if(typeof path!=="string")path=path+"";var startDot=-1;var startPart=0;var end=-1;var matchedSlash=true;var preDotState=0;for(var i=path.length-1;i>=0;--i){var code=path.charCodeAt(i);if(code===47){if(!matchedSlash){startPart=i+1;break}continue}if(end===-1){matchedSlash=false;end=i+1}if(code===46){if(startDot===-1)startDot=i;else if(preDotState!==1)preDotState=1}else if(startDot!==-1){preDotState=-1}}if(startDot===-1||end===-1||preDotState===0||preDotState===1&&startDot===end-1&&startDot===startPart+1){return""}return path.slice(startDot,end)};function filter(xs,f){if(xs.filter)return xs.filter(f);var res=[];for(var i=0;i<xs.length;i++){if(f(xs[i],i,xs))res.push(xs[i])}return res}var substr="ab".substr(-1)==="b"?function(str,start,len){return str.substr(start,len)}:function(str,start,len){if(start<0)start=str.length+start;return str.substr(start,len)}}).call(this,__webpack_require__(4))},function(module,__webpack_exports__,__webpack_require__){__webpack_require__.r(__webpack_exports__);var ns=__osdBundles__.get("entry/core/public");Object.defineProperties(__webpack_exports__,Object.getOwnPropertyDescriptors(ns))},function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__);var _node_modules_val_loader_dist_cjs_js_key_urlForwarding_osd_ui_shared_deps_public_path_module_creator_js__WEBPACK_IMPORTED_MODULE_0__=__webpack_require__(3);var _node_modules_val_loader_dist_cjs_js_key_urlForwarding_osd_ui_shared_deps_public_path_module_creator_js__WEBPACK_IMPORTED_MODULE_0___default=__webpack_require__.n(_node_modules_val_loader_dist_cjs_js_key_urlForwarding_osd_ui_shared_deps_public_path_module_creator_js__WEBPACK_IMPORTED_MODULE_0__);__osdBundles__.define("plugin/urlForwarding/public",__webpack_require__,5)},function(module,exports,__webpack_require__){__webpack_require__.p=window.__osdPublicPath__["urlForwarding"]},function(module,exports){var process=module.exports={};var cachedSetTimeout;var cachedClearTimeout;function defaultSetTimout(){throw new Error("setTimeout has not been defined")}function defaultClearTimeout(){throw new Error("clearTimeout has not been defined")}(function(){try{if(typeof setTimeout==="function"){cachedSetTimeout=setTimeout}else{cachedSetTimeout=defaultSetTimout}}catch(e){cachedSetTimeout=defaultSetTimout}try{if(typeof clearTimeout==="function"){cachedClearTimeout=clearTimeout}else{cachedClearTimeout=defaultClearTimeout}}catch(e){cachedClearTimeout=defaultClearTimeout}})();function runTimeout(fun){if(cachedSetTimeout===setTimeout){return setTimeout(fun,0)}if((cachedSetTimeout===defaultSetTimout||!cachedSetTimeout)&&setTimeout){cachedSetTimeout=setTimeout;return setTimeout(fun,0)}try{return cachedSetTimeout(fun,0)}catch(e){try{return cachedSetTimeout.call(null,fun,0)}catch(e){return cachedSetTimeout.call(this,fun,0)}}}function runClearTimeout(marker){if(cachedClearTimeout===clearTimeout){return clearTimeout(marker)}if((cachedClearTimeout===defaultClearTimeout||!cachedClearTimeout)&&clearTimeout){cachedClearTimeout=clearTimeout;return clearTimeout(marker)}try{return cachedClearTimeout(marker)}catch(e){try{return cachedClearTimeout.call(null,marker)}catch(e){return cachedClearTimeout.call(this,marker)}}}var queue=[];var draining=false;var currentQueue;var queueIndex=-1;function cleanUpNextTick(){if(!draining||!currentQueue){return}draining=false;if(currentQueue.length){queue=currentQueue.concat(queue)}else{queueIndex=-1}if(queue.length){drainQueue()}}function drainQueue(){if(draining){return}var timeout=runTimeout(cleanUpNextTick);draining=true;var len=queue.length;while(len){currentQueue=queue;queue=[];while(++queueIndex<len){if(currentQueue){currentQueue[queueIndex].run()}}queueIndex=-1;len=queue.length}currentQueue=null;draining=false;runClearTimeout(timeout)}process.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1){for(var i=1;i<arguments.length;i++){args[i-1]=arguments[i]}}queue.push(new Item(fun,args));if(queue.length===1&&!draining){runTimeout(drainQueue)}};function Item(fun,array){this.fun=fun;this.array=array}Item.prototype.run=function(){this.fun.apply(null,this.array)};process.title="browser";process.browser=true;process.env={};process.argv=[];process.version="";process.versions={};function noop(){}process.on=noop;process.addListener=noop;process.once=noop;process.off=noop;process.removeListener=noop;process.removeAllListeners=noop;process.emit=noop;process.prependListener=noop;process.prependOnceListener=noop;process.listeners=function(name){return[]};process.binding=function(name){throw new Error("process.binding is not supported")};process.cwd=function(){return"/"};process.chdir=function(dir){throw new Error("process.chdir is not supported")};process.umask=function(){return 0}},function(module,__webpack_exports__,__webpack_require__){"use strict";__webpack_require__.r(__webpack_exports__);__webpack_require__.d(__webpack_exports__,"plugin",(function(){return public_plugin}));__webpack_require__.d(__webpack_exports__,"UrlForwardingPlugin",(function(){return plugin_UrlForwardingPlugin}));function navigateToDefaultApp(defaultAppId,forwards,application,basePath,currentAppId,overwriteHash){let targetAppId="opensearchDashboards";let targetAppPath=`#/${defaultAppId}`;const relevantForward=forwards.find(forward=>defaultAppId.startsWith(forward.legacyAppId));if(relevantForward){targetAppPath=relevantForward.rewritePath(`/${defaultAppId}`);targetAppId=relevantForward.newAppId}if(currentAppId!==targetAppId){application.navigateToApp(targetAppId,{path:targetAppPath,replace:true})}else if(overwriteHash){window.location.hash=targetAppPath}}var public_=__webpack_require__(1);var path_browserify=__webpack_require__(0);function normalizePath(path){const normalizeFunc=(path_browserify["posix"]===null||path_browserify["posix"]===void 0?void 0:path_browserify["posix"].normalize)||path_browserify["normalize"];const normalizedPath=normalizeFunc(path);return normalizedPath.replace(/(\.?\.?\/?)*/,"/")}const navigateToLegacyOpenSearchDashboardsUrl=(path,forwards,basePath,application)=>{const normalizedPath=normalizePath(path);const relevantForward=forwards.find(forward=>normalizedPath.startsWith(`/${forward.legacyAppId}`));if(!relevantForward){return{navigated:false}}const targetAppPath=relevantForward.rewritePath(normalizedPath);const targetAppId=relevantForward.newAppId;application.navigateToApp(targetAppId,{path:targetAppPath,replace:true});return{navigated:true}};const createLegacyUrlForwardApp=(core,forwards)=>({id:"kibana",chromeless:true,title:"Legacy URL migration",appRoute:"/app/kibana#/",navLinkStatus:public_["AppNavLinkStatus"].hidden,async mount(params){const hash=params.history.location.hash.substr(1);if(!hash){const[,,opensearchDashboardsLegacyStart]=await core.getStartServices();opensearchDashboardsLegacyStart.navigateToDefaultApp()}const[{application:application,http:{basePath:basePath}}]=await core.getStartServices();const result=await navigateToLegacyOpenSearchDashboardsUrl(hash,forwards,basePath,application);if(!result.navigated){const[,,opensearchDashboardsLegacyStart]=await core.getStartServices();opensearchDashboardsLegacyStart.navigateToDefaultApp()}return()=>{}}});const createLegacyUrlForwardCurrentApp=(core,forwards)=>({id:"opensearch-dashboards",chromeless:true,title:"Legacy URL migration",appRoute:"/app/opensearch-dashboards#/",navLinkStatus:public_["AppNavLinkStatus"].hidden,async mount(params){const hash=params.history.location.hash.substr(1);if(!hash){const[,,opensearchDashboardsLegacyStart]=await core.getStartServices();opensearchDashboardsLegacyStart.navigateToDefaultApp()}const[{application:application,http:{basePath:basePath}}]=await core.getStartServices();const result=await navigateToLegacyOpenSearchDashboardsUrl(hash,forwards,basePath,application);if(!result.navigated){const[,,opensearchDashboardsLegacyStart]=await core.getStartServices();opensearchDashboardsLegacyStart.navigateToDefaultApp()}return()=>{}}});function _defineProperty(e,r,t){return(r=_toPropertyKey(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function _toPropertyKey(t){var i=_toPrimitive(t,"string");return"symbol"==typeof i?i:i+""}function _toPrimitive(t,r){if("object"!=typeof t||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var i=e.call(t,r||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===r?String:Number)(t)}class plugin_UrlForwardingPlugin{constructor(){_defineProperty(this,"forwardDefinitions",[]);_defineProperty(this,"currentAppId",void 0);_defineProperty(this,"currentAppIdSubscription",void 0)}setup(core){core.application.register(createLegacyUrlForwardApp(core,this.forwardDefinitions));core.application.register(createLegacyUrlForwardCurrentApp(core,this.forwardDefinitions));return{forwardApp:(legacyAppId,newAppId,rewritePath)=>{this.forwardDefinitions.push({legacyAppId:legacyAppId,newAppId:newAppId,rewritePath:rewritePath||(path=>`#${path.replace(`/${legacyAppId}`,"")||"/"}`)})}}}start(_ref,_ref2){var _this=this;let{application:application,http:{basePath:basePath},uiSettings:uiSettings}=_ref;let{opensearchDashboardsLegacy:opensearchDashboardsLegacy}=_ref2;this.currentAppIdSubscription=application.currentAppId$.subscribe(currentAppId=>{this.currentAppId=currentAppId});
1return{navigateToDefaultApp:function(){let{overwriteHash:overwriteHash}=arguments.length>0&&arguments[0]!==undefined?arguments[0]:{overwriteHash:true};navigateToDefaultApp(opensearchDashboardsLegacy.config.defaultAppId,_this.forwardDefinitions,application,basePath,_this.currentAppId,overwriteHash)},navigateToLegacyOpenSearchDashboardsUrl:hash=>navigateToLegacyOpenSearchDashboardsUrl(hash,this.forwardDefinitions,basePath,application),getForwards:()=>this.forwardDefinitions}}stop(){if(this.currentAppIdSubscription){this.currentAppIdSubscription.unsubscribe()}}}const public_plugin=()=>new plugin_UrlForwardingPlugin}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.