aiware-js 2.14.0 → 2.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.esm.js +1 -1
- package/index.html +1 -1
- package/js-core.esm.js +230 -34
- package/js-core.esm10.js +1 -1
- package/js-core.esm11.js +1 -1
- package/js-core.esm12.js +1 -1
- package/js-core.esm13.js +1 -1
- package/js-core.esm14.js +1 -1
- package/js-core.esm15.js +1 -23
- package/js-core.esm16.js +1 -1
- package/js-core.esm17.js +201 -566
- package/js-core.esm18.js +60 -1
- package/js-core.esm19.js +1 -1
- package/js-core.esm2.js +1 -1
- package/js-core.esm20.js +1 -1
- package/js-core.esm21.js +1 -1
- package/js-core.esm22.js +1 -1
- package/js-core.esm23.js +1 -1
- package/js-core.esm24.js +1 -1
- package/js-core.esm25.js +14 -1
- package/js-core.esm26.js +12 -1
- package/js-core.esm27.js +54 -230
- package/js-core.esm28.js +1 -60
- package/js-core.esm29.js +88 -1
- package/js-core.esm30.js +226 -1
- package/js-core.esm31.js +35 -1
- package/js-core.esm32.js +1 -1
- package/js-core.esm33.js +1 -1
- package/js-core.esm34.js +1 -1
- package/js-core.esm35.js +1 -14
- package/js-core.esm36.js +31 -12
- package/js-core.esm37.js +1 -54
- package/js-core.esm38.js +51 -1
- package/js-core.esm39.js +1 -88
- package/js-core.esm4.js +1 -1
- package/js-core.esm40.js +23 -220
- package/js-core.esm41.js +1 -35
- package/js-core.esm5.js +23 -1
- package/js-core.esm6.js +1 -20
- package/js-core.esm7.js +568 -109
- package/js-core.esm8.js +1 -1
- package/js-core.esm9.js +1 -1
- package/js-core.umd.js +209 -117
- package/lib/widgetHandler.d.ts +17 -4
- package/locales/en.json +1 -1
- package/locales/es.json +1 -1
- package/locales/fr.json +1 -1
- package/package.json +4 -2
- package/js-core.esm42.js +0 -1
- package/js-core.esm43.js +0 -1
- package/js-core.esm44.js +0 -1
- package/js-core.esm45.js +0 -1
- package/js-core.esm46.js +0 -31
- package/js-core.esm47.js +0 -1
- package/js-core.esm48.js +0 -1
- package/js-core.esm49.js +0 -1
- package/js-core.esm50.js +0 -29
package/js-core.esm38.js
CHANGED
|
@@ -1 +1,51 @@
|
|
|
1
|
-
import{m as makeStyles,fX as img$J,j as jsxRuntime,F as FormattedMessage,fY as img$I,fZ as img$1r,f_ as img$1q,f$ as img$1p,g0 as img$G,g1 as img$1s,g2 as img$F,aM as createAction,aN as createReducer,G as useDispatch,r as react,H as useSelector,J as authSelector,Q as lib,c$ as getAuthModule,A as AIWareIntlProvider,a3 as List,bh as Box,a4 as ListItem,bk as ListItemAvatar,Z as Avatar,a5 as ListItemText,T as Typography,as as all,aw as takeEvery$1}from"./js-core.esm.js";!function(){var e={};try{if(process)return process.env=Object.assign({},process.env),Object.assign(process.env,e)}catch(e){}globalThis.process={env:e}}(),makeStyles()(e=>({headerItemContainer:{display:"flex"},itemLabel:{fontWeight:600,color:"#2A323C",marginRight:8}})),makeStyles()(e=>({infoBox:{borderBottom:"0.5px solid #D5DFE9",paddingTop:e.spacing(4),paddingBottom:e.spacing(4),paddingLeft:e.spacing(),display:"flex"},squareBox:{width:150,height:150,display:"flex",justifyContent:"center",alignItems:"center",paddingLeft:e.spacing(2)},appInfo:{marginBottom:e.spacing(3)},avatarGird:{display:"flex",alignItems:"center"},avatar:{border:"10px solid #D5DFE9",background:"#F2F5F9",padding:e.spacing(3.4),width:"unset",height:"unset"},appName:{fontWeight:500,fontSize:22,color:"#335B89",lineHeight:"28px"},version:{fontSize:10,color:"#2A323C",lineHeight:"14px"},versionTitle:{fontWeight:600,color:"#2A323C"},appInfoDetail:{marginBottom:e.spacing(3)},buttonSU:{textTransform:"initial",fontWeight:400,fontSize:"10px",padding:e.spacing(.2,2),borderRadius:"2px"}}));const useStyles$1=makeStyles()((e,{backgroundColor:t})=>({boxItem:{display:"flex",padding:0,height:70,borderBottom:"1px solid "+e.palette.divider},avatarContainer:{background:t,width:40,height:40,borderRadius:"50%"},avatar:{width:"40px !important",height:"40px !important",fontSize:"14px !important",margin:"auto !important",marginRight:e.spacing(2.4)+" !important"},avatarIcon:{width:16,height:"auto"},listItemText:{fontSize:"14px!important",lineHeight:"19px",overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis",fontWeight:500,textTransform:"capitalize",color:"#2A323C"},descriptionItemText:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",fontSize:"12px !important",color:e.palette.secondary.main,lineHeight:"16px"}}));function CustomListItem({item:e,onClick:t}){var s,i=useStyles$1({backgroundColor:e.backgroundColor})["classes"];return jsxRuntime.exports.jsxs(ListItem,Object.assign({button:!0,className:i.boxItem,onClick:(s=e.key,()=>{null!=t&&t(s)}),"data-test":"toggle-"+e.key,"data-testid":"toggle-"+e.key},{children:[jsxRuntime.exports.jsx(ListItemAvatar,{children:jsxRuntime.exports.jsx("div",Object.assign({className:i.avatarContainer},{children:jsxRuntime.exports.jsx(Avatar,{src:e.icon,className:i.avatar,classes:{img:i.avatarIcon}})}))}),jsxRuntime.exports.jsx(ListItemText,{primary:jsxRuntime.exports.jsx(Typography,Object.assign({variant:"body2",className:i.listItemText},{children:e.label})),secondary:jsxRuntime.exports.jsx(Typography,Object.assign({color:"textSecondary",variant:"body2",className:i.descriptionItemText},{children:e.description})),className:i.listItemText})]}))}const adminSettingListItem=[{key:"profile",icon:img$J,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.profile",defaultMessage:"Profile",description:"The label of org info profile label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.profileDescription",defaultMessage:"View and edit organization info",description:"The description of org info profile label"}),backgroundColor:"#E8F7FF",roles:["superadmin","admin"]},{key:"users",icon:img$I,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.user",defaultMessage:"User",description:"The label of org info user label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.userDescription",defaultMessage:"View and edit all client users",description:"The description of org info user label"}),backgroundColor:"#E9FFF1",roles:["superadmin","admin"]},{key:"organizations",icon:img$1r,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.orgs",defaultMessage:"Organizations",description:"The label of org info organizations label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.orgsDescription",defaultMessage:"View and add new organizations",description:"The description of org info organizations description"}),backgroundColor:"#FFF7E2",roles:["superadmin"]},{key:"applications",icon:img$1q,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.apps",defaultMessage:"Applications",description:"The label of org info applications label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.appsDescription",defaultMessage:"View and edit all clients applications",description:"The description of org info apps description"}),backgroundColor:"#F6EDFF",roles:["superadmin"]},{key:"engines",icon:img$1p,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.engines",defaultMessage:"Engines",description:"The label of org info engines label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.enginesDescription",defaultMessage:"Manage and edit all client engines",description:"The description of org info engines description"}),backgroundColor:"#FFECE1",roles:["superadmin"]},{key:"edge/overview",icon:img$G,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.overview",defaultMessage:"Overview",description:"The label of org info overview label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.overviewDescription",defaultMessage:"Administrative view of Edge Ecosystem",description:"The description of org info Edge Ecosystem description"}),backgroundColor:"#FFE8E8",roles:["superadmin","admin"]},{key:"aiware",icon:img$1s,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.edge",defaultMessage:"aiWARE Edge",description:"The label of org info aiware edge label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.edgeDescription",defaultMessage:"Add and configure software settings",description:"The description of org info aiware edge description"}),backgroundColor:"#EDFBFF",roles:["superadmin","admin"]},{key:"config",icon:img$F,label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.configuration",defaultMessage:"Configuration",description:"The label of org info configuration label"}),description:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-setting-preference-panel.configurationDescription",defaultMessage:"View and edit all system settings",description:"The description of org info configuration description"}),backgroundColor:"#ECF1FF",roles:["superadmin"]}],GET_SETTING_CONFIGURATION="os-setting-panel/GET_SETTING_CONFIGURATION",GET_SETTING_CONFIGURATION_START="os-setting-panel/GET_SETTING_CONFIGURATION_START",GET_SETTING_CONFIGURATION_SUCCESS="os-setting-panel/GET_SETTING_CONFIGURATION_SUCCESS",GET_SETTING_CONFIGURATION_ERROR="os-setting-panel/GET_SETTING_CONFIGURATION_ERROR",getPreferenceSetting=createAction(GET_SETTING_CONFIGURATION),getPreferenceSettingStart=createAction(GET_SETTING_CONFIGURATION_START),getPreferenceSettingSuccess=createAction(GET_SETTING_CONFIGURATION_SUCCESS,function(e){return{payload:e}}),getPreferenceSettingError=createAction(GET_SETTING_CONFIGURATION_ERROR,function(e){return{payload:e}}),initialState={status:"idle",failureMessage:"",settings:{version:"3.1.1.0193903a",environment:"US AWS Production",edgeClusters:20,processors:3121,storage:65200}},settingReducer=createReducer(initialState,e=>{e.addCase(getPreferenceSettingStart,e=>Object.assign(Object.assign({},e),{status:"loading"})).addCase(getPreferenceSettingSuccess,(e,t)=>Object.assign(Object.assign({},e),{status:"success",settings:t.payload})).addCase(getPreferenceSettingError,(e,t)=>Object.assign(Object.assign({},e),{failureMessage:t.payload,status:"failure"}))}),namespace="settingPreferencePanel",settingSelector=e=>(null==e?void 0:e[namespace])||{};function*getPreferenceSettingSaga(){}function*settingSaga(){yield all([takeEvery$1(getPreferenceSetting().type,getPreferenceSettingSaga)])}function getSettingModule(){return{id:"os-setting-panel",reducerMap:{[namespace]:settingReducer},sagas:[settingSaga],initialActions:[]}}const useStyles=makeStyles()(e=>({root:{overflowX:"hidden",overflowY:"auto",height:"100%"},listMenuBox:{padding:e.spacing(5,7,4,6)},listContainer:{padding:0},listAccounts:{}})),enableApplicationInfo=!1,SettingsPreferencesPanel=()=>{var e=useStyles()["classes"];const t=useDispatch(),[s,i]=react.exports.useState([]),n=(useSelector(settingSelector),useSelector(e=>e.configs))["config"],a=useSelector(authSelector)["user"],o=(react.exports.useEffect(()=>{t(getPreferenceSetting())},[t]),react.exports.useCallback(e=>{var t=n["adminAppUrl"];const{roles:s,organization:{organizationId:i}}=a;s.includes("superadmin")?window.open(t+"/"+e):window.open(t+`/organizations/${i}/`+e)},[a,n]));return react.exports.useEffect(()=>{const e=a["roles"];var t;null!==e&&void 0!==e&&e.includes("superadmin")?(t=adminSettingListItem.filter(e=>e.roles.includes("superadmin")),i(t)):(t=adminSettingListItem.filter(e=>e.roles.includes("admin")),i(t))},[a]),jsxRuntime.exports.jsx(lib.DynamicModuleLoader,Object.assign({modules:[getSettingModule(),getAuthModule()]},{children:jsxRuntime.exports.jsx(AIWareIntlProvider,{children:jsxRuntime.exports.jsxs("div",Object.assign({className:e.root,"data-testid":"setting-preference-panel"},{children:[enableApplicationInfo,jsxRuntime.exports.jsx("div",Object.assign({className:e.listMenuBox},{children:jsxRuntime.exports.jsx(List,Object.assign({className:e.listContainer},{children:jsxRuntime.exports.jsx(Box,Object.assign({className:e.listAccounts},{children:s.map(e=>jsxRuntime.exports.jsx(react.exports.Fragment,{children:jsxRuntime.exports.jsx(CustomListItem,{item:e,onClick:o})},e.key))}))}))}))]}))})}))};export{SettingsPreferencesPanel};
|
|
1
|
+
import{H as createSlice,cg as createSelector,O as rootApiSelector,R as graphEndpointSelector,Q as sessionTokenSelector,cf as combineReducers,j as jsxRuntime,F as FormattedMessage,m as makeStyles,B as Box,T as Typography$1,eK as injectIntl,k as useSelector,i as useDispatch,r as react,ae as Skeleton$1,a7 as Divider,fS as ErrorState,a8 as Tooltip,a9 as IconButton,bV as Hide,ci as AIWareThemeProvider,K as lib,A as AIWareIntlProvider,bx as CacheProvider,by as muiCache,a2 as all,fR as selectIsUserAdmin,bi as React,cz as CustomTabs,cm as TabPanel,eE as userSelector,at as Button,G as Grid$1,g7 as NoApps,eo as hidePanel,Z as List,dA as takeEvery$1,cA as useBackupImg,cB as img$1u,p as lodash,S as Switch,w as TextField,fQ as selectOrgId,$ as ListItem,eP as ListItemAvatar,bN as Avatar,a1 as ListItemText,g8 as green,g5 as Lock,eU as ListItemSecondaryAction,cs as mountPanel,ai as select,ah as put,ak as call$g,cD as baseGraphQLApiWithError}from"./js-core.esm.js";import{C as Container}from"./js-core.esm21.js";import{S as Stack}from"./js-core.esm19.js";import{C as Chip$1}from"./js-core.esm23.js";!function(){var e={};try{if(process)return process.env=Object.assign({},process.env),Object.assign(process.env,e)}catch(e){}globalThis.process={env:e}}();var match,version,store,wmget,wmhas,wmset,set$1,get,has,STATE,activeXDocument,IteratorPrototype$2,PrototypeOfArrayIteratorPrototype,arrayIterator,commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},check=function(e){return e&&e.Math==Math&&e},global$k=check("object"==typeof globalThis&&globalThis)||check("object"==typeof window&&window)||check("object"==typeof self&&self)||check("object"==typeof commonjsGlobal&&commonjsGlobal)||function(){return this}()||Function("return this")(),objectGetOwnPropertyDescriptor={},fails$g=function(e){try{return!!e()}catch(e){return!0}},fails$f=fails$g,descriptors=!fails$g(function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}),fails$e=fails$g,functionBindNative=!fails$g(function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}),NATIVE_BIND$3=functionBindNative,call$f=Function.prototype.call,functionCall=NATIVE_BIND$3?call$f.bind(call$f):function(){return call$f.apply(call$f,arguments)},objectPropertyIsEnumerable={},$propertyIsEnumerable={}.propertyIsEnumerable,getOwnPropertyDescriptor$2=Object.getOwnPropertyDescriptor,NASHORN_BUG=getOwnPropertyDescriptor$2&&!$propertyIsEnumerable.call({1:2},1),createPropertyDescriptor$4=(objectPropertyIsEnumerable.f=NASHORN_BUG?function(e){e=getOwnPropertyDescriptor$2(this,e);return!!e&&e.enumerable}:$propertyIsEnumerable,function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}),NATIVE_BIND$2=functionBindNative,FunctionPrototype$2=Function.prototype,bind$5=FunctionPrototype$2.bind,call$e=FunctionPrototype$2.call,uncurryThis$g=NATIVE_BIND$2&&bind$5.bind(call$e,call$e),functionUncurryThis=NATIVE_BIND$2?function(e){return e&&uncurryThis$g(e)}:function(e){return e&&function(){return call$e.apply(e,arguments)}},uncurryThis$f=functionUncurryThis,toString$4=uncurryThis$f({}.toString),stringSlice$1=uncurryThis$f("".slice),classofRaw$1=function(e){return stringSlice$1(toString$4(e),8,-1)},uncurryThis$e=functionUncurryThis,fails$d=fails$g,classof$5=classofRaw$1,$Object$4=Object,split=functionUncurryThis("".split),indexedObject=fails$d(function(){return!$Object$4("z").propertyIsEnumerable(0)})?function(e){return"String"==classof$5(e)?split(e,""):$Object$4(e)}:$Object$4,$TypeError$d=TypeError,requireObjectCoercible$2=function(e){if(null==e)throw $TypeError$d("Can't call method on "+e);return e},IndexedObject$2=indexedObject,requireObjectCoercible$1=requireObjectCoercible$2,toIndexedObject$5=function(e){return IndexedObject$2(requireObjectCoercible$1(e))},isCallable$l=function(e){return"function"==typeof e},isCallable$k=isCallable$l,isObject$7=function(e){return"object"==typeof e?null!==e:isCallable$k(e)},global$j=global$k,isCallable$j=isCallable$l,aFunction=function(e){return isCallable$j(e)?e:void 0},getBuiltIn$8=function(e,t){return arguments.length<2?aFunction(global$j[e]):global$j[e]&&global$j[e][t]},uncurryThis$d=functionUncurryThis,objectIsPrototypeOf=functionUncurryThis({}.isPrototypeOf),getBuiltIn$7=getBuiltIn$8,engineUserAgent=getBuiltIn$8("navigator","userAgent")||"",global$i=global$k,userAgent$5=engineUserAgent,process$4=global$i.process,Deno$1=global$i.Deno,versions=process$4&&process$4.versions||Deno$1&&Deno$1.version,v8=versions&&versions.v8,engineV8Version=version=!(version=v8?0<(match=v8.split("."))[0]&&match[0]<4?1:+(match[0]+match[1]):version)&&userAgent$5&&(!(match=userAgent$5.match(/Edge\/(\d+)/))||74<=match[1])&&(match=userAgent$5.match(/Chrome\/(\d+)/))?+match[1]:version,V8_VERSION$1=engineV8Version,fails$c=fails$g,nativeSymbol=!!Object.getOwnPropertySymbols&&!fails$c(function(){var e=Symbol();return!String(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&V8_VERSION$1&&V8_VERSION$1<41}),NATIVE_SYMBOL$2=nativeSymbol,useSymbolAsUid=nativeSymbol&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,getBuiltIn$6=getBuiltIn$8,isCallable$i=isCallable$l,isPrototypeOf$4=objectIsPrototypeOf,USE_SYMBOL_AS_UID$1=useSymbolAsUid,$Object$3=Object,isSymbol$2=useSymbolAsUid?function(e){return"symbol"==typeof e}:function(e){var t=getBuiltIn$6("Symbol");return isCallable$i(t)&&isPrototypeOf$4(t.prototype,$Object$3(e))},$String$3=String,tryToString$5=function(e){try{return $String$3(e)}catch(e){return"Object"}},isCallable$h=isCallable$l,tryToString$4=tryToString$5,$TypeError$c=TypeError,aCallable$9=function(e){if(isCallable$h(e))return e;throw $TypeError$c(tryToString$4(e)+" is not a function")},aCallable$8=aCallable$9,getMethod$3=function(e,t){e=e[t];return null==e?void 0:aCallable$8(e)},call$d=functionCall,isCallable$g=isCallable$l,isObject$6=isObject$7,$TypeError$b=TypeError,ordinaryToPrimitive$1=function(e,t){var n,r;if("string"===t&&isCallable$g(n=e.toString)&&!isObject$6(r=call$d(n,e)))return r;if(isCallable$g(n=e.valueOf)&&!isObject$6(r=call$d(n,e)))return r;if("string"!==t&&isCallable$g(n=e.toString)&&!isObject$6(r=call$d(n,e)))return r;throw $TypeError$b("Can't convert object to primitive value")},shared$3={exports:{}},global$h=global$k,defineProperty$6=Object.defineProperty,defineGlobalProperty$3=function(t,n){try{defineProperty$6(global$h,t,{value:n,configurable:!0,writable:!0})}catch(e){global$h[t]=n}return n},global$g=global$k,defineGlobalProperty$2=defineGlobalProperty$3,SHARED="__core-js_shared__",store$3=global$k[SHARED]||defineGlobalProperty$2(SHARED,{}),sharedStore=store$3,store$2=sharedStore,requireObjectCoercible=((shared$3.exports=function(e,t){return store$2[e]||(store$2[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.24.1",mode:"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.24.1/LICENSE",source:"https://github.com/zloirock/core-js"}),requireObjectCoercible$2),$Object$2=Object,toObject$5=function(e){return $Object$2(requireObjectCoercible(e))},uncurryThis$c=functionUncurryThis,toObject$4=toObject$5,hasOwnProperty=functionUncurryThis({}.hasOwnProperty),hasOwnProperty_1=Object.hasOwn||function(e,t){return hasOwnProperty(toObject$4(e),t)},uncurryThis$b=functionUncurryThis,id=0,postfix=Math.random(),toString$3=uncurryThis$b(1..toString),uid$2=function(e){return"Symbol("+(void 0===e?"":e)+")_"+toString$3(++id+postfix,36)},global$f=global$k,shared$2=shared$3.exports,hasOwn$b=hasOwnProperty_1,uid$1=uid$2,NATIVE_SYMBOL$1=nativeSymbol,USE_SYMBOL_AS_UID=useSymbolAsUid,WellKnownSymbolsStore=shared$2("wks"),Symbol$1=global$f.Symbol,symbolFor=Symbol$1&&Symbol$1.for,createWellKnownSymbol=USE_SYMBOL_AS_UID?Symbol$1:Symbol$1&&Symbol$1.withoutSetter||uid$1,wellKnownSymbol$e=function(e){var t;return hasOwn$b(WellKnownSymbolsStore,e)&&(NATIVE_SYMBOL$1||"string"==typeof WellKnownSymbolsStore[e])||(t="Symbol."+e,NATIVE_SYMBOL$1&&hasOwn$b(Symbol$1,e)?WellKnownSymbolsStore[e]=Symbol$1[e]:WellKnownSymbolsStore[e]=(USE_SYMBOL_AS_UID&&symbolFor?symbolFor:createWellKnownSymbol)(t)),WellKnownSymbolsStore[e]},call$c=functionCall,isObject$5=isObject$7,isSymbol$1=isSymbol$2,getMethod$2=getMethod$3,ordinaryToPrimitive=ordinaryToPrimitive$1,wellKnownSymbol$d=wellKnownSymbol$e,$TypeError$a=TypeError,TO_PRIMITIVE=wellKnownSymbol$e("toPrimitive"),toPrimitive$1=function(e,t){if(!isObject$5(e)||isSymbol$1(e))return e;var n=getMethod$2(e,TO_PRIMITIVE);if(n){if(n=call$c(n,e,t=void 0===t?"default":t),!isObject$5(n)||isSymbol$1(n))return n;throw $TypeError$a("Can't convert object to primitive value")}return ordinaryToPrimitive(e,t=void 0===t?"number":t)},toPrimitive=toPrimitive$1,isSymbol=isSymbol$2,toPropertyKey$3=function(e){e=toPrimitive(e,"string");return isSymbol(e)?e:e+""},global$e=global$k,isObject$4=isObject$7,document$3=global$k.document,EXISTS$1=isObject$4(document$3)&&isObject$4(document$3.createElement),documentCreateElement$2=function(e){return EXISTS$1?document$3.createElement(e):{}},DESCRIPTORS$b=descriptors,fails$b=fails$g,createElement$1=documentCreateElement$2,ie8DomDefine=!descriptors&&!fails$g(function(){return 7!=Object.defineProperty(createElement$1("div"),"a",{get:function(){return 7}}).a}),DESCRIPTORS$a=descriptors,call$b=functionCall,propertyIsEnumerableModule$1=objectPropertyIsEnumerable,createPropertyDescriptor$3=createPropertyDescriptor$4,toIndexedObject$4=toIndexedObject$5,toPropertyKey$2=toPropertyKey$3,hasOwn$a=hasOwnProperty_1,IE8_DOM_DEFINE$1=ie8DomDefine,$getOwnPropertyDescriptor$1=Object.getOwnPropertyDescriptor,objectDefineProperty=(objectGetOwnPropertyDescriptor.f=DESCRIPTORS$a?$getOwnPropertyDescriptor$1:function(e,t){if(e=toIndexedObject$4(e),t=toPropertyKey$2(t),IE8_DOM_DEFINE$1)try{return $getOwnPropertyDescriptor$1(e,t)}catch(e){}if(hasOwn$a(e,t))return createPropertyDescriptor$3(!call$b(propertyIsEnumerableModule$1.f,e,t),e[t])},{}),DESCRIPTORS$9=descriptors,fails$a=fails$g,v8PrototypeDefineBug=descriptors&&fails$g(function(){return 42!=Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype}),isObject$3=isObject$7,$String$2=String,$TypeError$9=TypeError,anObject$c=function(e){if(isObject$3(e))return e;throw $TypeError$9($String$2(e)+" is not an object")},DESCRIPTORS$8=descriptors,IE8_DOM_DEFINE=ie8DomDefine,V8_PROTOTYPE_DEFINE_BUG$1=v8PrototypeDefineBug,anObject$b=anObject$c,toPropertyKey$1=toPropertyKey$3,$TypeError$8=TypeError,$defineProperty=Object.defineProperty,$getOwnPropertyDescriptor=Object.getOwnPropertyDescriptor,ENUMERABLE="enumerable",CONFIGURABLE$1="configurable",WRITABLE="writable",DESCRIPTORS$7=(objectDefineProperty.f=DESCRIPTORS$8?V8_PROTOTYPE_DEFINE_BUG$1?function(e,t,n){var r;return anObject$b(e),t=toPropertyKey$1(t),anObject$b(n),"function"==typeof e&&"prototype"===t&&"value"in n&&WRITABLE in n&&!n[WRITABLE]&&((r=$getOwnPropertyDescriptor(e,t))&&r[WRITABLE]&&(e[t]=n.value,n={configurable:(CONFIGURABLE$1 in n?n:r)[CONFIGURABLE$1],enumerable:(ENUMERABLE in n?n:r)[ENUMERABLE],writable:!1})),$defineProperty(e,t,n)}:$defineProperty:function(e,t,n){if(anObject$b(e),t=toPropertyKey$1(t),anObject$b(n),IE8_DOM_DEFINE)try{return $defineProperty(e,t,n)}catch(e){}if("get"in n||"set"in n)throw $TypeError$8("Accessors not supported");return"value"in n&&(e[t]=n.value),e},descriptors),definePropertyModule$5=objectDefineProperty,createPropertyDescriptor$2=createPropertyDescriptor$4,createNonEnumerableProperty$4=DESCRIPTORS$7?function(e,t,n){return definePropertyModule$5.f(e,t,createPropertyDescriptor$2(1,n))}:function(e,t,n){return e[t]=n,e},makeBuiltIn$2={exports:{}},DESCRIPTORS$6=descriptors,hasOwn$9=hasOwnProperty_1,FunctionPrototype$1=Function.prototype,getDescriptor=DESCRIPTORS$6&&Object.getOwnPropertyDescriptor,EXISTS=hasOwn$9(FunctionPrototype$1,"name"),PROPER=EXISTS&&"something"===function(){}.name,CONFIGURABLE=EXISTS&&(!DESCRIPTORS$6||getDescriptor(FunctionPrototype$1,"name").configurable),functionName={EXISTS:EXISTS,PROPER:PROPER,CONFIGURABLE:CONFIGURABLE},uncurryThis$a=functionUncurryThis,isCallable$f=isCallable$l,store$1=sharedStore,functionToString=functionUncurryThis(Function.toString),inspectSource$4=(isCallable$f(store$1.inspectSource)||(store$1.inspectSource=function(e){return functionToString(e)}),store$1.inspectSource),global$d=global$k,isCallable$e=isCallable$l,inspectSource$3=inspectSource$4,WeakMap$1=global$k.WeakMap,nativeWeakMap=isCallable$e(WeakMap$1)&&/native code/.test(inspectSource$3(WeakMap$1)),shared$1=shared$3.exports,uid=uid$2,keys=shared$1("keys"),sharedKey$3=function(e){return keys[e]||(keys[e]=uid(e))},hiddenKeys$4={},NATIVE_WEAK_MAP=nativeWeakMap,global$c=global$k,uncurryThis$9=functionUncurryThis,isObject$2=isObject$7,createNonEnumerableProperty$3=createNonEnumerableProperty$4,hasOwn$8=hasOwnProperty_1,shared=sharedStore,sharedKey$2=sharedKey$3,hiddenKeys$3=hiddenKeys$4,OBJECT_ALREADY_INITIALIZED="Object already initialized",TypeError$2=global$c.TypeError,WeakMap=global$c.WeakMap,enforce=function(e){return has(e)?get(e):set$1(e,{})},getterFor=function(t){return function(e){if(isObject$2(e)&&(e=get(e)).type===t)return e;throw TypeError$2("Incompatible receiver, "+t+" required")}},internalState=(has=NATIVE_WEAK_MAP||shared.state?(store=shared.state||(shared.state=new WeakMap),wmget=uncurryThis$9(store.get),wmhas=uncurryThis$9(store.has),wmset=uncurryThis$9(store.set),set$1=function(e,t){if(wmhas(store,e))throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);return t.facade=e,wmset(store,e,t),t},get=function(e){return wmget(store,e)||{}},function(e){return wmhas(store,e)}):(STATE=sharedKey$2("state"),hiddenKeys$3[STATE]=!0,set$1=function(e,t){if(hasOwn$8(e,STATE))throw new TypeError$2(OBJECT_ALREADY_INITIALIZED);return t.facade=e,createNonEnumerableProperty$3(e,STATE,t),t},get=function(e){return hasOwn$8(e,STATE)?e[STATE]:{}},function(e){return hasOwn$8(e,STATE)}),{set:set$1,get:get,has:has,enforce:enforce,getterFor:getterFor}),fails$9=fails$g,isCallable$d=isCallable$l,hasOwn$7=hasOwnProperty_1,DESCRIPTORS$5=descriptors,CONFIGURABLE_FUNCTION_NAME$1=functionName.CONFIGURABLE,inspectSource$2=inspectSource$4,InternalStateModule$2=internalState,enforceInternalState=InternalStateModule$2.enforce,getInternalState$1=InternalStateModule$2.get,defineProperty$5=Object.defineProperty,CONFIGURABLE_LENGTH=DESCRIPTORS$5&&!fails$9(function(){return 8!==defineProperty$5(function(){},"length",{value:8}).length}),TEMPLATE=String(String).split("String"),makeBuiltIn$1=makeBuiltIn$2.exports=function(e,t,n){"Symbol("===String(t).slice(0,7)&&(t="["+String(t).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),n&&n.getter&&(t="get "+t),n&&n.setter&&(t="set "+t),(!hasOwn$7(e,"name")||CONFIGURABLE_FUNCTION_NAME$1&&e.name!==t)&&(DESCRIPTORS$5?defineProperty$5(e,"name",{value:t,configurable:!0}):e.name=t),CONFIGURABLE_LENGTH&&n&&hasOwn$7(n,"arity")&&e.length!==n.arity&&defineProperty$5(e,"length",{value:n.arity});try{n&&hasOwn$7(n,"constructor")&&n.constructor?DESCRIPTORS$5&&defineProperty$5(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}n=enforceInternalState(e);return hasOwn$7(n,"source")||(n.source=TEMPLATE.join("string"==typeof t?t:"")),e},isCallable$c=(Function.prototype.toString=makeBuiltIn$1(function(){return isCallable$d(this)&&getInternalState$1(this).source||inspectSource$2(this)},"toString"),isCallable$l),definePropertyModule$4=objectDefineProperty,makeBuiltIn=makeBuiltIn$2.exports,defineGlobalProperty$1=defineGlobalProperty$3,defineBuiltIn$6=function(e,t,n,r){var o=(r=r||{}).enumerable,i=void 0!==r.name?r.name:t;if(isCallable$c(n)&&makeBuiltIn(n,i,r),r.global)o?e[t]=n:defineGlobalProperty$1(t,n);else{try{r.unsafe?e[t]&&(o=!0):delete e[t]}catch(e){}o?e[t]=n:definePropertyModule$4.f(e,t,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e},objectGetOwnPropertyNames={},ceil=Math.ceil,floor$1=Math.floor,mathTrunc=Math.trunc||function(e){e=+e;return(0<e?floor$1:ceil)(e)},trunc=mathTrunc,toIntegerOrInfinity$2=function(e){e=+e;return e!=e||0==e?0:trunc(e)},toIntegerOrInfinity$1=toIntegerOrInfinity$2,max$1=Math.max,min$1=Math.min,toAbsoluteIndex$2=function(e,t){e=toIntegerOrInfinity$1(e);return e<0?max$1(e+t,0):min$1(e,t)},toIntegerOrInfinity=toIntegerOrInfinity$2,min=Math.min,toLength$1=function(e){return 0<e?min(toIntegerOrInfinity(e),9007199254740991):0},toLength=toLength$1,lengthOfArrayLike$5=function(e){return toLength(e.length)},toIndexedObject$3=toIndexedObject$5,toAbsoluteIndex$1=toAbsoluteIndex$2,lengthOfArrayLike$4=lengthOfArrayLike$5,createMethod$1=function(s){return function(e,t,n){var r,o=toIndexedObject$3(e),i=lengthOfArrayLike$4(o),a=toAbsoluteIndex$1(n,i);if(s&&t!=t){for(;a<i;)if((r=o[a++])!=r)return!0}else for(;a<i;a++)if((s||a in o)&&o[a]===t)return s||a||0;return!s&&-1}},arrayIncludes={includes:createMethod$1(!0),indexOf:createMethod$1(!1)},uncurryThis$8=functionUncurryThis,hasOwn$6=hasOwnProperty_1,toIndexedObject$2=toIndexedObject$5,indexOf=arrayIncludes.indexOf,hiddenKeys$2=hiddenKeys$4,push$1=uncurryThis$8([].push),objectKeysInternal=function(e,t){var n,r=toIndexedObject$2(e),o=0,i=[];for(n in r)!hasOwn$6(hiddenKeys$2,n)&&hasOwn$6(r,n)&&push$1(i,n);for(;t.length>o;)!hasOwn$6(r,n=t[o++])||~indexOf(i,n)||push$1(i,n);return i},enumBugKeys$3=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],internalObjectKeys$1=objectKeysInternal,enumBugKeys$2=enumBugKeys$3,hiddenKeys$1=enumBugKeys$3.concat("length","prototype"),objectGetOwnPropertySymbols=(objectGetOwnPropertyNames.f=Object.getOwnPropertyNames||function(e){return internalObjectKeys$1(e,hiddenKeys$1)},{}),getBuiltIn$5=(objectGetOwnPropertySymbols.f=Object.getOwnPropertySymbols,getBuiltIn$8),uncurryThis$7=functionUncurryThis,getOwnPropertyNamesModule=objectGetOwnPropertyNames,getOwnPropertySymbolsModule$1=objectGetOwnPropertySymbols,anObject$a=anObject$c,concat$1=functionUncurryThis([].concat),ownKeys$1=getBuiltIn$5("Reflect","ownKeys")||function(e){var t=getOwnPropertyNamesModule.f(anObject$a(e)),n=getOwnPropertySymbolsModule$1.f;return n?concat$1(t,n(e)):t},hasOwn$5=hasOwnProperty_1,ownKeys=ownKeys$1,getOwnPropertyDescriptorModule=objectGetOwnPropertyDescriptor,definePropertyModule$3=objectDefineProperty,copyConstructorProperties$2=function(e,t,n){for(var r=ownKeys(t),o=definePropertyModule$3.f,i=getOwnPropertyDescriptorModule.f,a=0;a<r.length;a++){var s=r[a];hasOwn$5(e,s)||n&&hasOwn$5(n,s)||o(e,s,i(t,s))}},fails$8=fails$g,isCallable$b=isCallable$l,replacement=/#|\.prototype\./,isForced$2=function(e,t){e=data[normalize(e)];return e==POLYFILL||e!=NATIVE&&(isCallable$b(t)?fails$8(t):!!t)},normalize=isForced$2.normalize=function(e){return String(e).replace(replacement,".").toLowerCase()},data=isForced$2.data={},NATIVE=isForced$2.NATIVE="N",POLYFILL=isForced$2.POLYFILL="P",isForced_1=isForced$2,global$b=global$k,getOwnPropertyDescriptor$1=objectGetOwnPropertyDescriptor.f,createNonEnumerableProperty$2=createNonEnumerableProperty$4,defineBuiltIn$5=defineBuiltIn$6,defineGlobalProperty=defineGlobalProperty$3,copyConstructorProperties$1=copyConstructorProperties$2,isForced$1=isForced_1,_export=function(e,t){var n,r,o,i=e.target,a=e.global,s=e.stat,l=a?global$b:s?global$b[i]||defineGlobalProperty(i,{}):(global$b[i]||{}).prototype;if(l)for(n in t){if(r=t[n],o=e.dontCallGetSet?(o=getOwnPropertyDescriptor$1(l,n))&&o.value:l[n],!isForced$1(a?n:i+(s?".":"#")+n,e.forced)&&void 0!==o){if(typeof r==typeof o)continue;copyConstructorProperties$1(r,o)}(e.sham||o&&o.sham)&&createNonEnumerableProperty$2(r,"sham",!0),defineBuiltIn$5(l,n,r,e)}},internalObjectKeys=objectKeysInternal,enumBugKeys$1=enumBugKeys$3,objectKeys$2=Object.keys||function(e){return internalObjectKeys(e,enumBugKeys$1)},DESCRIPTORS$4=descriptors,uncurryThis$6=functionUncurryThis,call$a=functionCall,fails$7=fails$g,objectKeys$1=objectKeys$2,getOwnPropertySymbolsModule=objectGetOwnPropertySymbols,propertyIsEnumerableModule=objectPropertyIsEnumerable,toObject$3=toObject$5,IndexedObject$1=indexedObject,$assign=Object.assign,defineProperty$4=Object.defineProperty,concat=uncurryThis$6([].concat),objectAssign=!$assign||fails$7(function(){if(DESCRIPTORS$4&&1!==$assign({b:1},$assign(defineProperty$4({},"a",{enumerable:!0,get:function(){defineProperty$4(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=$assign({},e)[n]||objectKeys$1($assign({},t)).join("")!=r})?function(e,t){for(var n=toObject$3(e),r=arguments.length,o=1,i=getOwnPropertySymbolsModule.f,a=propertyIsEnumerableModule.f;o<r;)for(var s,l=IndexedObject$1(arguments[o++]),c=i?concat(objectKeys$1(l),i(l)):objectKeys$1(l),p=c.length,u=0;u<p;)s=c[u++],DESCRIPTORS$4&&!call$a(a,l,s)||(n[s]=l[s]);return n}:$assign,$$a=_export,assign=objectAssign,objectDefineProperties=(_export({target:"Object",stat:!0,arity:2,forced:Object.assign!==assign},{assign:assign}),{}),DESCRIPTORS$3=descriptors,V8_PROTOTYPE_DEFINE_BUG=v8PrototypeDefineBug,definePropertyModule$2=objectDefineProperty,anObject$9=anObject$c,toIndexedObject$1=toIndexedObject$5,objectKeys=objectKeys$2,getBuiltIn$4=(objectDefineProperties.f=DESCRIPTORS$3&&!V8_PROTOTYPE_DEFINE_BUG?Object.defineProperties:function(e,t){anObject$9(e);for(var n,r=toIndexedObject$1(t),o=objectKeys(t),i=o.length,a=0;a<i;)definePropertyModule$2.f(e,n=o[a++],r[n]);return e},getBuiltIn$8),html$2=getBuiltIn$8("document","documentElement"),anObject$8=anObject$c,definePropertiesModule=objectDefineProperties,enumBugKeys=enumBugKeys$3,hiddenKeys=hiddenKeys$4,html$1=html$2,documentCreateElement$1=documentCreateElement$2,sharedKey$1=sharedKey$3,GT=">",LT="<",PROTOTYPE="prototype",SCRIPT="script",IE_PROTO$1=sharedKey$3("IE_PROTO"),EmptyConstructor=function(){},scriptTag=function(e){return LT+SCRIPT+GT+e+LT+"/"+SCRIPT+GT},NullProtoObjectViaActiveX=function(e){e.write(scriptTag("")),e.close();var t=e.parentWindow.Object;return e=null,t},NullProtoObjectViaIFrame=function(){var e=documentCreateElement$1("iframe"),t="java"+SCRIPT+":";return e.style.display="none",html$1.appendChild(e),e.src=String(t),(t=e.contentWindow.document).open(),t.write(scriptTag("document.F=Object")),t.close(),t.F},NullProtoObject=function(){try{activeXDocument=new ActiveXObject("htmlfile")}catch(e){}NullProtoObject="undefined"==typeof document||document.domain&&activeXDocument?NullProtoObjectViaActiveX(activeXDocument):NullProtoObjectViaIFrame();for(var e=enumBugKeys.length;e--;)delete NullProtoObject[PROTOTYPE][enumBugKeys[e]];return NullProtoObject()},objectCreate=(hiddenKeys[IE_PROTO$1]=!0,Object.create||function(e,t){var n;return null!==e?(EmptyConstructor[PROTOTYPE]=anObject$8(e),n=new EmptyConstructor,EmptyConstructor[PROTOTYPE]=null,n[IE_PROTO$1]=e):n=NullProtoObject(),void 0===t?n:definePropertiesModule.f(n,t)}),wellKnownSymbol$c=wellKnownSymbol$e,create$1=objectCreate,defineProperty$3=objectDefineProperty.f,UNSCOPABLES=wellKnownSymbol$c("unscopables"),ArrayPrototype$1=Array.prototype,addToUnscopables$1=(null==ArrayPrototype$1[UNSCOPABLES]&&defineProperty$3(ArrayPrototype$1,UNSCOPABLES,{configurable:!0,value:create$1(null)}),function(e){ArrayPrototype$1[UNSCOPABLES][e]=!0}),iterators={},fails$6=fails$g,correctPrototypeGetter=!fails$g(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),hasOwn$4=hasOwnProperty_1,isCallable$a=isCallable$l,toObject$2=toObject$5,sharedKey=sharedKey$3,CORRECT_PROTOTYPE_GETTER=correctPrototypeGetter,IE_PROTO=sharedKey$3("IE_PROTO"),$Object$1=Object,ObjectPrototype=$Object$1.prototype,objectGetPrototypeOf=CORRECT_PROTOTYPE_GETTER?$Object$1.getPrototypeOf:function(e){e=toObject$2(e);if(hasOwn$4(e,IE_PROTO))return e[IE_PROTO];var t=e.constructor;return isCallable$a(t)&&e instanceof t?t.prototype:e instanceof $Object$1?ObjectPrototype:null},fails$5=fails$g,isCallable$9=isCallable$l,getPrototypeOf$1=objectGetPrototypeOf,defineBuiltIn$4=defineBuiltIn$6,wellKnownSymbol$b=wellKnownSymbol$e,ITERATOR$5=wellKnownSymbol$e("iterator"),BUGGY_SAFARI_ITERATORS$1=!1,NEW_ITERATOR_PROTOTYPE=([].keys&&("next"in(arrayIterator=[].keys())?(PrototypeOfArrayIteratorPrototype=getPrototypeOf$1(getPrototypeOf$1(arrayIterator)))!==Object.prototype&&(IteratorPrototype$2=PrototypeOfArrayIteratorPrototype):BUGGY_SAFARI_ITERATORS$1=!0),null==IteratorPrototype$2||fails$5(function(){var e={};return IteratorPrototype$2[ITERATOR$5].call(e)!==e})),iteratorsCore=(isCallable$9((IteratorPrototype$2=NEW_ITERATOR_PROTOTYPE?{}:IteratorPrototype$2)[ITERATOR$5])||defineBuiltIn$4(IteratorPrototype$2,ITERATOR$5,function(){return this}),{IteratorPrototype:IteratorPrototype$2,BUGGY_SAFARI_ITERATORS:BUGGY_SAFARI_ITERATORS$1}),defineProperty$2=objectDefineProperty.f,hasOwn$3=hasOwnProperty_1,wellKnownSymbol$a=wellKnownSymbol$e,TO_STRING_TAG$3=wellKnownSymbol$e("toStringTag"),setToStringTag$3=function(e,t,n){(e=e&&!n?e.prototype:e)&&!hasOwn$3(e,TO_STRING_TAG$3)&&defineProperty$2(e,TO_STRING_TAG$3,{configurable:!0,value:t})},IteratorPrototype$1=iteratorsCore.IteratorPrototype,create=objectCreate,createPropertyDescriptor$1=createPropertyDescriptor$4,setToStringTag$2=setToStringTag$3,Iterators$4=iterators,returnThis$1=function(){return this},createIteratorConstructor$1=function(e,t,n,r){t+=" Iterator";return e.prototype=create(IteratorPrototype$1,{next:createPropertyDescriptor$1(+!r,n)}),setToStringTag$2(e,t,!1),Iterators$4[t]=returnThis$1,e},isCallable$8=isCallable$l,$String$1=String,$TypeError$7=TypeError,aPossiblePrototype$1=function(e){if("object"==typeof e||isCallable$8(e))return e;throw $TypeError$7("Can't set "+$String$1(e)+" as a prototype")},uncurryThis$5=functionUncurryThis,anObject$7=anObject$c,aPossiblePrototype=aPossiblePrototype$1,objectSetPrototypeOf=Object.setPrototypeOf||("__proto__"in{}?function(){var n,r=!1,e={};try{(n=uncurryThis$5(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(e,[]),r=e instanceof Array}catch(e){}return function(e,t){return anObject$7(e),aPossiblePrototype(t),r?n(e,t):e.__proto__=t,e}}():void 0),$$9=_export,call$9=functionCall,FunctionName=functionName,isCallable$7=isCallable$l,createIteratorConstructor=createIteratorConstructor$1,getPrototypeOf=objectGetPrototypeOf,setPrototypeOf$1=objectSetPrototypeOf,setToStringTag$1=setToStringTag$3,createNonEnumerableProperty$1=createNonEnumerableProperty$4,defineBuiltIn$3=defineBuiltIn$6,wellKnownSymbol$9=wellKnownSymbol$e,Iterators$3=iterators,IteratorsCore=iteratorsCore,PROPER_FUNCTION_NAME$1=FunctionName.PROPER,CONFIGURABLE_FUNCTION_NAME=FunctionName.CONFIGURABLE,IteratorPrototype=IteratorsCore.IteratorPrototype,BUGGY_SAFARI_ITERATORS=IteratorsCore.BUGGY_SAFARI_ITERATORS,ITERATOR$4=wellKnownSymbol$9("iterator"),KEYS="keys",VALUES="values",ENTRIES="entries",returnThis=function(){return this},defineIterator$1=function(e,t,n,r,o,i,a){createIteratorConstructor(n,t,r);function s(e){if(e===o&&$)return $;if(!BUGGY_SAFARI_ITERATORS&&e in u)return u[e];switch(e){case KEYS:case VALUES:case ENTRIES:return function(){return new n(this,e)}}return function(){return new n(this)}}var l,c,r=t+" Iterator",p=!1,u=e.prototype,d=u[ITERATOR$4]||u["@@iterator"]||o&&u[o],$=!BUGGY_SAFARI_ITERATORS&&d||s(o),g="Array"==t&&u.entries||d;if(g&&(g=getPrototypeOf(g.call(new e)))!==Object.prototype&&g.next&&(getPrototypeOf(g)!==IteratorPrototype&&(setPrototypeOf$1?setPrototypeOf$1(g,IteratorPrototype):isCallable$7(g[ITERATOR$4])||defineBuiltIn$3(g,ITERATOR$4,returnThis)),setToStringTag$1(g,r,!0)),PROPER_FUNCTION_NAME$1&&o==VALUES&&d&&d.name!==VALUES&&(CONFIGURABLE_FUNCTION_NAME?createNonEnumerableProperty$1(u,"name",VALUES):(p=!0,$=function(){return call$9(d,this)})),o)if(l={values:s(VALUES),keys:i?$:s(KEYS),entries:s(ENTRIES)},a)for(c in l)!BUGGY_SAFARI_ITERATORS&&!p&&c in u||defineBuiltIn$3(u,c,l[c]);else $$9({target:t,proto:!0,forced:BUGGY_SAFARI_ITERATORS||p},l);return u[ITERATOR$4]!==$&&defineBuiltIn$3(u,ITERATOR$4,$,{name:o}),Iterators$3[t]=$,l},toIndexedObject=toIndexedObject$5,addToUnscopables=addToUnscopables$1,Iterators$2=iterators,InternalStateModule$1=internalState,defineProperty$1=objectDefineProperty.f,defineIterator=defineIterator$1,DESCRIPTORS$2=descriptors,ARRAY_ITERATOR="Array Iterator",setInternalState$1=InternalStateModule$1.set,getInternalState=InternalStateModule$1.getterFor(ARRAY_ITERATOR),es_array_iterator=defineIterator(Array,"Array",function(e,t){setInternalState$1(this,{type:ARRAY_ITERATOR,target:toIndexedObject(e),index:0,kind:t})},function(){var e=getInternalState(this),t=e.target,n=e.kind,r=e.index++;return!t||r>=t.length?{value:e.target=void 0,done:!0}:"keys"==n?{value:r,done:!1}:"values"==n?{value:t[r],done:!1}:{value:[r,t[r]],done:!1}},"values"),values=Iterators$2.Arguments=Iterators$2.Array;if(addToUnscopables("keys"),addToUnscopables("values"),addToUnscopables("entries"),DESCRIPTORS$2&&"values"!==values.name)try{defineProperty$1(values,"name",{value:"values"})}catch(e){}var COLLECTION_NAME,domIterables={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},documentCreateElement=documentCreateElement$2,classList=documentCreateElement$2("span").classList,DOMTokenListPrototype$1=classList&&classList.constructor&&classList.constructor.prototype,domTokenListPrototype=DOMTokenListPrototype$1===Object.prototype?void 0:DOMTokenListPrototype$1,global$a=global$k,DOMIterables=domIterables,DOMTokenListPrototype=domTokenListPrototype,ArrayIteratorMethods=es_array_iterator,createNonEnumerableProperty=createNonEnumerableProperty$4,wellKnownSymbol$8=wellKnownSymbol$e,ITERATOR$3=wellKnownSymbol$8("iterator"),TO_STRING_TAG$2=wellKnownSymbol$8("toStringTag"),ArrayValues=ArrayIteratorMethods.values,handlePrototype=function(t,e){if(t){if(t[ITERATOR$3]!==ArrayValues)try{createNonEnumerableProperty(t,ITERATOR$3,ArrayValues)}catch(e){t[ITERATOR$3]=ArrayValues}if(t[TO_STRING_TAG$2]||createNonEnumerableProperty(t,TO_STRING_TAG$2,e),DOMIterables[e])for(var n in ArrayIteratorMethods)if(t[n]!==ArrayIteratorMethods[n])try{createNonEnumerableProperty(t,n,ArrayIteratorMethods[n])}catch(e){t[n]=ArrayIteratorMethods[n]}}};for(COLLECTION_NAME in DOMIterables)handlePrototype(global$a[COLLECTION_NAME]&&global$a[COLLECTION_NAME].prototype,COLLECTION_NAME);handlePrototype(DOMTokenListPrototype,"DOMTokenList");var EmptyStringDescriptionStore,SymbolWrapper,NATIVE_SYMBOL,symbolToString,symbolValueOf,regexp,replace,stringSlice,EApplicationStatus,EConfigTypes,wellKnownSymbol$7=wellKnownSymbol$e,TO_STRING_TAG$1=wellKnownSymbol$e("toStringTag"),test$1={},toStringTagSupport=(test$1[TO_STRING_TAG$1]="z","[object z]"===String(test$1)),TO_STRING_TAG_SUPPORT=toStringTagSupport,isCallable$6=isCallable$l,classofRaw=classofRaw$1,wellKnownSymbol$6=wellKnownSymbol$e,TO_STRING_TAG=wellKnownSymbol$e("toStringTag"),$Object=Object,CORRECT_ARGUMENTS="Arguments"==classofRaw(function(){return arguments}()),tryGet=function(e,t){try{return e[t]}catch(e){}},classof$4=TO_STRING_TAG_SUPPORT?classofRaw:function(e){var t;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(t=tryGet(e=$Object(e),TO_STRING_TAG))?t:CORRECT_ARGUMENTS?classofRaw(e):"Object"==(t=classofRaw(e))&&isCallable$6(e.callee)?"Arguments":t},classof$3=classof$4,$String=String,toString$2=function(e){if("Symbol"===classof$3(e))throw TypeError("Cannot convert a Symbol value to a string");return $String(e)},$$8=_export,DESCRIPTORS$1=descriptors,global$9=global$k,uncurryThis$4=functionUncurryThis,hasOwn$2=hasOwnProperty_1,isCallable$5=isCallable$l,isPrototypeOf$3=objectIsPrototypeOf,toString$1=toString$2,defineProperty=objectDefineProperty.f,copyConstructorProperties=copyConstructorProperties$2,NativeSymbol=global$9.Symbol,SymbolPrototype=NativeSymbol&&NativeSymbol.prototype,anObject$6=(!DESCRIPTORS$1||!isCallable$5(NativeSymbol)||"description"in SymbolPrototype&&void 0===NativeSymbol().description||(EmptyStringDescriptionStore={},copyConstructorProperties(SymbolWrapper=function(){var e=arguments.length<1||void 0===arguments[0]?void 0:toString$1(arguments[0]),t=isPrototypeOf$3(SymbolPrototype,this)?new NativeSymbol(e):void 0===e?NativeSymbol():NativeSymbol(e);return""===e&&(EmptyStringDescriptionStore[t]=!0),t},NativeSymbol),(SymbolWrapper.prototype=SymbolPrototype).constructor=SymbolWrapper,NATIVE_SYMBOL="Symbol(test)"==String(NativeSymbol("test")),symbolToString=uncurryThis$4(SymbolPrototype.toString),symbolValueOf=uncurryThis$4(SymbolPrototype.valueOf),regexp=/^Symbol\((.*)\)[^)]+$/,replace=uncurryThis$4("".replace),stringSlice=uncurryThis$4("".slice),defineProperty(SymbolPrototype,"description",{configurable:!0,get:function(){var e=symbolValueOf(this),t=symbolToString(e);if(hasOwn$2(EmptyStringDescriptionStore,e))return"";e=NATIVE_SYMBOL?stringSlice(t,7,-1):replace(t,regexp,"$1");return""===e?void 0:e}}),$$8({global:!0,constructor:!0,forced:!0},{Symbol:SymbolWrapper})),anObject$c),regexpFlags=function(){var e=anObject$6(this),t="";return e.hasIndices&&(t+="d"),e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.unicodeSets&&(t+="v"),e.sticky&&(t+="y"),t},call$8=functionCall,hasOwn$1=hasOwnProperty_1,isPrototypeOf$2=objectIsPrototypeOf,regExpFlags=regexpFlags,RegExpPrototype$1=RegExp.prototype,regexpGetFlags=function(e){var t=e.flags;return void 0!==t||"flags"in RegExpPrototype$1||hasOwn$1(e,"flags")||!isPrototypeOf$2(RegExpPrototype$1,e)?t:call$8(regExpFlags,e)},PROPER_FUNCTION_NAME=functionName.PROPER,defineBuiltIn$2=defineBuiltIn$6,anObject$5=anObject$c,$toString=toString$2,fails$4=fails$g,getRegExpFlags=regexpGetFlags,TO_STRING="toString",RegExpPrototype=RegExp.prototype,n$ToString=RegExpPrototype[TO_STRING],NOT_GENERIC=fails$4(function(){return"/a/b"!=n$ToString.call({source:"a",flags:"b"})}),INCORRECT_NAME=PROPER_FUNCTION_NAME&&n$ToString.name!=TO_STRING;(NOT_GENERIC||INCORRECT_NAME)&&defineBuiltIn$2(RegExp.prototype,TO_STRING,function(){var e=anObject$5(this);return"/"+$toString(e.source)+"/"+$toString(getRegExpFlags(e))},{unsafe:!0});const ApplicationListItem=({app:e,onOpenApplicationDetailPanel:t,showInstalledChip:n=!1,isAppInstalled:r})=>{const{name:o,description:i,iconUrl:a,id:s,ownerOrganizationId:l}=e,c=useSelector(selectOrgId);var e=c&&l&&l.toString()===c.toString(),p={height:"18px",borderRadius:"30px",mb:1},u={fontWeight:"800",fontSize:"9px",lineHeight:"12px",textTransform:"uppercase"};return jsxRuntime.exports.jsxs(react.exports.Fragment,{children:[jsxRuntime.exports.jsxs(ListItem,Object.assign({alignItems:"center",sx:{minHeight:"134px",p:4}},{children:[jsxRuntime.exports.jsx(ListItemAvatar,Object.assign({sx:{alignSelf:"flex-start"}},{children:jsxRuntime.exports.jsx(Avatar,Object.assign({src:a,alt:o},{children:jsxRuntime.exports.jsx(Avatar,{children:o[0]})}))})),jsxRuntime.exports.jsx(ListItemText,{sx:{display:"inline",maxWidth:"390px",alignSelf:"flex-start",m:0},primary:jsxRuntime.exports.jsxs(react.exports.Fragment,{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"body2",sx:{color:"#2A323C",fontWeight:"400"}},{children:o})),jsxRuntime.exports.jsxs(Stack,Object.assign({direction:"row",spacing:1},{children:[n&&r&&r(s)&&jsxRuntime.exports.jsx(Chip$1,{label:jsxRuntime.exports.jsx(Typography$1,Object.assign({sx:Object.assign({color:green[700]},u)},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center-applications-installed-badge-123132",defaultMessage:"Installed",description:"installed application badge"})})),color:"success",size:"small",sx:Object.assign({background:"rgba(27, 94, 32, 0.2)",width:"70px"},p)}),e&&jsxRuntime.exports.jsx(Chip$1,{icon:jsxRuntime.exports.jsx(Lock,{style:{height:"12px",width:"12px"}}),label:jsxRuntime.exports.jsx(Typography$1,Object.assign({sx:Object.assign({color:"#4F5863"},u)},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center-applications-org-owned-badge-123112",defaultMessage:"org owned",description:"org owned application badge"})})),variant:"outlined",size:"small",sx:Object.assign({width:"90px"},p)})]}))]}),secondary:jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"body2",sx:{mt:1}},{children:i}))}),jsxRuntime.exports.jsx(ListItemSecondaryAction,{children:jsxRuntime.exports.jsx(Button,Object.assign({onClick:t,variant:"outlined",color:"primary"},{children:"View Details"}))})]})),jsxRuntime.exports.jsx(Divider,{})]})},LoaderSkeletonItem=()=>jsxRuntime.exports.jsxs(ListItem,Object.assign({alignItems:"center",sx:{height:"134px"}},{children:[jsxRuntime.exports.jsx(ListItemAvatar,{children:jsxRuntime.exports.jsx(Skeleton$1,{variant:"circular",width:40,height:40})}),jsxRuntime.exports.jsx(ListItemText,{children:jsxRuntime.exports.jsx(Skeleton$1,{variant:"text",width:150,height:30})}),jsxRuntime.exports.jsx(ListItemSecondaryAction,{children:jsxRuntime.exports.jsx(Skeleton$1,{variant:"rectangular",width:87,height:35})})]})),LoaderSkeleton=()=>jsxRuntime.exports.jsxs(List,{children:[jsxRuntime.exports.jsx(LoaderSkeletonItem,{}),jsxRuntime.exports.jsx(Divider,{}),jsxRuntime.exports.jsx(LoaderSkeletonItem,{}),jsxRuntime.exports.jsx(Divider,{}),jsxRuntime.exports.jsx(LoaderSkeletonItem,{}),jsxRuntime.exports.jsx(Divider,{})]}),ApplicationList=({apps:e,uiStatus:t,onRetry:n,showInstalledChip:r=!1,isAppInstalled:o})=>{const i=useDispatch();return"loading"===t?jsxRuntime.exports.jsx(LoaderSkeleton,{}):"failure"===t?jsxRuntime.exports.jsx(ErrorState,{onRetry:n,errorMessage:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.error-message",defaultMessage:"Something went wrong while loading applications.",description:"admin center applications error state"})}):jsxRuntime.exports.jsx(List,Object.assign({sx:{maxHeight:"95%",overflowY:"auto"}},{children:e.map(e=>jsxRuntime.exports.jsx(ApplicationListItem,{app:e,onOpenApplicationDetailPanel:(e=>()=>{i(mountPanel({panelId:"APPLICATION_DETAILS_PANEL",microFrontend:{name:"APPLICATION_DETAILS_PANEL",config:{applicationId:e.id,initValue:e}},panelConfig:{type:"APP_BAR_PANEL_TEMPLATE",marginTop:55,marginStart:80,size:"large",zIndex:1002,parentPanelId:"ADMIN_CENTER_BROWSE",dimmed:0,dimmedStatus:"dimParent"}}))})(e),showInstalledChip:r,isAppInstalled:o}))}))},SLICE_NAME$1="adminCenterApplication",namespace$2=(!function(e){e.active="active",e.draft="draft",e.deleted="deleted",e.pending="pending",e.rejected="rejected",e.approved="approved",e.disabled="disabled"}(EApplicationStatus=EApplicationStatus||{}),!function(e){e.string="String",e.json="JSON",e.boolean="Boolean"}(EConfigTypes=EConfigTypes||{}),"adminCenterApplications"),initialState$2={allApplications:[],installedApplications:[],allAppStatus:"idle",installedAppStatus:"idle"},adminCenterApplicationSlice=createSlice({name:SLICE_NAME$1+"/"+namespace$2,initialState:initialState$2,reducers:{fetchAllApplicationsStart(e){e.allAppStatus="loading"},fetchAllApplicationsSuccess(e,t){e.allAppStatus="success",e.allApplications=t.payload},fetchAllApplicationsFailure(e){e.allAppStatus="failure"},fetchInstalledApplicationsStart(e){e.installedAppStatus="loading"},fetchInstalledApplicationsSuccess(e,t){e.installedAppStatus="success",e.installedApplications=t.payload},fetchInstalledApplicationsFailure(e){e.installedAppStatus="failure"}}}),actions$2=adminCenterApplicationSlice.actions;var Status,adminCenterApplications_state=adminCenterApplicationSlice.reducer;const selectInstalledApps=e=>{return null==(e=null==(e=null==e?void 0:e[SLICE_NAME$1])?void 0:e[namespace$2])?void 0:e.installedApplications},selectAllApps=e=>{return null==(e=null==(e=null==e?void 0:e[SLICE_NAME$1])?void 0:e[namespace$2])?void 0:e.allApplications},selectAllAppsUiStatus=e=>{return null==(e=null==(e=null==e?void 0:e[SLICE_NAME$1])?void 0:e[namespace$2])?void 0:e.allAppStatus},selectInstalledAppsUiStatus=e=>{return null==(e=null==(e=null==e?void 0:e[SLICE_NAME$1])?void 0:e[namespace$2])?void 0:e.installedAppStatus},selectApiConfigs=createSelector([rootApiSelector,graphEndpointSelector,sessionTokenSelector],(e,t,n)=>({apiRoot:e,graphQLEndpoint:t,token:n}));function __rest(e,t){var n={};for(o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,o=Object.getOwnPropertySymbols(e);r<o.length;r++)t.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]]);return n}function __awaiter(e,a,s,l){return new(s=s||Promise)(function(n,t){function r(e){try{i(l.next(e))}catch(e){t(e)}}function o(e){try{i(l.throw(e))}catch(e){t(e)}}function i(e){var t;e.done?n(e.value):((t=e.value)instanceof s?t:new s(function(e){e(t)})).then(r,o)}i((l=l.apply(e,a||[])).next())})}const SLICE_NAME="applications",namespace$1=(!function(e){e.idle="idle",e.loading="loading",e.success="success",e.failure="failure"}(Status=Status||{}),"applicationDetail"),initialState$1={status:"idle",application:{},ownerOrganization:{name:""}},applicationDetailSlice=createSlice({name:SLICE_NAME+"/"+namespace$1,initialState:initialState$1,reducers:{setInitialApplicationValue(e,t){var n=t.payload,r=n["ownerOrganization"],n=__rest(n,["ownerOrganization"]);e.initValue=t.payload,e.application=n,e.ownerOrganization=r,e.status=Status.success},fetchApplicationStart(e,t){var n,{applicationId:t,initValue:r}=t.payload;e.applicationId=t,r?(t=r["ownerOrganization"],n=__rest(r,["ownerOrganization"]),e.initValue=r,e.application=n,e.ownerOrganization=t,e.status=Status.success):e.status=Status.loading},fetchApplicationSuccess(e,t){var{application:t,organization:n}=t.payload;e.application=t,e.ownerOrganization=n,e.status=Status.success},fetchApplicationError(e,t){e.status=Status.failure},setStatus(e,t){e.status=t.payload},installAppStart(e,t){e.status=Status.loading},installAppSuccess(e,t){e.status=Status.success,e.application=t.payload},installAppFailure(e){e.status=Status.failure}}}),actions$1=applicationDetailSlice.actions;var applicationDetailsPanelReducer=applicationDetailSlice.reducer;const namespace=SLICE_NAME$1,initialState={[namespace$2]:initialState$2,[namespace$1]:initialState$1},actions={[namespace$2]:actions$2,[namespace$1]:actions$1},rootReducer=combineReducers({[namespace$2]:adminCenterApplications_state,[namespace$1]:applicationDetailsPanelReducer});var location,defer,channel,port,tryToString$3=tryToString$5,$TypeError$6=TypeError,deletePropertyOrThrow$1=function(e,t){if(!delete e[t])throw $TypeError$6("Cannot delete property "+tryToString$3(t)+" of "+tryToString$3(e))},toPropertyKey=toPropertyKey$3,definePropertyModule$1=objectDefineProperty,createPropertyDescriptor=createPropertyDescriptor$4,createProperty$1=function(e,t,n){t=toPropertyKey(t);t in e?definePropertyModule$1.f(e,t,createPropertyDescriptor(0,n)):e[t]=n},toAbsoluteIndex=toAbsoluteIndex$2,lengthOfArrayLike$3=lengthOfArrayLike$5,createProperty=createProperty$1,$Array=Array,max=Math.max,arraySliceSimple=function(e,t,n){for(var r=lengthOfArrayLike$3(e),o=toAbsoluteIndex(t,r),i=toAbsoluteIndex(void 0===n?r:n,r),a=$Array(max(i-o,0)),s=0;o<i;o++,s++)createProperty(a,s,e[o]);return a.length=s,a},arraySlice$2=arraySliceSimple,floor=Math.floor,mergeSort=function(e,t){var n=e.length,r=floor(n/2);return n<8?insertionSort(e,t):merge(e,mergeSort(arraySlice$2(e,0,r),t),mergeSort(arraySlice$2(e,r),t),t)},insertionSort=function(e,t){for(var n,r,o=e.length,i=1;i<o;){for(n=e[r=i];r&&0<t(e[r-1],n);)e[r]=e[--r];r!==i++&&(e[r]=n)}return e},merge=function(e,t,n,r){for(var o=t.length,i=n.length,a=0,s=0;a<o||s<i;)e[a+s]=a<o&&s<i?r(t[a],n[s])<=0?t[a++]:n[s++]:a<o?t[a++]:n[s++];return e},arraySort=mergeSort,fails$3=fails$g,arrayMethodIsStrict$2=function(e,t){var n=[][e];return!!n&&fails$3(function(){n.call(null,t||function(){return 1},1)})},userAgent$4=engineUserAgent,firefox=engineUserAgent.match(/firefox\/(\d+)/i),engineFfVersion=!!firefox&&+firefox[1],UA=engineUserAgent,engineIsIeOrEdge=/MSIE|Trident/.test(UA),userAgent$3=engineUserAgent,webkit=engineUserAgent.match(/AppleWebKit\/(\d+)\./),engineWebkitVersion=!!webkit&&+webkit[1],$$7=_export,uncurryThis$3=functionUncurryThis,aCallable$7=aCallable$9,toObject$1=toObject$5,lengthOfArrayLike$2=lengthOfArrayLike$5,deletePropertyOrThrow=deletePropertyOrThrow$1,toString=toString$2,fails$2=fails$g,internalSort=arraySort,arrayMethodIsStrict$1=arrayMethodIsStrict$2,FF=engineFfVersion,IE_OR_EDGE=engineIsIeOrEdge,V8=engineV8Version,WEBKIT=engineWebkitVersion,test=[],un$Sort=uncurryThis$3(test.sort),push=uncurryThis$3(test.push),FAILS_ON_UNDEFINED=fails$2(function(){test.sort(void 0)}),FAILS_ON_NULL=fails$2(function(){test.sort(null)}),STRICT_METHOD$1=arrayMethodIsStrict$1("sort"),STABLE_SORT=!fails$2(function(){if(V8)return V8<70;if(!(FF&&3<FF)){if(IE_OR_EDGE)return!0;if(WEBKIT)return WEBKIT<603;for(var e,t,n,r="",o=65;o<76;o++){switch(e=String.fromCharCode(o),o){case 66:case 69:case 70:case 72:t=3;break;case 68:case 71:t=4;break;default:t=2}for(n=0;n<47;n++)test.push({k:e+n,v:t})}for(test.sort(function(e,t){return t.v-e.v}),n=0;n<test.length;n++)e=test[n].k.charAt(0),r.charAt(r.length-1)!==e&&(r+=e);return"DGBEFHACIJK"!==r}}),FORCED=FAILS_ON_UNDEFINED||!FAILS_ON_NULL||!STRICT_METHOD$1||!STABLE_SORT,getSortCompare=function(n){return function(e,t){return void 0===t?-1:void 0===e?1:void 0!==n?+n(e,t)||0:toString(e)>toString(t)?1:-1}},classof$2=($$7({target:"Array",proto:!0,forced:FORCED},{sort:function(e){void 0!==e&&aCallable$7(e);var t=toObject$1(this);if(STABLE_SORT)return void 0===e?un$Sort(t):un$Sort(t,e);for(var n,r=[],o=lengthOfArrayLike$2(t),i=0;i<o;i++)i in t&&push(r,t[i]);for(internalSort(r,getSortCompare(e)),n=r.length,i=0;i<n;)t[i]=r[i++];for(;i<o;)deletePropertyOrThrow(t,i++);return t}}),classofRaw$1),global$8=global$k,engineIsNode="process"==classofRaw$1(global$k.process),getBuiltIn$3=getBuiltIn$8,definePropertyModule=objectDefineProperty,wellKnownSymbol$5=wellKnownSymbol$e,DESCRIPTORS=descriptors,SPECIES$2=wellKnownSymbol$e("species"),setSpecies$1=function(e){var e=getBuiltIn$3(e),t=definePropertyModule.f;DESCRIPTORS&&e&&!e[SPECIES$2]&&t(e,SPECIES$2,{configurable:!0,get:function(){return this}})},isPrototypeOf$1=objectIsPrototypeOf,$TypeError$5=TypeError,anInstance$1=function(e,t){if(isPrototypeOf$1(t,e))return e;throw $TypeError$5("Incorrect invocation")},uncurryThis$2=functionUncurryThis,fails$1=fails$g,isCallable$4=isCallable$l,classof$1=classof$4,getBuiltIn$2=getBuiltIn$8,inspectSource$1=inspectSource$4,noop=function(){},empty=[],construct=getBuiltIn$8("Reflect","construct"),constructorRegExp=/^\s*(?:class|function)\b/,exec=uncurryThis$2(constructorRegExp.exec),INCORRECT_TO_STRING=!constructorRegExp.exec(noop),isConstructorModern=function(e){if(!isCallable$4(e))return!1;try{return construct(noop,empty,e),!0}catch(e){return!1}},isConstructorLegacy=function(e){if(!isCallable$4(e))return!1;switch(classof$1(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return INCORRECT_TO_STRING||!!exec(constructorRegExp,inspectSource$1(e))}catch(e){return!0}},isConstructor$1=(isConstructorLegacy.sham=!0,!construct||fails$1(function(){var e;return isConstructorModern(isConstructorModern.call)||!isConstructorModern(Object)||!isConstructorModern(function(){e=!0})||e})?isConstructorLegacy:isConstructorModern),isConstructor=isConstructor$1,tryToString$2=tryToString$5,$TypeError$4=TypeError,aConstructor$1=function(e){if(isConstructor(e))return e;throw $TypeError$4(tryToString$2(e)+" is not a constructor")},anObject$4=anObject$c,aConstructor=aConstructor$1,wellKnownSymbol$4=wellKnownSymbol$e,SPECIES$1=wellKnownSymbol$e("species"),speciesConstructor$1=function(e,t){var e=anObject$4(e).constructor;return void 0===e||null==(e=anObject$4(e)[SPECIES$1])?t:aConstructor(e)},NATIVE_BIND$1=functionBindNative,FunctionPrototype=Function.prototype,apply$1=FunctionPrototype.apply,call$7=FunctionPrototype.call,functionApply="object"==typeof Reflect&&Reflect.apply||(NATIVE_BIND$1?call$7.bind(apply$1):function(){return call$7.apply(apply$1,arguments)}),uncurryThis$1=functionUncurryThis,aCallable$6=aCallable$9,NATIVE_BIND=functionBindNative,bind$4=functionUncurryThis(functionUncurryThis.bind),functionBindContext=function(e,t){return aCallable$6(e),void 0===t?e:NATIVE_BIND?bind$4(e,t):function(){return e.apply(t,arguments)}},uncurryThis=functionUncurryThis,arraySlice$1=functionUncurryThis([].slice),$TypeError$3=TypeError,validateArgumentsLength$1=function(e,t){if(e<t)throw $TypeError$3("Not enough arguments");return e},userAgent$2=engineUserAgent,engineIsIos=/(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent$2),global$7=global$k,apply=functionApply,bind$3=functionBindContext,isCallable$3=isCallable$l,hasOwn=hasOwnProperty_1,fails=fails$g,html=html$2,arraySlice=arraySlice$1,createElement=documentCreateElement$2,validateArgumentsLength=validateArgumentsLength$1,IS_IOS$1=engineIsIos,IS_NODE$4=engineIsNode,set=global$7.setImmediate,clear=global$7.clearImmediate,process$3=global$7.process,Dispatch=global$7.Dispatch,Function$1=global$7.Function,MessageChannel=global$7.MessageChannel,String$1=global$7.String,counter=0,queue$1={},ONREADYSTATECHANGE="onreadystatechange";try{location=global$7.location}catch(e){}var flush,head,last,notify$1,toggle,node,promise,then,Internal,OwnPromiseCapability,PromiseWrapper,nativeThen,run=function(e){var t;hasOwn(queue$1,e)&&(t=queue$1[e],delete queue$1[e],t())},runner=function(e){return function(){run(e)}},listener=function(e){run(e.data)},post=function(e){global$7.postMessage(String$1(e),location.protocol+"//"+location.host)},task$1=(set&&clear||(set=function(e){validateArgumentsLength(arguments.length,1);var t=isCallable$3(e)?e:Function$1(e),n=arraySlice(arguments,1);return queue$1[++counter]=function(){apply(t,void 0,n)},defer(counter),counter},clear=function(e){delete queue$1[e]},IS_NODE$4?defer=function(e){process$3.nextTick(runner(e))}:Dispatch&&Dispatch.now?defer=function(e){Dispatch.now(runner(e))}:MessageChannel&&!IS_IOS$1?(port=(channel=new MessageChannel).port2,channel.port1.onmessage=listener,defer=bind$3(port.postMessage,port)):global$7.addEventListener&&isCallable$3(global$7.postMessage)&&!global$7.importScripts&&location&&"file:"!==location.protocol&&!fails(post)?(defer=post,global$7.addEventListener("message",listener,!1)):defer=ONREADYSTATECHANGE in createElement("script")?function(e){html.appendChild(createElement("script"))[ONREADYSTATECHANGE]=function(){html.removeChild(this),run(e)}}:function(e){setTimeout(runner(e),0)}),{set:set,clear:clear}),userAgent$1=engineUserAgent,global$6=global$k,engineIsIosPebble=/ipad|iphone|ipod/i.test(userAgent$1)&&void 0!==global$6.Pebble,userAgent=engineUserAgent,engineIsWebosWebkit=/web0s(?!.*chrome)/i.test(userAgent),global$5=global$k,bind$2=functionBindContext,getOwnPropertyDescriptor=objectGetOwnPropertyDescriptor.f,macrotask=task$1.set,IS_IOS=engineIsIos,IS_IOS_PEBBLE=engineIsIosPebble,IS_WEBOS_WEBKIT=engineIsWebosWebkit,IS_NODE$3=engineIsNode,MutationObserver=global$5.MutationObserver||global$5.WebKitMutationObserver,document$2=global$5.document,process$2=global$5.process,Promise$1=global$5.Promise,queueMicrotaskDescriptor=getOwnPropertyDescriptor(global$5,"queueMicrotask"),queueMicrotask=queueMicrotaskDescriptor&&queueMicrotaskDescriptor.value,microtask$1=(queueMicrotask||(flush=function(){var e,t;for(IS_NODE$3&&(e=process$2.domain)&&e.exit();head;){t=head.fn,head=head.next;try{t()}catch(e){throw head?notify$1():last=void 0,e}}last=void 0,e&&e.enter()},notify$1=IS_IOS||IS_NODE$3||IS_WEBOS_WEBKIT||!MutationObserver||!document$2?!IS_IOS_PEBBLE&&Promise$1&&Promise$1.resolve?((promise=Promise$1.resolve(void 0)).constructor=Promise$1,then=bind$2(promise.then,promise),function(){then(flush)}):IS_NODE$3?function(){process$2.nextTick(flush)}:(macrotask=bind$2(macrotask,global$5),function(){macrotask(flush)}):(toggle=!0,node=document$2.createTextNode(""),new MutationObserver(flush).observe(node,{characterData:!0}),function(){node.data=toggle=!toggle})),queueMicrotask||function(e){e={fn:e,next:void 0};last&&(last.next=e),head||(head=e,notify$1()),last=e}),global$4=global$k,hostReportErrors$1=function(e,t){var n=global$4.console;n&&n.error&&(1==arguments.length?n.error(e):n.error(e,t))},perform$3=function(e){try{return{error:!1,value:e()}}catch(e){return{error:!0,value:e}}},Queue$1=function(){this.head=null,this.tail=null},queue=(Queue$1.prototype={add:function(e){e={item:e,next:null};this.head?this.tail.next=e:this.head=e,this.tail=e},get:function(){var e=this.head;if(e)return this.head=e.next,this.tail===e&&(this.tail=null),e.item}},Queue$1),global$3=global$k,promiseNativeConstructor=global$k.Promise,engineIsDeno="object"==typeof Deno&&Deno&&"object"==typeof Deno.version,IS_DENO$1=engineIsDeno,IS_NODE$2=engineIsNode,engineIsBrowser=!engineIsDeno&&!engineIsNode&&"object"==typeof window&&"object"==typeof document,global$2=global$k,NativePromiseConstructor$3=promiseNativeConstructor,isCallable$2=isCallable$l,isForced=isForced_1,inspectSource=inspectSource$4,wellKnownSymbol$3=wellKnownSymbol$e,IS_BROWSER=engineIsBrowser,IS_DENO=engineIsDeno,V8_VERSION=engineV8Version,SPECIES=(NativePromiseConstructor$3&&NativePromiseConstructor$3.prototype,wellKnownSymbol$3("species")),SUBCLASSING=!1,NATIVE_PROMISE_REJECTION_EVENT$1=isCallable$2(global$2.PromiseRejectionEvent),FORCED_PROMISE_CONSTRUCTOR$5=isForced("Promise",function(){var e=inspectSource(NativePromiseConstructor$3),t=e!==String(NativePromiseConstructor$3);if(!t&&66===V8_VERSION)return!0;if(!V8_VERSION||V8_VERSION<51||!/native code/.test(e)){function n(e){e(function(){},function(){})}e=new NativePromiseConstructor$3(function(e){e(1)});if((e.constructor={})[SPECIES]=n,!(SUBCLASSING=e.then(function(){})instanceof n))return!0}return!t&&(IS_BROWSER||IS_DENO)&&!NATIVE_PROMISE_REJECTION_EVENT$1}),promiseConstructorDetection={CONSTRUCTOR:FORCED_PROMISE_CONSTRUCTOR$5,REJECTION_EVENT:NATIVE_PROMISE_REJECTION_EVENT$1,SUBCLASSING:SUBCLASSING},newPromiseCapability$2={},aCallable$5=aCallable$9,PromiseCapability=function(e){var n,r;this.promise=new e(function(e,t){if(void 0!==n||void 0!==r)throw TypeError("Bad Promise constructor");n=e,r=t}),this.resolve=aCallable$5(n),this.reject=aCallable$5(r)},$$6=(newPromiseCapability$2.f=function(e){return new PromiseCapability(e)},_export),IS_NODE$1=engineIsNode,global$1=global$k,call$6=functionCall,defineBuiltIn$1=defineBuiltIn$6,setPrototypeOf=objectSetPrototypeOf,setToStringTag=setToStringTag$3,setSpecies=setSpecies$1,aCallable$4=aCallable$9,isCallable$1=isCallable$l,isObject$1=isObject$7,anInstance=anInstance$1,speciesConstructor=speciesConstructor$1,task=task$1.set,microtask=microtask$1,hostReportErrors=hostReportErrors$1,perform$2=perform$3,Queue=queue,InternalStateModule=internalState,NativePromiseConstructor$2=promiseNativeConstructor,PromiseConstructorDetection=promiseConstructorDetection,newPromiseCapabilityModule$3=newPromiseCapability$2,PROMISE="Promise",FORCED_PROMISE_CONSTRUCTOR$4=PromiseConstructorDetection.CONSTRUCTOR,NATIVE_PROMISE_REJECTION_EVENT=PromiseConstructorDetection.REJECTION_EVENT,NATIVE_PROMISE_SUBCLASSING=PromiseConstructorDetection.SUBCLASSING,getInternalPromiseState=InternalStateModule.getterFor(PROMISE),setInternalState=InternalStateModule.set,NativePromisePrototype$1=NativePromiseConstructor$2&&NativePromiseConstructor$2.prototype,PromiseConstructor=NativePromiseConstructor$2,PromisePrototype=NativePromisePrototype$1,TypeError$1=global$1.TypeError,document$1=global$1.document,process$1=global$1.process,newPromiseCapability$1=newPromiseCapabilityModule$3.f,newGenericPromiseCapability=newPromiseCapability$1,DISPATCH_EVENT=!!(document$1&&document$1.createEvent&&global$1.dispatchEvent),UNHANDLED_REJECTION="unhandledrejection",REJECTION_HANDLED="rejectionhandled",PENDING=0,FULFILLED=1,REJECTED=2,HANDLED=1,UNHANDLED=2,isThenable=function(e){var t;return!(!isObject$1(e)||!isCallable$1(t=e.then))&&t},callReaction=function(e,t){var n,r,o,i=t.value,a=t.state==FULFILLED,s=a?e.ok:e.fail,l=e.resolve,c=e.reject,p=e.domain;try{s?(a||(t.rejection===UNHANDLED&&onHandleUnhandled(t),t.rejection=HANDLED),!0===s?n=i:(p&&p.enter(),n=s(i),p&&(p.exit(),o=!0)),n===e.promise?c(TypeError$1("Promise-chain cycle")):(r=isThenable(n))?call$6(r,n,l,c):l(n)):c(i)}catch(e){p&&!o&&p.exit(),c(e)}},notify=function(n,r){n.notified||(n.notified=!0,microtask(function(){for(var e,t=n.reactions;e=t.get();)callReaction(e,n);n.notified=!1,r&&!n.rejection&&onUnhandled(n)}))},dispatchEvent=function(e,t,n){var r;DISPATCH_EVENT?((r=document$1.createEvent("Event")).promise=t,r.reason=n,r.initEvent(e,!1,!0),global$1.dispatchEvent(r)):r={promise:t,reason:n},!NATIVE_PROMISE_REJECTION_EVENT&&(t=global$1["on"+e])?t(r):e===UNHANDLED_REJECTION&&hostReportErrors("Unhandled promise rejection",n)},onUnhandled=function(r){call$6(task,global$1,function(){var e=r.facade,t=r.value,n=isUnhandled(r);if(n&&(n=perform$2(function(){IS_NODE$1?process$1.emit("unhandledRejection",t,e):dispatchEvent(UNHANDLED_REJECTION,e,t)}),r.rejection=IS_NODE$1||isUnhandled(r)?UNHANDLED:HANDLED,n.error))throw n.value})},isUnhandled=function(e){return e.rejection!==HANDLED&&!e.parent},onHandleUnhandled=function(t){call$6(task,global$1,function(){var e=t.facade;IS_NODE$1?process$1.emit("rejectionHandled",e):dispatchEvent(REJECTION_HANDLED,e,t.value)})},bind$1=function(t,n,r){return function(e){t(n,e,r)}},internalReject=function(e,t,n){e.done||(e.done=!0,(e=n?n:e).value=t,e.state=REJECTED,notify(e,!0))},internalResolve=function(n,e,t){if(!n.done){n.done=!0,t&&(n=t);try{if(n.facade===e)throw TypeError$1("Promise can't be resolved itself");var r=isThenable(e);r?microtask(function(){var t={done:!1};try{call$6(r,e,bind$1(internalResolve,t,n),bind$1(internalReject,t,n))}catch(e){internalReject(t,e,n)}}):(n.value=e,n.state=FULFILLED,notify(n,!1))}catch(e){internalReject({done:!1},e,n)}}};if(FORCED_PROMISE_CONSTRUCTOR$4&&(PromisePrototype=(PromiseConstructor=function(e){anInstance(this,PromisePrototype),aCallable$4(e),call$6(Internal,this);var t=getInternalPromiseState(this);try{e(bind$1(internalResolve,t),bind$1(internalReject,t))}catch(e){internalReject(t,e)}}).prototype,(Internal=function(e){setInternalState(this,{type:PROMISE,done:!1,notified:!1,parent:!1,reactions:new Queue,rejection:!1,state:PENDING,value:void 0})}).prototype=defineBuiltIn$1(PromisePrototype,"then",function(e,t){var n=getInternalPromiseState(this),r=newPromiseCapability$1(speciesConstructor(this,PromiseConstructor));return n.parent=!0,r.ok=!isCallable$1(e)||e,r.fail=isCallable$1(t)&&t,r.domain=IS_NODE$1?process$1.domain:void 0,n.state==PENDING?n.reactions.add(r):microtask(function(){callReaction(r,n)}),r.promise}),OwnPromiseCapability=function(){var e=new Internal,t=getInternalPromiseState(e);this.promise=e,this.resolve=bind$1(internalResolve,t),this.reject=bind$1(internalReject,t)},newPromiseCapabilityModule$3.f=newPromiseCapability$1=function(e){return e===PromiseConstructor||e===PromiseWrapper?new OwnPromiseCapability(e):newGenericPromiseCapability(e)},isCallable$1(NativePromiseConstructor$2)&&NativePromisePrototype$1!==Object.prototype)){nativeThen=NativePromisePrototype$1.then,NATIVE_PROMISE_SUBCLASSING||defineBuiltIn$1(NativePromisePrototype$1,"then",function(e,t){var n=this;return new PromiseConstructor(function(e,t){call$6(nativeThen,n,e,t)}).then(e,t)},{unsafe:!0});try{delete NativePromisePrototype$1.constructor}catch(e){}setPrototypeOf&&setPrototypeOf(NativePromisePrototype$1,PromisePrototype)}$$6({global:!0,constructor:!0,wrap:!0,forced:FORCED_PROMISE_CONSTRUCTOR$4},{Promise:PromiseConstructor}),setToStringTag(PromiseConstructor,PROMISE,!1),setSpecies(PROMISE);var wellKnownSymbol$2=wellKnownSymbol$e,Iterators$1=iterators,ITERATOR$2=wellKnownSymbol$e("iterator"),ArrayPrototype=Array.prototype,isArrayIteratorMethod$1=function(e){return void 0!==e&&(Iterators$1.Array===e||ArrayPrototype[ITERATOR$2]===e)},classof=classof$4,getMethod$1=getMethod$3,Iterators=iterators,wellKnownSymbol$1=wellKnownSymbol$e,ITERATOR$1=wellKnownSymbol$e("iterator"),getIteratorMethod$2=function(e){if(null!=e)return getMethod$1(e,ITERATOR$1)||getMethod$1(e,"@@iterator")||Iterators[classof(e)]},call$5=functionCall,aCallable$3=aCallable$9,anObject$3=anObject$c,tryToString$1=tryToString$5,getIteratorMethod$1=getIteratorMethod$2,$TypeError$2=TypeError,getIterator$1=function(e,t){var n=arguments.length<2?getIteratorMethod$1(e):t;if(aCallable$3(n))return anObject$3(call$5(n,e));throw $TypeError$2(tryToString$1(e)+" is not iterable")},call$4=functionCall,anObject$2=anObject$c,getMethod=getMethod$3,iteratorClose$1=function(e,t,n){var r,o;anObject$2(e);try{if(!(r=getMethod(e,"return"))){if("throw"===t)throw n;return n}r=call$4(r,e)}catch(e){o=!0,r=e}if("throw"===t)throw n;if(o)throw r;return anObject$2(r),n},bind=functionBindContext,call$3=functionCall,anObject$1=anObject$c,tryToString=tryToString$5,isArrayIteratorMethod=isArrayIteratorMethod$1,lengthOfArrayLike$1=lengthOfArrayLike$5,isPrototypeOf=objectIsPrototypeOf,getIterator=getIterator$1,getIteratorMethod=getIteratorMethod$2,iteratorClose=iteratorClose$1,$TypeError$1=TypeError,Result=function(e,t){this.stopped=e,this.result=t},ResultPrototype=Result.prototype,iterate$2=function(e,t,n){function r(e){return i&&iteratorClose(i,"normal",e),new Result(!0,e)}function o(e){return d?(anObject$1(e),f?y(e[0],e[1],r):y(e[0],e[1])):f?y(e,r):y(e)}var i,a,s,l,c,p,u=n&&n.that,d=!(!n||!n.AS_ENTRIES),$=!(!n||!n.IS_RECORD),g=!(!n||!n.IS_ITERATOR),f=!(!n||!n.INTERRUPTED),y=bind(t,u);if($)i=e.iterator;else if(g)i=e;else{if(!(n=getIteratorMethod(e)))throw $TypeError$1(tryToString(e)+" is not iterable");if(isArrayIteratorMethod(n)){for(a=0,s=lengthOfArrayLike$1(e);a<s;a++)if((l=o(e[a]))&&isPrototypeOf(ResultPrototype,l))return l;return new Result(!1)}i=getIterator(e,n)}for(c=($?e:i).next;!(p=call$3(c,i)).done;){try{l=o(p.value)}catch(e){iteratorClose(i,"throw",e)}if("object"==typeof l&&l&&isPrototypeOf(ResultPrototype,l))return l}return new Result(!1)},wellKnownSymbol=wellKnownSymbol$e,ITERATOR=wellKnownSymbol$e("iterator"),SAFE_CLOSING=!1;try{var called=0,iteratorWithReturn={next:function(){return{done:!!called++}},return:function(){SAFE_CLOSING=!0}};iteratorWithReturn[ITERATOR]=function(){return this},Array.from(iteratorWithReturn,function(){throw 2})}catch(e){}var method,checkCorrectnessOfIteration$1=function(e,t){if(!t&&!SAFE_CLOSING)return!1;var n=!1;try{var r={};r[ITERATOR]=function(){return{next:function(){return{done:n=!0}}}},e(r)}catch(e){}return n},NativePromiseConstructor$1=promiseNativeConstructor,checkCorrectnessOfIteration=checkCorrectnessOfIteration$1,FORCED_PROMISE_CONSTRUCTOR$3=promiseConstructorDetection.CONSTRUCTOR,promiseStaticsIncorrectIteration=FORCED_PROMISE_CONSTRUCTOR$3||!checkCorrectnessOfIteration(function(e){NativePromiseConstructor$1.all(e).then(void 0,function(){})}),$$5=_export,call$2=functionCall,aCallable$2=aCallable$9,newPromiseCapabilityModule$2=newPromiseCapability$2,perform$1=perform$3,iterate$1=iterate$2,PROMISE_STATICS_INCORRECT_ITERATION$1=promiseStaticsIncorrectIteration,$$4=(_export({target:"Promise",stat:!0,forced:promiseStaticsIncorrectIteration},{all:function(e){var s=this,t=newPromiseCapabilityModule$2.f(s),l=t.resolve,c=t.reject,n=perform$1(function(){var r=aCallable$2(s.resolve),o=[],i=0,a=1;iterate$1(e,function(e){var t=i++,n=!1;a++,call$2(r,s,e).then(function(e){n||(n=!0,o[t]=e,--a||l(o))},c)}),--a||l(o)});return n.error&&c(n.value),t.promise}}),_export),FORCED_PROMISE_CONSTRUCTOR$2=promiseConstructorDetection.CONSTRUCTOR,NativePromiseConstructor=promiseNativeConstructor,getBuiltIn$1=getBuiltIn$8,isCallable=isCallable$l,defineBuiltIn=defineBuiltIn$6,NativePromisePrototype=NativePromiseConstructor&&NativePromiseConstructor.prototype,$$3=($$4({target:"Promise",proto:!0,forced:FORCED_PROMISE_CONSTRUCTOR$2,real:!0},{catch:function(e){return this.then(void 0,e)}}),isCallable(NativePromiseConstructor)&&(method=getBuiltIn$1("Promise").prototype.catch,NativePromisePrototype.catch!==method&&defineBuiltIn(NativePromisePrototype,"catch",method,{unsafe:!0})),_export),call$1=functionCall,aCallable$1=aCallable$9,newPromiseCapabilityModule$1=newPromiseCapability$2,perform=perform$3,iterate=iterate$2,PROMISE_STATICS_INCORRECT_ITERATION=promiseStaticsIncorrectIteration,$$2=(_export({target:"Promise",stat:!0,forced:promiseStaticsIncorrectIteration},{race:function(e){var n=this,r=newPromiseCapabilityModule$1.f(n),o=r.reject,t=perform(function(){var t=aCallable$1(n.resolve);iterate(e,function(e){call$1(t,n,e).then(r.resolve,o)})});return t.error&&o(t.value),r.promise}}),_export),call=functionCall,newPromiseCapabilityModule=newPromiseCapability$2,FORCED_PROMISE_CONSTRUCTOR$1=promiseConstructorDetection.CONSTRUCTOR,anObject=($$2({target:"Promise",stat:!0,forced:FORCED_PROMISE_CONSTRUCTOR$1},{reject:function(e){var t=newPromiseCapabilityModule.f(this);return call(t.reject,void 0,e),t.promise}}),anObject$c),isObject=isObject$7,newPromiseCapability=newPromiseCapability$2,promiseResolve$1=function(e,t){if(anObject(e),isObject(t)&&t.constructor===e)return t;e=newPromiseCapability.f(e);return(0,e.resolve)(t),e.promise},$$1=_export,getBuiltIn=getBuiltIn$8,FORCED_PROMISE_CONSTRUCTOR=promiseConstructorDetection.CONSTRUCTOR,promiseResolve=promiseResolve$1;function fetchOrgsApplications(n,r){return __awaiter(this,void 0,void 0,function*(){var e="fetchOrgsApplications",t="applications";return(yield baseGraphQLApiWithError(Object.assign({query:`
|
|
2
|
+
query ${e} ${`($owned: Boolean $limit: Int${n?" $status: ApplicationStatus":""})`}{
|
|
3
|
+
${t} ${`(owned: $owned limit: $limit${n?" status: $status":""})`} {
|
|
4
|
+
records {
|
|
5
|
+
id
|
|
6
|
+
name
|
|
7
|
+
description
|
|
8
|
+
iconUrl
|
|
9
|
+
isPublic
|
|
10
|
+
ownerOrganizationId
|
|
11
|
+
status
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
`,variables:{owned:!1,limit:100,status:n||void 0},operationName:e},r)))[t]})}getBuiltIn("Promise"),$$1({target:"Promise",stat:!0,forced:FORCED_PROMISE_CONSTRUCTOR},{resolve:function(e){return promiseResolve(this,e)}});const fetchAllApplications=(n,r)=>__awaiter(void 0,void 0,void 0,function*(){try{const e=yield fetch(n+"/v1/admin/applications?allActive=true&limit=99999&offset=0",{method:"GET",headers:Object.assign({"Content-Type":"application/json"},r&&{Authorization:"Bearer "+r}),credentials:"include"}),t=yield e.json();return t.records=t.results.map(e=>Object.assign({name:e.applicationName,iconUrl:e.applicationIconUrl,id:e.applicationId,isPublic:e.public,description:e.applicationDescription},e)),t}catch(e){throw console.error(e),new Error("Something went wrong while loading apps")}});function*fetchInstalledAppsSaga(){try{const e=yield fetchOrgsApplications("active",yield select(selectApiConfigs));e.records=e.records.sort((e,t)=>e.name.localeCompare(t.name)),yield put(actions.adminCenterApplications.fetchInstalledApplicationsSuccess(e.records))}catch(e){yield put(actions.adminCenterApplications.fetchInstalledApplicationsFailure()),console.log(e)}}function*fetchAllAppsSaga(){try{var e=yield select(selectApiConfigs),t=yield fetchAllApplications(e.apiRoot,e.token);yield put(actions.adminCenterApplications.fetchAllApplicationsSuccess(t.records))}catch(e){yield put(actions.adminCenterApplications.fetchAllApplicationsFailure()),console.log(e)}}function*getInstalledAppsWatcher(){yield takeEvery$1(actions.adminCenterApplications.fetchInstalledApplicationsStart.type,fetchInstalledAppsSaga)}function*getAllAppsWatcher(){yield takeEvery$1(actions.adminCenterApplications.fetchAllApplicationsStart.type,fetchAllAppsSaga)}function*rootSaga(){yield all([getInstalledAppsWatcher(),getAllAppsWatcher()])}const appDetailsResponseFields=`records {
|
|
16
|
+
id
|
|
17
|
+
name
|
|
18
|
+
description
|
|
19
|
+
status
|
|
20
|
+
iconUrl
|
|
21
|
+
isPublic
|
|
22
|
+
applicationConfig {
|
|
23
|
+
records {
|
|
24
|
+
configKey
|
|
25
|
+
configType
|
|
26
|
+
description
|
|
27
|
+
value
|
|
28
|
+
valueJSON
|
|
29
|
+
configLevel
|
|
30
|
+
required
|
|
31
|
+
secured
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
entityTags {
|
|
35
|
+
tagKey
|
|
36
|
+
tagValue
|
|
37
|
+
}
|
|
38
|
+
ownerOrganizationId
|
|
39
|
+
}`;function getApplicationById(o,i){return __awaiter(this,void 0,void 0,function*(){var e="getApplicationById",t="applications",n={id:i},r=`
|
|
40
|
+
query ${e} ($id: ID!){
|
|
41
|
+
${t} (owned: false, id: $id) {
|
|
42
|
+
${appDetailsResponseFields}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
`;try{return(yield baseGraphQLApiWithError(Object.assign({query:r,operationName:e,variables:n},o)))[t]}catch(e){throw console.log(e),new Error("Something went wrong while loading app details")}})}function getOrganizationName(n,r){return __awaiter(this,void 0,void 0,function*(){var e="getOrganizationName",t={id:r};try{return yield baseGraphQLApiWithError(Object.assign({query:"\n query getOrganizationName ($id: ID!){\n organization (id: $id) {\n id\n name\n }\n }\n ",operationName:e,variables:t},n))}catch(e){console.log(e)}})}function installApp(n,r){return __awaiter(this,void 0,void 0,function*(){var e="installApp",t=`
|
|
46
|
+
query ${e} ($orgId: ID! $appId: ID! $configs: [ApplicationConfigInput!]) {
|
|
47
|
+
applicationAddToOrg (orgId: $orgId appId: $appId configs: $configs) {
|
|
48
|
+
${appDetailsResponseFields}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
`;try{return yield baseGraphQLApiWithError(Object.assign({query:t,operationName:e,variables:r},n))}catch(e){console.log(e)}})}function*fetchOwnerOrganization(e,t){let n={};try{var r=(yield call$g(getOrganizationName,e,t))["organization"];n=r}catch(e){n={id:t,name:" "},console.log(e)}return n}function*fetchApplicationDetailsSaga(e){try{var t=yield select(selectApiConfigs),[n]=(yield call$g(getApplicationById,t,e.payload.applicationId)).records,r=yield call$g(fetchOwnerOrganization,t,n.ownerOrganizationId);yield put(actions$1.fetchApplicationSuccess({application:n,organization:r}))}catch(e){yield put(actions$1.fetchApplicationError()),console.log(e)}}function*installAppSaga(e){try{var t=yield select(selectApiConfigs),[n]=(yield call$g(installApp,t,e.payload)).records;yield put(actions$1.installAppSuccess(n))}catch(e){yield put(actions$1.installAppFailure()),console.log(e)}}function*getApplicationDetailsWatcher(){yield takeEvery$1(actions$1.fetchApplicationStart.type,fetchApplicationDetailsSaga)}function*installAppWatcher(){yield takeEvery$1(actions$1.installAppStart.type,installAppSaga)}function*applicationDetailsPanelRootSaga(){yield all([getApplicationDetailsWatcher(),installAppWatcher()])}function getAdminCenterApplicationsModule(){return{id:SLICE_NAME$1,reducerMap:{[SLICE_NAME$1]:rootReducer},sagas:[rootSaga],initialActions:[]}}function getApplicationDetailsPanelModule(){return{id:SLICE_NAME,reducerMap:{[SLICE_NAME]:applicationDetailsPanelReducer},sagas:[applicationDetailsPanelRootSaga],initialActions:[]}}const tabsList$1=[{label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.lpZXMd",defaultMessage:"All Applications",description:"Admin center all applications label"}),disabled:!1,id:"All Applications"},{label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.lpZXMy",defaultMessage:"Installed Applications",description:"Admin center installed applications label"}),disabled:!1,id:"Installed Applications"}],ApplicationsTable=()=>{const[e,t]=react.exports.useState(0),n=useSelector(selectIsUserAdmin),r=useSelector(selectInstalledApps);var o=useSelector(selectAllApps),i=useSelector(selectInstalledAppsUiStatus),a=useSelector(selectAllAppsUiStatus);const s=useDispatch();react.exports.useEffect(()=>{s(actions.adminCenterApplications.fetchInstalledApplicationsStart()),n&&s(actions.adminCenterApplications.fetchAllApplicationsStart())},[s]);return jsxRuntime.exports.jsxs(React.Fragment,{children:[jsxRuntime.exports.jsx(Box,Object.assign({sx:{borderBottom:"1px solid #e8e8e8"}},{children:jsxRuntime.exports.jsx(Box,Object.assign({sx:{"& .Sdk-MuiTab-root.Mui-selected":{color:"text.primary",fontWeight:600},width:n?"350px":"170px"}},{children:jsxRuntime.exports.jsx(CustomTabs,{selectedId:e,onChangeTab:e=>{t(e)},tabsList:n?tabsList$1:[tabsList$1[1]]})}))})),jsxRuntime.exports.jsx(TabPanel,Object.assign({value:e,index:0},{children:n?jsxRuntime.exports.jsx(ApplicationList,{apps:o,uiStatus:a,onRetry:()=>s(actions.adminCenterApplications.fetchAllApplicationsStart()),showInstalledChip:!0,isAppInstalled:t=>-1!==r.findIndex(e=>e.id===t)}):jsxRuntime.exports.jsx(ApplicationList,{apps:r,uiStatus:i,onRetry:()=>s(actions.adminCenterApplications.fetchInstalledApplicationsStart())})})),jsxRuntime.exports.jsx(TabPanel,Object.assign({value:e,index:1},{children:jsxRuntime.exports.jsx(ApplicationList,{apps:r,uiStatus:i,onRetry:()=>s(actions.adminCenterApplications.fetchInstalledApplicationsStart())})}))]})},useStyles$2=makeStyles()(e=>({root:{display:"flex",flexDirection:"column",height:"100%"},header:{display:"flex",justifyContent:"space-between",padding:e.spacing(4),borderBottom:"0.5px solid "+e.palette.divider},tableWrapper:{overflow:"hidden"},toolbar:{alignItems:"baseline","& button svg":{marginRight:"5px"},display:"flex",justifyContent:"center"}}));function ApplicationsTab({}){var e=useStyles$2()["classes"];return jsxRuntime.exports.jsxs("section",Object.assign({className:e.root},{children:[jsxRuntime.exports.jsx("header",Object.assign({className:e.header},{children:jsxRuntime.exports.jsxs(Box,Object.assign({sx:{mr:15}},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h5","data-testid":"org-applications.header"},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-panel.applications.table.header",defaultMessage:"Applications",description:"Application Header"})})),jsxRuntime.exports.jsx(Typography$1,Object.assign({sx:{mt:1},variant:"subtitle1","data-testid":"org-applications.description"},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-panel.applications.table.description",defaultMessage:"Browse and manage the applications that are enabled for this Organization and its users.",description:"Applications Tab Description"})}))]}))})),jsxRuntime.exports.jsx("div",Object.assign({className:e.tableWrapper},{children:jsxRuntime.exports.jsx(ApplicationsTable,{})}))]}))}var aCallable=aCallable$9,toObject=toObject$5,IndexedObject=indexedObject,lengthOfArrayLike=lengthOfArrayLike$5,$TypeError=TypeError,createMethod=function(c){return function(e,t,n,r){aCallable(t);var o=toObject(e),i=IndexedObject(o),a=lengthOfArrayLike(o),s=c?a-1:0,l=c?-1:1;if(n<2)for(;;){if(s in i){r=i[s],s+=l;break}if(s+=l,c?s<0:a<=s)throw $TypeError("Reduce of empty array with no initial value")}for(;c?0<=s:s<a;s+=l)s in i&&(r=t(r,i[s],s,o));return r}},arrayReduce={left:createMethod(!1),right:createMethod(!0)},$=_export,$reduce=arrayReduce.left,arrayMethodIsStrict=arrayMethodIsStrict$2,CHROME_VERSION=engineV8Version,IS_NODE=engineIsNode,STRICT_METHOD=arrayMethodIsStrict$2("reduce"),CHROME_BUG=!IS_NODE&&79<CHROME_VERSION&&CHROME_VERSION<83;$({target:"Array",proto:!0,forced:!STRICT_METHOD||CHROME_BUG},{reduce:function(e){var t=arguments.length;return $reduce(this,e,t,1<t?arguments[1]:void 0)}});const useStyles$1=makeStyles()((e,{isEmpty:t})=>({panelRoot:{width:"100%"},panelLoading:{height:300},panelContainer:{display:"flex",flexDirection:"column",width:"100%",padding:e.spacing(2)},panelHeader:{display:"flex",justifyContent:"space-between",alignItems:"center",paddingLeft:e.spacing(1),marginBottom:e.spacing(1),"&.with-secondary-title":{alignItems:"flex-start"}},panelHeaderLine:{minHeight:"16px"},panelContent:{width:"100%"},panelBody:{display:"flex",flexGrow:1},divider:{marginBottom:e.spacing(2)},engineHeader:{minHeight:"120px"},headerInfo:{paddingLeft:e.spacing(4),flexGrow:1},headerOwner:{color:"#0c53b0",minHeight:"16px"},detailInfo:{paddingTop:e.spacing(3)},detailInfoBody:{paddingLeft:e.spacing(4),paddingTop:e.spacing(3)},detailOverview:{paddingTop:e.spacing(6),paddingBottom:e.spacing(6),minHeight:"120px"},sectionTitle:{paddingBottom:e.spacing(3)},textContent:{fontStyle:"normal",fontWeight:400,fontSize:14,lineHeight:20},titleInline:{fontWeight:600,marginRight:e.spacing(1)},contentRow:{paddingBottom:e.spacing(3)},engineDescription:{paddingTop:e.spacing(2),paddingBottom:e.spacing(2)},engineVersion:{paddingLeft:e.spacing(3)},mainLayout:{paddingTop:e.spacing(2)},tabPanels:{width:"100%"},detailHeaderContainer:{paddingLeft:e.spacing(3),paddingTop:e.spacing(2),alignItems:"center"},taskTabPanels:{marginTop:e.spacing(2),paddingLeft:e.spacing(2),paddingRight:e.spacing(2),width:"100%",maxHeight:"160px",maxWidth:"660px",overflow:"auto",background:"#F4F4F4",border:"1px solid #D5DFE9","box-sizing":"border-box","border-radius":"4px"},metricsList:{paddingTop:e.spacing(6)},taskFitlerContainer:{marginTop:e.spacing(4),marginBottom:e.spacing(2),height:"40px",lineHeight:"40px",display:"flex","flex-wrap":"wrap","flex-direction":"row","justify-content":"flex-end"},taskFitlerItem:{marginRight:e.spacing(2)},tabsContainer:{"& .Sdk-Mui-selected":{color:"black"},"& .Sdk-MuiTabs-indicator":{backgroundColor:"#000"}},tabsParent:{padding:e.spacing(0,3,0,3),"& div":{borderBottom:"none"},"& div button":{fontFamily:"Nunito",fontWeight:400,flex:"0 1 auto !important",minWidth:"unset"}},configName:{marginBottom:"4px"},configDescription:{marginBottom:"9px"},configContainer:{paddingLeft:"21px",marginBottom:"21px"},configDivider:{marginTop:"21px"},configInput:{"& input":{borderColor:"#E1E6ED",paddingTop:"18px",paddingBottom:"18px",minWidth:"320px"}},requiredLabel:{color:"#9CA8B4",marginLeft:"6px"},helperText:{paddingLeft:"15px",fontSize:"12px",fontWeight:"bold"},noConfigs:{textAlign:"center",marginTop:"30px","& svg":{width:"160px",height:"160px",marginBottom:"20px"}},uninstallBtn:{marginTop:t?"40px":"0",padding:"8px 15px"},actionButtons:{"& button":{padding:"8px 15px",lineHeight:"20px"},display:"flex",justifyContent:"right"},appSettingsContainer:{display:"flex",justifyContent:"space-between",flexDirection:"column",height:"calc(100vh - 55px - 250px)"}})),selectStatus=e=>{return null==(e=null==e?void 0:e[SLICE_NAME])?void 0:e.status},selectApplication=e=>{return null==(e=null==e?void 0:e[SLICE_NAME])?void 0:e.application},selectOwnerOrganization=e=>{return null==(e=null==e?void 0:e[SLICE_NAME])?void 0:e.ownerOrganization},useStyles=makeStyles()(e=>({root:{borderRadius:"50%",border:"2px solid #D5DFE9",display:"flex",justifyContent:"center",alignItems:"center",overflow:"hidden"},small:{width:e.spacing(6),height:e.spacing(6)},medium:{width:e.spacing(9),height:e.spacing(9)},large:{width:e.spacing(12),height:e.spacing(12)},xlarge:{width:e.spacing(16),height:e.spacing(16)},logo:{maxWidth:"100%",maxHeight:"100%"},veritoneLogo:{maxWidth:"75%",maxHeight:"75%"}})),Logo=({size:e="xlarge",path:t="",altText:n})=>{var r=useStyles()["classes"],[t,o]=useBackupImg(t,img$1u);return jsxRuntime.exports.jsx("div",Object.assign({className:r.root+" "+r[e]},{children:jsxRuntime.exports.jsx("img",{className:r.logo+" "+(t===img$1u&&r.veritoneLogo),src:t,alt:n,onError:o})}))},getSignedUriPath=n=>{const e=["iconUrl"].map(e=>e);return e.reduce((e,t)=>n[t]||e,void 0)},DetailHeader=({installationConfig:t})=>{const n=useSelector(selectApplication);var e=useSelector(selectOwnerOrganization);const r=(useSelector(userSelector)||{})["organization"];var o=useStyles$1({})["classes"],i=null==(i=n.entityTags)?void 0:i.map(e=>e.tagKey).join(", "),a=getSignedUriPath(n);const s=useDispatch();return jsxRuntime.exports.jsxs(Box,Object.assign({display:"flex",flexDirection:"row",className:o.detailHeaderContainer,"data-testid":"application-details-header"},{children:[jsxRuntime.exports.jsx("div",{children:jsxRuntime.exports.jsx(Logo,{path:a,altText:n.name+" Logo"})}),jsxRuntime.exports.jsxs("div",Object.assign({className:o.headerInfo},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h1","data-testid":"application-details-header-name"},{children:n.name})),jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"caption",className:o.headerOwner,"data-testid":"application-details-header-owner"},{children:null==e?void 0:e.name})),jsxRuntime.exports.jsx(Box,Object.assign({display:"flex",flexDirection:"row",className:o.panelHeaderLine},{children:jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"caption"},{children:i}))}))]})),jsxRuntime.exports.jsx("div",{children:n.status!==EApplicationStatus.active&&jsxRuntime.exports.jsx(Button,Object.assign({color:"primary",variant:"contained",onClick:()=>{var e;s(actions$1.installAppStart({appId:n.id,orgId:(null==(e=null===r||void 0===r?void 0:r.organizationId)?void 0:e.toString())||"",configs:t||[]}))}},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center.applications.install-btn",defaultMessage:"Install App",description:"Install App button label"})}))})]}))},InfoItem=({dataTest:e,title:t,value:n})=>jsxRuntime.exports.jsxs(Grid$1,Object.assign({item:!0,xs:6},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"caption","data-test":`application-details-panel-detail-info-${e}-caption`},{children:t})),jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h5","data-test":"application-details-panel-detail-info-"+e},{children:n}))]})),BasicInfo=()=>{var e=useSelector(selectApplication),t=useStyles$1({})["classes"];return jsxRuntime.exports.jsxs(Box,Object.assign({"data-test":"application-details-panel-basic-info-content"},{children:[jsxRuntime.exports.jsxs(Box,Object.assign({className:t.detailOverview,"data-test":"application-details-panel-overview"},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h3",className:t.sectionTitle},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-overview-title",defaultMessage:"Overview",description:"title of the Overview section on the application details panel"})})),jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h5"},{children:e.description}))]})),jsxRuntime.exports.jsx(Divider,{}),jsxRuntime.exports.jsxs(Box,Object.assign({className:t.detailInfo,"data-test":"application-details-panel-basic-info-details"},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h3",className:t.sectionTitle},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-basic-info-details-title",defaultMessage:"Information",description:"The title of the Information section in the application details panel basic info"})})),jsxRuntime.exports.jsxs(Grid$1,Object.assign({container:!0,spacing:4,className:t.detailInfoBody},{children:[jsxRuntime.exports.jsx(InfoItem,{dataTest:"name",title:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-info-name-title",defaultMessage:"Name",description:"The title of the name field in the application details panel basic info"}),value:e.name}),jsxRuntime.exports.jsx(InfoItem,{dataTest:"app-id",title:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-info-app-id-title",defaultMessage:"App ID",description:"The title of the app id field in the application details panel basic info"}),value:e.id}),jsxRuntime.exports.jsx(InfoItem,{dataTest:"tags",title:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-info-tags-title",defaultMessage:"Tags",description:"The title of the tags field in the application details panel basic info"}),value:null==(t=e.entityTags)?void 0:t.map(e=>e.tagKey).join(", ")})]}))]}))]}))},formattedMessages=e=>({fieldIsRequired:e.formatMessage({id:"admin-center-applcations.application-details-panel.settings-tab.required-field-error",defaultMessage:[{type:0,value:"This field is required"}]})}),SettingsTab=({intl:e,setInstallationConfig:t})=>{const n=formattedMessages(e)["fieldIsRequired"],r=useSelector(selectApplication),[o,i]=react.exports.useState([]),[a,s]=react.exports.useState([]),[l,c]=react.exports.useState(!1),p=useStyles$1({isEmpty:0===o.length})["classes"],u=(react.exports.useEffect(()=>{var e;r&&null!=(e=null===r||void 0===r?void 0:r.applicationConfig)&&e.records&&(i(null==(e=null===r||void 0===r?void 0:r.applicationConfig)?void 0:e.records),l||(c(!0),s(null==(e=null===r||void 0===r?void 0:r.applicationConfig)?void 0:e.records)))},[r]),t=>{var e;return null==(e=o.find(e=>e.configKey===t))?void 0:e.value}),d=(n,t)=>{const r=o.findIndex(e=>e.configKey===t);-1!==r&&i(e=>{const t=[...e];e=Object.assign(Object.assign({},t[r]),{value:n});return t[r]=e,t})};const $=e=>e.required&&!u(e.configKey);return jsxRuntime.exports.jsxs(Box,Object.assign({"data-testid":"application-details-panel.app-settings.container",className:p.appSettingsContainer},{children:[jsxRuntime.exports.jsxs("div",{children:[jsxRuntime.exports.jsxs(Box,Object.assign({className:p.detailOverview,"data-test":"application-details-panel-overview"},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h3",className:p.sectionTitle},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-app-settings-title",defaultMessage:"App Settings",description:"title of the App Settings section on the application details panel"})})),jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h5"},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-basic-info-details-title",defaultMessage:"Set your Organization settings that will be applied to all users of this application.",description:"App settings description text"})}))]})),jsxRuntime.exports.jsxs(Box,Object.assign({"data-test":"application-details-panel-app-settings-details"},{children:[o.length?o.map(e=>jsxRuntime.exports.jsxs("div",Object.assign({className:p.configContainer,"data-testid":"application-config-container"},{children:[jsxRuntime.exports.jsxs(Grid$1,Object.assign({container:!0},{children:[jsxRuntime.exports.jsx(Grid$1,Object.assign({item:!0},{children:jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h3",className:p.configName},{children:e.configKey}))})),jsxRuntime.exports.jsx(Grid$1,Object.assign({item:!0},{children:jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"h3",className:p.requiredLabel},{children:e.required?jsxRuntime.exports.jsxs(jsxRuntime.exports.Fragment,{children:["(",jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-panel-app-settings.required-label",defaultMessage:"Required",description:"Required label for the app config"}),")"]}):null}))}))]})),jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"body2",className:p.configDescription},{children:e.description})),(t=>{switch(t.configType){case EConfigTypes.string:return jsxRuntime.exports.jsx(TextField,{value:u(t.configKey),onChange:e=>d(e.target.value,t.configKey),disabled:t.secured,className:p.configInput,error:$(t),label:$(t)?n:void 0});case EConfigTypes.json:return;case EConfigTypes.boolean:return jsxRuntime.exports.jsx(Switch,{checked:u(t.configKey),disabled:t.secured,onChange:e=>d(e.target.checked,t.configKey)});default:return null}})(e),jsxRuntime.exports.jsx(Divider,{className:p.configDivider})]}),e.configKey)):jsxRuntime.exports.jsxs("div",Object.assign({className:p.noConfigs},{children:[jsxRuntime.exports.jsx(NoApps,{fontSize:"large"}),jsxRuntime.exports.jsx(Typography$1,Object.assign({variant:"body2",className:p.helperText},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center-applications.application-details.no-configs",defaultMessage:"This app does not have any configs.",description:"No Applciation configs"})}))]})),jsxRuntime.exports.jsx("div",{children:jsxRuntime.exports.jsx(Button,Object.assign({variant:"outlined",className:p.uninstallBtn},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center-applications.application-details.uninstall-btn",defaultMessage:"Uninstall Application",description:"Uninstall Application button label"})}))})]}))]}),jsxRuntime.exports.jsxs("div",Object.assign({className:p.actionButtons},{children:[jsxRuntime.exports.jsx(Button,Object.assign({variant:"text",sx:{color:"black",marginRight:"15px",fontWeight:400},onClick:()=>i(a)},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center-applications.application-details.cancel-btn",defaultMessage:"Cancel",description:"Cancel button label"})})),jsxRuntime.exports.jsx(Button,Object.assign({variant:"contained",disabled:lodash.exports.isEqual(a,o)||!!o.find(e=>e.required&&!e.value&&"boolean"!=typeof e.value),onClick:()=>{t(o),s(o)}},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"admin-center-applications.application-details.save-btn",defaultMessage:"Save",description:"Save button label"})}))]}))]}))};var AppSettings=injectIntl(SettingsTab);const tabsList=[{label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail-basic-info",defaultMessage:"Basic Info",description:"the title of the Basic Info tab on the application details panel"}),disabled:!1,id:"application-details-tab-label-basic-info"}],settingsTab={label:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-detail.app-settings",defaultMessage:"App Settings",description:"the title of the App Settings tab on the application details panel"}),disabled:!1,id:"application-details-tab-label-app-settings"},MainLayout=({setInstallationConfig:e})=>{const t=useSelector(selectApplication),[n,r]=react.exports.useState(0);var o=useStyles$1({})["classes"];const[i,a]=react.exports.useState(tabsList),[s,l]=react.exports.useState(!1);const c=()=>(null===t||void 0===t?void 0:t.status)!==EApplicationStatus.active;return react.exports.useEffect(()=>{c()||s||(l(!0),a([...i,settingsTab]))},[t]),jsxRuntime.exports.jsxs(Box,Object.assign({className:o.mainLayout},{children:[jsxRuntime.exports.jsx("div",Object.assign({className:o.tabsContainer,"data-testid":"application-details-panel-tabs-list"},{children:jsxRuntime.exports.jsx("div",Object.assign({className:o.tabsParent},{children:jsxRuntime.exports.jsx(CustomTabs,{selectedId:n,onChangeTab:e=>{r(e)},tabsList:i})}))})),jsxRuntime.exports.jsx(Divider,{className:o.divider}),jsxRuntime.exports.jsxs(Box,Object.assign({className:o.tabPanels},{children:[jsxRuntime.exports.jsx(TabPanel,Object.assign({value:n,index:0},{children:jsxRuntime.exports.jsx(BasicInfo,{})})),!c()&&jsxRuntime.exports.jsx(TabPanel,Object.assign({value:n,index:1},{children:jsxRuntime.exports.jsx(AppSettings,{setInstallationConfig:e})}))]}))]}))},Content=({applicationId:e,initValue:t})=>{var n=useSelector(selectStatus);const r=useDispatch();var o=useStyles$1({})["classes"],[i,a]=(react.exports.useEffect(()=>{e?r(actions$1.fetchApplicationStart({applicationId:e,initValue:t})):t&&r(actions$1.setInitialApplicationValue(t))},[r,e,t]),react.exports.useState([]));return n===Status.loading&&jsxRuntime.exports.jsxs(Container,Object.assign({className:o.panelLoading},{children:[jsxRuntime.exports.jsx(Skeleton$1,{variant:"rectangular",animation:"wave",width:400,height:200}),jsxRuntime.exports.jsx(Divider,{sx:{my:2}}),jsxRuntime.exports.jsx(Skeleton$1,{variant:"rectangular",animation:"wave",width:960,height:300})]}))||n===Status.success&&jsxRuntime.exports.jsxs(Container,Object.assign({className:o.panelContent},{children:[jsxRuntime.exports.jsx(DetailHeader,{installationConfig:i}),jsxRuntime.exports.jsx(MainLayout,{setInstallationConfig:a})]}))||n===Status.failure&&jsxRuntime.exports.jsx(Container,{children:jsxRuntime.exports.jsx(ErrorState,{onRetry:()=>{r(actions$1.fetchApplicationStart({applicationId:e,initValue:t}))},errorMessage:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.application-details-panel-error-message",defaultMessage:"Something went wrong while loading your application details.",description:"error message shown when the application details panel encounters a load error"})})})||jsxRuntime.exports.jsx(Container,{children:"Please wait..."})},PanelContainer=({children:e})=>{const t=useDispatch();var n=useStyles$1({})["classes"];return jsxRuntime.exports.jsx("div",Object.assign({className:n.panelRoot,"data-testid":"application-details-panel"},{children:jsxRuntime.exports.jsxs("div",Object.assign({className:n.panelContainer},{children:[jsxRuntime.exports.jsxs("div",Object.assign({className:n.panelHeader},{children:[jsxRuntime.exports.jsx(Typography$1,Object.assign({"data-testid":"application-details-panel-title",variant:"h1"},{children:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.detail-panel-title",defaultMessage:"Application Details",description:"The title of the Application Details panel"})})),jsxRuntime.exports.jsx(Tooltip,Object.assign({title:jsxRuntime.exports.jsx(FormattedMessage,{id:"os-admin-center-applications.detail-panel-close",defaultMessage:"Close Panel",description:"The title of the Application Details panel close button"})},{children:jsxRuntime.exports.jsx(IconButton,Object.assign({onClick:()=>{t(hidePanel("APPLICATION_DETAILS_PANEL"))},"aria-labelledby":"group-details-close-panel","data-testid":"group-details-close-panel",size:"large"},{children:jsxRuntime.exports.jsx(Hide,{})}))}))]})),jsxRuntime.exports.jsx("div",Object.assign({className:n.panelBody},{children:e}))]}))}))},ApplicationDetailsPanel=({applicationId:e,initValue:t})=>jsxRuntime.exports.jsx(AIWareThemeProvider,{children:jsxRuntime.exports.jsx(lib.DynamicModuleLoader,Object.assign({modules:[getApplicationDetailsPanelModule()]},{children:jsxRuntime.exports.jsx(AIWareIntlProvider,{children:jsxRuntime.exports.jsx(CacheProvider,Object.assign({value:muiCache},{children:jsxRuntime.exports.jsx(PanelContainer,{children:jsxRuntime.exports.jsx(Content,{applicationId:e,initValue:t})})}))})}))});export{ApplicationDetailsPanel,ApplicationsTab,Content,PanelContainer,actions,getAdminCenterApplicationsModule,getApplicationDetailsPanelModule,initialState,namespace,rootReducer};
|