(window.webpackJsonp=window.webpackJsonp||[]).push([[46],{"./documentation/controllers/DocumentationContextBarController.js":function(t,e,i){"use strict";i.r(e),i.d(e,"default",(function(){return a}));var r,o=i("./documentation/stores/DocumentationContextBarStore.js"),n=i("../../node_modules/mobx/lib/mobx.module.js"),s=i("./js/stores/get-store.js");let a=(l=(r=class{constructor(){this.entityId=void 0,this.entityUid=void 0,this.entityType=void 0,this.owner=void 0,this.unsavedDescription=null,this.updateUnsavedDescription=t=>{this.unsavedDescription=t}}get store(){const t=Object(s.getStore)("ActiveWorkspaceSessionStore").activeEditor,e=Object(s.getStore)("EditorStore").find(t);if(e){const t=e.resource,i="v2implview://stubView/";if(t.startsWith(i)){const[e,r]=t.replace(i,"").split("/");return new o.default(e,r)}}return null}willDestroy(){this.codegen=void 0}get contextBarUnsavedDescription(){return this.unsavedDescription}}).prototype,c="store",u=[n.computed],d=Object.getOwnPropertyDescriptor(r.prototype,"store"),p=r.prototype,T={},Object.keys(d).forEach((function(t){T[t]=d[t]})),T.enumerable=!!T.enumerable,T.configurable=!!T.configurable,("value"in T||T.initializer)&&(T.writable=!0),T=u.slice().reverse().reduce((function(t,e){return e(l,c,t)||t}),T),p&&void 0!==T.initializer&&(T.value=T.initializer?T.initializer.call(p):void 0,T.initializer=void 0),void 0===T.initializer&&(Object.defineProperty(l,c,T),T=null),r);var l,c,u,d,p,T},"./documentation/stores/DocumentationContextBarStore.js":function(t,e,i){"use strict";i.r(e),i.d(e,"default",(function(){return u}));var r,o,n,s=i("../../node_modules/mobx/lib/mobx.module.js"),a=i("./documentation/constants.js"),l=i("./documentation/stores/DocumentationMasterStore.js");function c(t,e,i,r,o){var n={};return Object.keys(r).forEach((function(t){n[t]=r[t]})),n.enumerable=!!n.enumerable,n.configurable=!!n.configurable,("value"in n||n.initializer)&&(n.writable=!0),n=i.slice().reverse().reduce((function(i,r){return r(t,e,i)||i}),n),o&&void 0!==n.initializer&&(n.value=n.initializer?n.initializer.call(o):void 0,n.initializer=void 0),void 0===n.initializer&&(Object.defineProperty(t,e,n),n=null),n}let u=(n=o=class{constructor(t,e){this.entityType=t,this.entityUid=e,this.masterStore=l.default.getInstance()}get isOffline(){return this.masterStore.isOffline}get isEditable(){return this.masterStore.isEditable}get activeEnvironmentVariables(){return this.masterStore.activeEnvironmentVariables}get isUserMemberOfActiveWorkspace(){return this.masterStore.isUserMemberOfActiveWorkspace}get entityData(){if(this.entityType&&!a.DOCUMENTATION_ENTITY[this.entityType.toUpperCase()])return{isLoading:!1,error:null,data:null};let{data:t,status:e}=this.masterStore.getData({uid:this.entityUid,type:this.entityType,versionTag:a.DOCUMENTATION_LATEST_VERSION_STRING},{withPublishedData:!0});return{isLoading:e===a.DOCUMENTATION_STATUS.LOADING,error:e===a.DOCUMENTATION_STATUS.ERROR,data:t}}get parentCollectionData(){if(this.entityType&&!a.DOCUMENTATION_ENTITY[this.entityType.toUpperCase()])return{isLoading:!1,error:null,data:null};const{data:t}=this.entityData;if(this.entityType===a.DOCUMENTATION_ENTITY.COLLECTION)return t;if(!t)return;const e=`${t.owner}-${t.collection}`;return this.masterStore.getData({uid:e,type:a.DOCUMENTATION_ENTITY.COLLECTION,versionTag:a.DOCUMENTATION_LATEST_VERSION_STRING}).data}updateDescription(t){this.masterStore.updateDescription({type:this.entityType,uid:this.entityUid},t)}},o.masterStoreGetMethod={[a.DOCUMENTATION_ENTITY.COLLECTION]:"getCollection",[a.DOCUMENTATION_ENTITY.FOLDER]:"getFolder",[a.DOCUMENTATION_ENTITY.REQUEST]:"getRequest"},c((r=n).prototype,"entityData",[s.computed],Object.getOwnPropertyDescriptor(r.prototype,"entityData"),r.prototype),c(r.prototype,"parentCollectionData",[s.computed],Object.getOwnPropertyDescriptor(r.prototype,"parentCollectionData"),r.prototype),r)}}]);