@techdocs/cli 1.8.11-next.1 → 1.8.11

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.
Files changed (68) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/dist/embedded-app/.config-schema.json +46 -49
  3. package/dist/embedded-app/index.html +1 -1
  4. package/dist/embedded-app/static/124.2fe45728.chunk.js +5 -0
  5. package/dist/embedded-app/static/124.2fe45728.chunk.js.map +1 -0
  6. package/dist/embedded-app/static/2401.b9ecb259.chunk.js +5 -0
  7. package/dist/embedded-app/static/2401.b9ecb259.chunk.js.map +1 -0
  8. package/dist/embedded-app/static/2420.8b65f057.chunk.js +5 -0
  9. package/dist/embedded-app/static/2420.8b65f057.chunk.js.map +1 -0
  10. package/dist/embedded-app/static/287.e4ea033a.chunk.js +5 -0
  11. package/dist/embedded-app/static/287.e4ea033a.chunk.js.map +1 -0
  12. package/dist/embedded-app/static/3182.09c2f360.chunk.js +6 -0
  13. package/dist/embedded-app/static/3182.09c2f360.chunk.js.map +1 -0
  14. package/dist/embedded-app/static/3632.12b6d8dd.chunk.js +5 -0
  15. package/dist/embedded-app/static/3632.12b6d8dd.chunk.js.map +1 -0
  16. package/dist/embedded-app/static/4919.94eee8c0.chunk.js +3 -0
  17. package/dist/embedded-app/static/4919.94eee8c0.chunk.js.map +1 -0
  18. package/dist/embedded-app/static/5974.9d006f0f.chunk.js +3 -0
  19. package/dist/embedded-app/static/5974.9d006f0f.chunk.js.map +1 -0
  20. package/dist/embedded-app/static/6271.e14894fd.chunk.js +5 -0
  21. package/dist/embedded-app/static/6271.e14894fd.chunk.js.map +1 -0
  22. package/dist/embedded-app/static/73.c7f521ae.chunk.js +3 -0
  23. package/dist/embedded-app/static/{73.cc8a3548.chunk.js.map → 73.c7f521ae.chunk.js.map} +1 -1
  24. package/dist/embedded-app/static/8307.3553740d.chunk.js +8 -0
  25. package/dist/embedded-app/static/8307.3553740d.chunk.js.map +1 -0
  26. package/dist/embedded-app/static/8384.f9a38a1a.chunk.js +5 -0
  27. package/dist/embedded-app/static/8384.f9a38a1a.chunk.js.map +1 -0
  28. package/dist/embedded-app/static/9652.e5ad523b.chunk.js +5 -0
  29. package/dist/embedded-app/static/9652.e5ad523b.chunk.js.map +1 -0
  30. package/dist/embedded-app/static/main.e5571a2f.js +497 -0
  31. package/dist/embedded-app/static/main.e5571a2f.js.map +1 -0
  32. package/dist/embedded-app/static/module-zod.52dba18e.js +3 -0
  33. package/dist/embedded-app/static/module-zod.52dba18e.js.map +1 -0
  34. package/dist/embedded-app/static/{runtime.a5f4ad6c.js → runtime.e5571a2f.js} +2 -2
  35. package/dist/embedded-app/static/{runtime.a5f4ad6c.js.map → runtime.e5571a2f.js.map} +1 -1
  36. package/dist/embedded-app/static/{vendor.a5f4ad6c.js → vendor.e5571a2f.js} +1 -1
  37. package/dist/embedded-app/static/{vendor.a5f4ad6c.js.map → vendor.e5571a2f.js.map} +1 -1
  38. package/dist/index.cjs.js +1 -1
  39. package/package.json +5 -5
  40. package/dist/embedded-app/static/115.dcb79bb0.chunk.js +0 -3
  41. package/dist/embedded-app/static/115.dcb79bb0.chunk.js.map +0 -1
  42. package/dist/embedded-app/static/124.843ab31e.chunk.js +0 -5
  43. package/dist/embedded-app/static/124.843ab31e.chunk.js.map +0 -1
  44. package/dist/embedded-app/static/2401.4df01527.chunk.js +0 -5
  45. package/dist/embedded-app/static/2401.4df01527.chunk.js.map +0 -1
  46. package/dist/embedded-app/static/2420.18b68427.chunk.js +0 -5
  47. package/dist/embedded-app/static/2420.18b68427.chunk.js.map +0 -1
  48. package/dist/embedded-app/static/287.ee4ee196.chunk.js +0 -5
  49. package/dist/embedded-app/static/287.ee4ee196.chunk.js.map +0 -1
  50. package/dist/embedded-app/static/3182.232eb781.chunk.js +0 -6
  51. package/dist/embedded-app/static/3182.232eb781.chunk.js.map +0 -1
  52. package/dist/embedded-app/static/3632.95b279c9.chunk.js +0 -5
  53. package/dist/embedded-app/static/3632.95b279c9.chunk.js.map +0 -1
  54. package/dist/embedded-app/static/5974.633b23c0.chunk.js +0 -3
  55. package/dist/embedded-app/static/5974.633b23c0.chunk.js.map +0 -1
  56. package/dist/embedded-app/static/6271.25803276.chunk.js +0 -5
  57. package/dist/embedded-app/static/6271.25803276.chunk.js.map +0 -1
  58. package/dist/embedded-app/static/73.cc8a3548.chunk.js +0 -3
  59. package/dist/embedded-app/static/8307.42c405fe.chunk.js +0 -8
  60. package/dist/embedded-app/static/8307.42c405fe.chunk.js.map +0 -1
  61. package/dist/embedded-app/static/8384.a139d26a.chunk.js +0 -5
  62. package/dist/embedded-app/static/8384.a139d26a.chunk.js.map +0 -1
  63. package/dist/embedded-app/static/9652.9a93372c.chunk.js +0 -5
  64. package/dist/embedded-app/static/9652.9a93372c.chunk.js.map +0 -1
  65. package/dist/embedded-app/static/main.a5f4ad6c.js +0 -497
  66. package/dist/embedded-app/static/main.a5f4ad6c.js.map +0 -1
  67. package/dist/embedded-app/static/module-zod.955be94f.js +0 -3
  68. package/dist/embedded-app/static/module-zod.955be94f.js.map +0 -1
@@ -0,0 +1,497 @@
1
+ (()=>{(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([[8792],{86519:function(Y,T,t){"use strict";t.d(T,{c:function(){return o}});const o=Symbol.for("CATALOG_FILTER_EXISTS_0e15b590c0b343a2bae3e787e84c2111")},72348:function(Y,T,t){"use strict";t.d(T,{P:function(){return d},_P:function(){return i},oQ:function(){return o}});const o="default",i="backstage.io/view-url",d="backstage.io/edit-url",O="kubernetes.io/api-server",m="kubernetes.io/api-server-certificate-authority",v="kubernetes.io/auth-provider"},6820:function(Y,T,t){"use strict";t.d(T,{KU:function(){return O},U2:function(){return m},sM:function(){return d}});var o=t(72348);function i(v){let f=v.indexOf(":");const c=v.indexOf("/");c!==-1&&c<f&&(f=-1);const C=f===-1?void 0:v.slice(0,f),A=c===-1?void 0:v.slice(f+1,c),w=v.slice(Math.max(f+1,c+1));if(C===""||A===""||w==="")throw new TypeError(`Entity reference "${v}" was not on the form [<kind>:][<namespace>/]<name>`);return{kind:C,namespace:A,name:w}}function d(v){return{kind:v.kind,namespace:v.metadata.namespace||o.oQ,name:v.metadata.name}}function O(v,f){if(!v)throw new Error("Entity reference must not be empty");const c=f==null?void 0:f.defaultKind,C=(f==null?void 0:f.defaultNamespace)||o.oQ;let A,w,h;if(typeof v=="string"){const y=i(v);var S;A=(S=y.kind)!==null&&S!==void 0?S:c;var g;w=(g=y.namespace)!==null&&g!==void 0?g:C,h=y.name}else{var D;A=(D=v.kind)!==null&&D!==void 0?D:c;var P;w=(P=v.namespace)!==null&&P!==void 0?P:C,h=v.name}if(A)if(w){if(!h){const y=JSON.stringify(v);throw new Error(`Entity reference ${y} had missing or empty name`)}}else{const y=JSON.stringify(v);throw new Error(`Entity reference ${y} had missing or empty namespace`)}else{const y=JSON.stringify(v);throw new Error(`Entity reference ${y} had missing or empty kind (e.g. did not start with "component:" or similar)`)}return{kind:A,namespace:w,name:h}}function m(v){let f,c,C;if("metadata"in v){f=v.kind;var A;c=(A=v.metadata.namespace)!==null&&A!==void 0?A:o.oQ,C=v.metadata.name}else{f=v.kind;var w;c=(w=v.namespace)!==null&&w!==void 0?w:o.oQ,C=v.name}return`${f.toLocaleLowerCase("en-US")}:${c.toLocaleLowerCase("en-US")}/${C.toLocaleLowerCase("en-US")}`}},51372:function(Y,T,t){"use strict";t.d(T,{fT:function(){return c},jn:function(){return S},nC:function(){return f},sA:function(){return g},vv:function(){return o}});const o="ownedBy",i="ownerOf",d="consumesApi",O="apiConsumedBy",m="providesApi",v="apiProvidedBy",f="dependsOn",c="dependencyOf",C="parentOf",A="childOf",w="memberOf",h="hasMember",S="partOf",g="hasPart"},17736:function(Y,T,t){"use strict";t.d(T,{Eo:function(){return o},I4:function(){return d}});const o="backstage.io/managed-by-location",i="backstage.io/managed-by-origin-location",d="backstage.io/source-location"},78692:function(Y,T,t){"use strict";t.d(T,{Cr:function(){return v},KL:function(){return m},aY:function(){return O}});var o=t(6820),i=t(17736);const d=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*\:/i;function O(f){if(typeof f!="string")throw new TypeError(`Unable to parse location ref '${f}', unexpected argument ${typeof f}`);const c=f.indexOf(":");if(c<0)throw new TypeError(`Unable to parse location ref '${f}', expected '<type>:<target>', e.g. 'url:https://host/path'`);const C=f.substring(0,c).trim(),A=f.substring(c+1).trim();if(!C||!A)throw new TypeError(`Unable to parse location ref '${f}', expected '<type>:<target>', e.g. 'url:https://host/path'`);if(C==="http"||C==="https")throw new TypeError(`Invalid location ref '${f}', please prefix it with 'url:', e.g. 'url:${f}'`);if(d.test(A))throw new TypeError(`Invalid location ref '${f}', target is a javascript: URL`);return{type:C,target:A}}function m(f){const{type:c,target:C}=f;if(c){if(!C)throw new TypeError("Unable to stringify location ref, empty target")}else throw new TypeError("Unable to stringify location ref, empty type");if(d.test(C))throw new TypeError(`Invalid location ref '${c}:${C}', target is a javascript: URL`);return`${c}:${C}`}function v(f){var c,C,A,w,h;const S=(h=(C=f.metadata)===null||C===void 0||(c=C.annotations)===null||c===void 0?void 0:c[i.I4])!==null&&h!==void 0?h:(w=f.metadata)===null||w===void 0||(A=w.annotations)===null||A===void 0?void 0:A[i.Eo];if(!S)throw new Error(`Entity '${(0,o.U2)(f)}' is missing location`);return O(S)}},77310:function(Y,T,t){"use strict";t.d(T,{z:function(){return C}});var o=t(31085),i=t(10394),d=t(54917),O=t(14041),m=t(69578),v=t(40697),f=t(25577),c=t(37916);function C(A){const{text:w,language:h,showLineNumbers:S=!1,highlightedNumbers:g,customStyle:D,showCopyCodeButton:P=!1}=A,y=(0,d.A)(),j=y.palette.type==="dark"?v.A:f.A,R=y.palette.type==="dark"?"#256bf3":"#e6ffed";return(0,o.jsxs)(i.A,{position:"relative",children:[(0,o.jsx)(m.A,{customStyle:D,language:h,style:j,showLineNumbers:S,wrapLines:!0,lineNumberStyle:{color:y.palette.textVerySubtle},lineProps:x=>g!=null&&g.includes(x)?{style:{backgroundColor:R}}:{},children:w}),P&&(0,o.jsx)(i.A,{position:"absolute",top:0,right:0,children:(0,o.jsx)(c.l,{text:w})})]})}},37916:function(Y,T,t){"use strict";t.d(T,{l:function(){return w}});var o=t(31085),i=t(72427),d=t(39837),O=t(29365),m=t(71677),v=t(99594),f=t(14041),c=t(36338),C=t(10315),A=t(87849);function w(h){const{t:S}=(0,A.i)(C.O),{text:g,tooltipDelay:D=1e3,tooltipText:P=S("copyTextButton.tooltipText"),"aria-label":y="Copy text"}=h,j=(0,i.gf)(d.m),[R,x]=(0,f.useState)(!1),[{error:z},_]=(0,c.A)();(0,f.useEffect)(()=>{z&&j.post(z)},[z,j]);const tt=K=>{K.stopPropagation(),x(!0),_(g)};return(0,o.jsx)(o.Fragment,{children:(0,o.jsx)(m.Ay,{id:"copy-test-tooltip",title:P,placement:"top",leaveDelay:D,onClose:()=>x(!1),open:R,children:(0,o.jsx)(O.A,{onClick:tt,"aria-label":y,children:(0,o.jsx)(v.A,{})})})})}},44186:function(Y,T,t){"use strict";t.d(T,{p:function(){return S}});var o=t(31085),i=t(42899),d=t(58837),O=t(72501),m=t(14041),v=t.p+"static/missingAnnotation.67f79e98..svg",f=t.p+"static/noInformation.4b426325..svg",c=t.p+"static/createComponent.975d1e1e..svg",C=t.p+"static/noBuild.1715fa71..svg";const A=(0,d.A)({generalImg:{width:"95%",zIndex:2,position:"relative",left:"50%",top:"50%",transform:"translate(-50%, 15%)"}},{name:"BackstageEmptyStateImage"}),w=({missing:g})=>{const D=A();switch(g){case"field":return(0,o.jsx)("img",{src:v,className:D.generalImg,alt:"annotation is missing"});case"info":return(0,o.jsx)("img",{src:f,alt:"no Information",className:D.generalImg});case"content":return(0,o.jsx)("img",{src:c,alt:"create Component",className:D.generalImg});case"data":return(0,o.jsx)("img",{src:C,alt:"no Build",className:D.generalImg});default:return null}},h=(0,d.A)(g=>({root:{backgroundColor:g.palette.background.default,padding:g.spacing(2,0,0,0)},action:{marginTop:g.spacing(2)},imageContainer:{position:"relative"}}),{name:"BackstageEmptyState"});function S(g){const{title:D,description:P,missing:y,action:j}=g,R=h();return(0,o.jsxs)(i.A,{container:!0,direction:"row",justifyContent:"space-around",alignItems:"flex-start",className:R.root,spacing:2,children:[(0,o.jsx)(i.A,{item:!0,xs:12,md:6,children:(0,o.jsxs)(i.A,{container:!0,direction:"column",children:[(0,o.jsx)(i.A,{item:!0,xs:!0,children:(0,o.jsx)(O.A,{variant:"h5",children:D})}),(0,o.jsx)(i.A,{item:!0,xs:!0,children:(0,o.jsx)(O.A,{variant:"body1",children:P})}),(0,o.jsx)(i.A,{item:!0,xs:!0,className:R.action,children:j})]})}),(0,o.jsx)(i.A,{item:!0,xs:12,md:6,className:R.imageContainer,children:typeof y=="string"?(0,o.jsx)(w,{missing:y}):y.customImage})]})}},22020:function(Y,T,t){"use strict";t.d(T,{b:function(){return w}});var o=t(31085),i=t(58837),d=t(58007),O=t(8109),m=t(5951),v=t(14041),f=t(37916),c=t(88640);const C=(0,i.A)(h=>({text:{fontFamily:"monospace",whiteSpace:"pre",overflowX:"auto",marginRight:h.spacing(2)},divider:{margin:h.spacing(2)}}),{name:"BackstageErrorPanel"}),A=({error:h,message:S,stack:g,children:D})=>{const P=C();return(0,o.jsxs)(d.A,{dense:!0,children:[(0,o.jsxs)(O.A,{alignItems:"flex-start",children:[(0,o.jsx)(m.A,{classes:{secondary:P.text},primary:"Error",secondary:h}),(0,o.jsx)(f.l,{text:h})]}),(0,o.jsxs)(O.A,{alignItems:"flex-start",children:[(0,o.jsx)(m.A,{classes:{secondary:P.text},primary:"Message",secondary:S}),(0,o.jsx)(f.l,{text:S})]}),g&&(0,o.jsxs)(O.A,{alignItems:"flex-start",children:[(0,o.jsx)(m.A,{classes:{secondary:P.text},primary:"Stack Trace",secondary:g}),(0,o.jsx)(f.l,{text:g})]}),D]})};function w(h){const{title:S,error:g,defaultExpanded:D,titleFormat:P,children:y}=h;return(0,o.jsx)(c.B,{severity:"error",title:S!=null?S:g.message,defaultExpanded:D,titleFormat:P,children:(0,o.jsx)(A,{error:g.name,message:g.message,stack:g.stack,children:y})})}},72072:function(Y,T,t){"use strict";t.d(T,{N_:function(){return K}});var o=t(31085),i=t(72427),d=t(65461),O=t(93368),m=t(49203),v=t(58837),f=t(72501),c=t(53373),C=t.n(c),A=t(45250),w=t.n(A),h=t(14041),S=t(18690),g=t(73970);function D(){const[W]=(0,S.AV)((0,o.jsx)(S.qh,{index:!0,element:(0,o.jsx)("div",{})}));return!W.index}const P=(0,v.A)({visuallyHidden:{clip:"rect(0 0 0 0)",clipPath:"inset(50%)",overflow:"hidden",position:"absolute",userSelect:"none",whiteSpace:"nowrap",height:1,width:1},externalLink:{position:"relative"}},{name:"Link"}),y=W=>/^([a-z+.-]+):/.test(W),j=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*\:/i,R=window.open;if(R&&!R.__backstage){const W=function(...H){const J=String(H[0]);if(j.test(J))throw new Error("Rejected window.open() with a javascript: URL as a security precaution");return R.apply(this,H)};W.__backstage=!0,window.open=W}const x=()=>{try{return(0,i.gf)(d.U).getOptionalString("app.baseUrl")}catch{return}},z=()=>{const W="http://sample.dev";var G;const H=(G=x())!==null&&G!==void 0?G:"/",{pathname:J}=new URL(H,W);return(0,A.trimEnd)(J,"/")},_=W=>{let G=String(W);const H=z(),J=y(G),q=G.startsWith(H);return!J&&!q&&(G=H.concat(G)),G},tt=W=>{if(W instanceof Array)return W.map(tt).join(" ").trim();if(typeof W=="object"&&W){var G;return tt(W==null||(G=W.props)===null||G===void 0?void 0:G.children)}return["string","number"].includes(typeof W)?String(W):""},K=h.forwardRef(({onClick:W,noTrack:G,...H},J)=>{const q=P(),yt=(0,O.s)(),at=D()?_(H.to):H.to,Ot=tt(H.children)||at,ht=y(at),vt=ht&&!!/^https?:/.exec(at);if(j.test(at))throw new Error("Link component rejected javascript: URL as a security precaution");const dt=st=>{W==null||W(st),G||yt.captureEvent("click",Ot,{attributes:{to:at}})};return ht?(0,o.jsxs)(m.A,{...vt?{target:"_blank",rel:"noopener"}:{},...H,...H["aria-label"]?{"aria-label":`${H["aria-label"]}, Opens in a new window`}:{},ref:J,href:at,onClick:dt,className:C()(q.externalLink,H.className),children:[H.children,(0,o.jsx)(f.A,{component:"span",className:q.visuallyHidden,children:", Opens in a new window"})]}):(0,o.jsx)(m.A,{...H,ref:J,component:g.N_,to:at,onClick:dt})})},73896:function(Y,T,t){"use strict";t.d(T,{z:function(){return v}});var o=t(31085),i=t(64947),d=t(14041),O=t(72072);const m=d.forwardRef((c,C)=>(0,o.jsx)(O.N_,{ref:C,...c,color:"initial"})),v=d.forwardRef((c,C)=>(0,o.jsx)(i.A,{ref:C,component:m,...c})),f=null},4650:function(Y,T,t){"use strict";t.d(T,{h:function(){return w}});var o=t(31085),i=t(58837),d=t(45872),O=t(61125),m=t(14041),v=t(77310);const f=(0,i.A)(h=>({markdown:{"& table":{borderCollapse:"collapse",border:`1px solid ${h.palette.border}`},"& th, & td":{border:`1px solid ${h.palette.border}`,padding:h.spacing(1)},"& td":{wordBreak:"break-word",overflow:"hidden",verticalAlign:"middle",lineHeight:"1",margin:0,padding:h.spacing(3,2,3,2.5),borderBottom:0},"& th":{backgroundColor:h.palette.background.paper},"& tr":{backgroundColor:h.palette.background.paper},"& tr:nth-child(odd)":{backgroundColor:h.palette.background.default},"& a":{color:h.palette.link},"& img":{maxWidth:"100%"}}}),{name:"BackstageMarkdownContent"}),c=(h,S)=>S?typeof S=="string"?h+S:m.Children.toArray(S.props.children).reduce(c,h):h,C=({level:h,children:S})=>{const P=m.Children.toArray(S).reduce(c,"").toLocaleLowerCase("en-US").replace(/\W/g,"-");return m.createElement(`h${h}`,{id:P},S)},A={code:({inline:h,className:S,children:g,...D})=>{const P=String(g).replace(/\n+$/,""),y=/language-(\w+)/.exec(S||"");return!h&&y?(0,o.jsx)(v.z,{language:y[1],text:P}):(0,o.jsx)("code",{className:S,...D,children:g})},h1:C,h2:C,h3:C,h4:C,h5:C,h6:C};function w(h){const{content:S,dialect:g="gfm",linkTarget:D,transformLinkUri:P,transformImageUri:y,className:j}=h,R=f();return(0,o.jsx)(d.$,{remarkPlugins:g==="gfm"?[O.A]:[],className:`${R.markdown} ${j!=null?j:""}`.trim(),children:S,components:A,linkTarget:D,transformLinkUri:P,transformImageUri:y})}},68146:function(Y,T,t){"use strict";t.d(T,{k:function(){return v}});var o=t(31085),i=t(10394),d=t(88951),O=t(54917),m=t(14041);function v(f){const c=(0,O.A)(),[C,A]=(0,m.useState)(!1);return(0,m.useEffect)(()=>{const w=setTimeout(()=>A(!0),c.transitions.duration.short);return()=>clearTimeout(w)},[c.transitions.duration.short]),C?(0,o.jsx)(d.A,{...f,"data-testid":"progress"}):(0,o.jsx)(i.A,{display:"none"})}},66917:function(Y,T,t){"use strict";t.d(T,{w:function(){return K}});var o=t(31085),i=t(10394),d=t(69076),O=t(67720),m=t(95061),v=t(41857),f=t(48543),c=t(26343),C=t(81215),A=t(87051),w=t(12398),h=t(58837),S=t(72501),g=t(14041),D=t(10437);const P=(0,h.A)(W=>(0,w.A)({icon:{position:"absolute",right:W.spacing(.5),pointerEvents:"none",color:"#616161"}}),{name:"BackstageClosedDropdown"});var j=()=>{const W=P();return(0,o.jsx)(D.A,{className:W.icon,fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)("path",{d:"M7.5 8L6 9.5L12.0703 15.5703L18.1406 9.5L16.6406 8L12.0703 12.5703L7.5 8Z",fill:"currentColor"})})};const R=(0,h.A)(W=>(0,w.A)({icon:{position:"absolute",right:W.spacing(.5),pointerEvents:"none",color:"#616161"}}),{name:"BackstageOpenedDropdown"});var z=()=>{const W=R();return(0,o.jsx)(D.A,{className:W.icon,fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)("path",{d:"M16.5 16L18 14.5L11.9297 8.42969L5.85938 14.5L7.35938 16L11.9297 11.4297L16.5 16Z",fill:"currentColor"})})};const _=(0,A.A)(W=>(0,w.A)({root:{"label + &":{marginTop:W.spacing(3)},"&.Mui-focused > div[role=button]":{borderColor:W.palette.primary.main}},input:{borderRadius:W.shape.borderRadius,position:"relative",backgroundColor:W.palette.background.paper,border:"1px solid #ced4da",fontSize:W.typography.body1.fontSize,padding:W.spacing(1.25,3.25,1.25,1.5),transition:W.transitions.create(["border-color","box-shadow"]),"&:focus":{background:W.palette.background.paper,borderRadius:W.shape.borderRadius}}}),{name:"BackstageSelectInputBase"})(v.A),tt=(0,h.A)(W=>(0,w.A)({formControl:{margin:W.spacing(1,0),maxWidth:300},label:{transform:"initial",fontWeight:"bold",fontSize:W.typography.body2.fontSize,fontFamily:W.typography.fontFamily,color:W.palette.text.primary,"&.Mui-focused":{color:W.palette.text.primary}},formLabel:{transform:"initial",fontWeight:"bold",fontSize:W.typography.body2.fontSize,fontFamily:W.typography.fontFamily,color:W.palette.text.primary,"&.Mui-focused":{color:W.palette.text.primary}},chips:{display:"flex",flexWrap:"wrap"},chip:{margin:2},checkbox:{},root:{display:"flex",flexDirection:"column"}}),{name:"BackstageSelect"});function K(W){const{multiple:G,items:H,label:J,placeholder:q,selected:yt,onChange:at,triggerReset:Ot,native:ht=!1,disabled:vt=!1,margin:dt}=W,st=tt(),[mt,Et]=(0,g.useState)(yt||(G?[]:"")),[Tt,gt]=(0,g.useState)(!1);(0,g.useEffect)(()=>{Et(G?[]:"")},[Ot,G]),(0,g.useEffect)(()=>{Et(yt||(G?[]:""))},[yt,G]);const it=Ct=>{Et(Ct.target.value),at(Ct.target.value)},ft=Ct=>{if(vt){Ct.preventDefault();return}gt(N=>G&&!(Ct.target instanceof HTMLElement)?!0:!N)},pt=()=>{gt(!1)},Rt=Ct=>()=>{const N=mt.filter(V=>V!==Ct);Et(N),at(N)};return(0,o.jsx)(i.A,{className:st.root,children:(0,o.jsxs)(m.A,{className:st.formControl,children:[(0,o.jsx)(f.A,{className:st.formLabel,children:J}),(0,o.jsxs)(C.A,{"aria-label":J,value:mt,native:ht,disabled:vt,"data-testid":"select",displayEmpty:!0,multiple:G,margin:dt,onChange:it,open:Tt,onOpen:ft,onClose:pt,input:(0,o.jsx)(_,{}),label:J,renderValue:Ct=>{var N;return G&&mt.length!==0?(0,o.jsx)(i.A,{className:st.chips,children:Ct.map(V=>{const xt=H.find(wt=>wt.value===V);return xt?(0,o.jsx)(O.A,{label:xt==null?void 0:xt.label,clickable:!0,onDelete:Rt(V),className:st.chip},xt==null?void 0:xt.value):!1})}):(0,o.jsx)(S.A,{children:mt.length===0?q||"":(N=H.find(V=>V.value===Ct))===null||N===void 0?void 0:N.label})},IconComponent:()=>Tt?(0,o.jsx)(z,{}):(0,o.jsx)(j,{}),MenuProps:{anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},getContentAnchorEl:null},children:[q&&!G&&(0,o.jsx)(c.A,{value:[],children:q}),ht?H&&H.map(Ct=>(0,o.jsx)("option",{value:Ct.value,children:Ct.label},Ct.value)):H&&H.map(Ct=>(0,o.jsxs)(c.A,{value:Ct.value,children:[G&&(0,o.jsx)(d.A,{color:"primary",checked:mt.includes(Ct.value)||!1,className:st.checkbox}),Ct.label]},Ct.value))]})]})})}},27586:function(Y,T,t){"use strict";t.d(T,{Y:function(){return W}});var o=t(31085),i=t(82266),d=t(10394),O=t(64947),m=t(93453),v=t(29365),f=t(46423),c=t(5951),C=t(26343),A=t(28233),w=t(55197),h=t(58837),S=t(72501),g=t(5893),D=t(14041),P=t(10795),y=t(31129),j=t(72072),R=t(10315),x=t(87849);const z=(0,h.A)({popoverList:{minWidth:260,maxWidth:400},menuItem:{whiteSpace:"normal"}},{name:"BackstageSupportButton"}),_=({icon:G})=>{const H=(0,i.n)();var J;const q=G&&(J=H.getSystemIcon(G))!==null&&J!==void 0?J:y.NT;return(0,o.jsx)(q,{})},tt=({link:G})=>{var H;return(0,o.jsx)(j.N_,{to:G.url,children:(H=G.title)!==null&&H!==void 0?H:G.url})},K=({item:G})=>{var H;return(0,o.jsxs)(C.A,{children:[(0,o.jsx)(f.A,{children:(0,o.jsx)(_,{icon:G.icon})}),(0,o.jsx)(c.A,{primary:G.title,secondary:(H=G.links)===null||H===void 0?void 0:H.reduce((J,q,yt)=>[...J,yt>0&&(0,o.jsx)("br",{},yt),(0,o.jsx)(tt,{link:q},q.url)],[])})]})};function W(G){const{t:H}=(0,x.i)(R.O),{title:J,items:q,children:yt}=G,{items:at}=(0,P.l)(),[Ot,ht]=(0,D.useState)(!1),[vt,dt]=(0,D.useState)(null),st=z(),mt=(0,g.A)(gt=>gt.breakpoints.down("sm")),Et=gt=>{dt(gt.currentTarget),ht(!0)},Tt=()=>{ht(!1)};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(d.A,{display:"flex",ml:1,children:mt?(0,o.jsx)(v.A,{color:"primary",size:"small",onClick:Et,"data-testid":"support-button","aria-label":"Support",children:(0,o.jsx)(y.NT,{})}):(0,o.jsx)(O.A,{"data-testid":"support-button","aria-label":"Support",color:"primary",onClick:Et,startIcon:(0,o.jsx)(y.NT,{}),children:H("supportButton.title")})}),(0,o.jsxs)(w.Ay,{"data-testid":"support-button-popover",open:Ot,anchorEl:vt,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},onClose:Tt,children:[(0,o.jsxs)(A.A,{className:st.popoverList,autoFocusItem:!!vt,children:[J&&(0,o.jsx)(C.A,{alignItems:"flex-start",className:st.menuItem,children:(0,o.jsx)(S.A,{variant:"subtitle1",children:J})}),D.Children.map(yt,(gt,it)=>(0,o.jsx)(C.A,{alignItems:"flex-start",className:st.menuItem,children:gt},`child-${it}`)),(q!=null?q:at).map((gt,it)=>(0,o.jsx)(K,{item:gt},`item-${it}`))]}),(0,o.jsx)(m.A,{children:(0,o.jsx)(O.A,{color:"primary",onClick:Tt,"aria-label":"Close",children:H("supportButton.close")})})]})]})}},14209:function(Y,T,t){"use strict";t.d(T,{X:function(){return pt}});var o=t(31085),i=t(25301),d=t(10394),O=t(29365),m=t(87051),v=t(58837),f=t(54917),c=t(72501),C=t(83313),A=t(89019),w=t(62461),h=t(68887),S=t(63798),g=t(64704),D=t(6774),P=t(75625),y=t(65859),j=t(5416),R=t(33494),x=t(80113),z=t(26229),_=t(46802),tt=t(45250),K=t(14041),W=t(64947),G=t(66917),H=t(10315),J=t(87849);const q=(0,v.A)(N=>({root:{height:"100%",width:"315px",display:"flex",flexDirection:"column",marginRight:N.spacing(3)},value:{fontWeight:"bold",fontSize:18},header:{display:"flex",alignItems:"center",height:N.spacing(7.5),justifyContent:"space-between",borderBottom:`1px solid ${N.palette.grey[500]}`},filters:{display:"flex",flexDirection:"column","& > *":{marginTop:N.spacing(2)}}}),{name:"BackstageTableFilters"}),yt=N=>{var V;const xt=q(),{onChangeFilters:wt}=N,{t:Ft}=(0,J.i)(H.O),[It,Mt]=(0,K.useState)({...N.selectedFilters}),[Wt,St]=(0,K.useState)(!1),Nt=()=>{Mt({}),St(Xt=>!Xt)};return(0,K.useEffect)(()=>{wt(It)},[It,wt]),(0,o.jsxs)(d.A,{className:xt.root,children:[(0,o.jsxs)(d.A,{className:xt.header,children:[(0,o.jsx)(d.A,{className:xt.value,children:Ft("table.filter.title")}),(0,o.jsx)(W.A,{color:"primary",onClick:Nt,children:Ft("table.filter.clearAll")})]}),(0,o.jsx)(d.A,{className:xt.filters,children:((V=N.filters)===null||V===void 0?void 0:V.length)&&N.filters.map(Xt=>(0,o.jsx)(G.w,{triggerReset:Wt,...Xt.element,selected:It[Xt.element.label],onChange:pe=>Mt({...It,[Xt.element.label]:pe})},Xt.element.label))})]})};var at=t(78467);function Ot(N){return(0,o.jsx)("tbody",{"data-testid":"loading-indicator",children:(0,o.jsx)("tr",{children:(0,o.jsx)("td",{colSpan:N.colSpan,children:(0,o.jsx)(d.A,{sx:{display:"flex",justifyContent:"center",alignItems:"center",width:"100%",minHeight:"15rem"},children:(0,o.jsx)(at.A,{size:"5rem"})})})})})}const ht={Add:(0,K.forwardRef)((N,V)=>(0,o.jsx)(C.A,{...N,ref:V})),Check:(0,K.forwardRef)((N,V)=>(0,o.jsx)(w.A,{...N,ref:V})),Clear:(0,K.forwardRef)((N,V)=>(0,o.jsx)(g.A,{...N,ref:V})),Delete:(0,K.forwardRef)((N,V)=>(0,o.jsx)(D.A,{...N,ref:V})),DetailPanel:(0,K.forwardRef)((N,V)=>(0,o.jsx)(S.A,{...N,ref:V})),Edit:(0,K.forwardRef)((N,V)=>(0,o.jsx)(P.A,{...N,ref:V})),Export:(0,K.forwardRef)((N,V)=>(0,o.jsx)(z.A,{...N,ref:V})),Filter:(0,K.forwardRef)((N,V)=>(0,o.jsx)(y.A,{...N,ref:V})),FirstPage:(0,K.forwardRef)((N,V)=>(0,o.jsx)(j.A,{...N,ref:V})),LastPage:(0,K.forwardRef)((N,V)=>(0,o.jsx)(R.A,{...N,ref:V})),NextPage:(0,K.forwardRef)((N,V)=>(0,o.jsx)(S.A,{...N,ref:V})),PreviousPage:(0,K.forwardRef)((N,V)=>(0,o.jsx)(h.A,{...N,ref:V})),ResetSearch:(0,K.forwardRef)((N,V)=>(0,o.jsx)(g.A,{...N,ref:V})),Search:(0,K.forwardRef)((N,V)=>(0,o.jsx)(y.A,{...N,ref:V})),SortArrow:(0,K.forwardRef)((N,V)=>(0,o.jsx)(A.A,{...N,ref:V})),ThirdStateCheck:(0,K.forwardRef)((N,V)=>(0,o.jsx)(x.A,{...N,ref:V})),ViewColumn:(0,K.forwardRef)((N,V)=>(0,o.jsx)(_.A,{...N,ref:V}))};function vt(N,V){const xt=V.split(".");let wt=N[xt[0]];for(let Ft=1;Ft<xt.length;++Ft){if(wt===void 0)return wt;const It=xt[Ft];wt=wt[It]}return wt}const dt=(0,m.A)(N=>({header:{padding:N.spacing(1,2,1,2.5),borderTop:`1px solid ${N.palette.grey.A100}`,borderBottom:`1px solid ${N.palette.grey.A100}`,fontWeight:N.typography.fontWeightBold,position:"static",wordBreak:"normal",textTransform:"uppercase"}}),{name:"BackstageTableHeader"})(i.rV),st=(0,m.A)(N=>({root:{padding:N.spacing(3,0,2.5,2.5)},title:{"& > h6":{fontWeight:N.typography.fontWeightBold}},searchField:{paddingRight:N.spacing(2)}}),{name:"BackstageTableToolbar"})(i.Nb),mt=(0,v.A)(N=>({root:{display:"flex",alignItems:"center",justifyContent:"space-between"},title:{fontWeight:N.typography.fontWeightBold,fontSize:18,whiteSpace:"nowrap"}}),{name:"BackstageTableFiltersContainer"}),Et=(0,v.A)(()=>({root:{display:"flex",alignItems:"start"}}),{name:"BackstageTable"});function Tt(N,V){return N.map(xt=>{var wt;const Ft=(wt=xt.headerStyle)!==null&&wt!==void 0?wt:{};let It=xt.cellStyle||{};if(xt.highlight)if(Ft.color=V.palette.textContrast,typeof It=="object")It.fontWeight=V.typography.fontWeightBold;else{const Mt=It;It=(Wt,St,Nt)=>({...Mt(Wt,St,Nt),fontWeight:V.typography.fontWeightBold})}return{...xt,headerStyle:Ft,cellStyle:It}})}function gt(N,V){return(0,tt.transform)(N,(xt,wt,Ft)=>{(0,tt.isEqual)(wt,V[Ft])||(xt[Ft]=wt)})}const it={search:"",filtersOpen:!1,filters:{}};function ft(N){const{toolbarRef:V,setSearch:xt,hasFilters:wt,selectedFiltersLength:Ft,toggleFilters:It}=N,Mt=mt(),Wt=(0,K.useCallback)(St=>{N.onSearchChanged(St),xt(St)},[N,xt]);return wt?(0,o.jsxs)(d.A,{className:Mt.root,children:[(0,o.jsxs)(d.A,{className:Mt.root,children:[(0,o.jsx)(O.A,{onClick:It,"aria-label":"filter list",children:(0,o.jsx)(y.A,{})}),(0,o.jsxs)(c.A,{className:Mt.title,children:["Filters (",Ft,")"]})]}),(0,o.jsx)(st,{...N,ref:V,onSearchChanged:Wt})]}):(0,o.jsx)(st,{...N,ref:V,onSearchChanged:Wt})}function pt(N){const{data:V,columns:xt,emptyContent:wt,options:Ft,title:It,subtitle:Mt,localization:Wt,filters:St,initialState:Nt,onStateChange:Xt,components:pe,isLoading:ce,...de}=N,zt=Et(),qt=(0,f.A)(),ye={...it,...Nt},[ke,Ue]=(0,K.useState)(ye.filtersOpen),Ge=(0,K.useCallback)(()=>Ue(ge=>!ge),[Ue]),[Te,an]=(0,K.useState)(ye.filters),[qe,re]=(0,K.useState)(ye.search);(0,K.useEffect)(()=>{if(Xt){const ge=gt({search:qe,filtersOpen:ke,filters:Te},it);Xt(ge)}},[qe,ke,Te,Xt]);const Ke=(0,K.useCallback)(ge=>{var De;return(De=xt.find(Qe=>Qe.title===ge))===null||De===void 0?void 0:De.field},[xt]),ze=(0,K.useMemo)(()=>{if(typeof V=="function"||!Te)return V;const ge=Object.values(Te);return V&&ge.flat().length?V.filter(Qe=>!!Object.entries(Te).filter(([,Ze])=>!!Ze.length).every(([Ze,$e])=>{const He=vt(Qe,Ke(Ze));return Array.isArray(He)&&Array.isArray($e)?He.some(_e=>$e.includes(_e)):Array.isArray(He)?He.includes($e):Array.isArray($e)?$e.includes(He):He===$e})):V},[V,Te,Ke]),tn=Object.values(Te).flat().length,Ye=!!(St!=null&&St.length),Ce=(0,K.useCallback)(ge=>(0,o.jsx)(ft,{setSearch:re,hasFilters:Ye,selectedFiltersLength:tn,toggleFilters:Ge,...ge}),[Ge,Ye,tn,re]),ln=typeof V!="function"&&V.length===0,cn=xt.length,dn=(0,K.useMemo)(()=>Rt({hasNoRows:ln,emptyContent:wt,columnCount:cn,loading:ce}),[ln,wt,cn,ce]);return(0,o.jsxs)(d.A,{className:zt.root,children:[ke&&V&&typeof V!="function"&&(St==null?void 0:St.length)&&(0,o.jsx)(yt,{filters:Ct(St,V,xt),selectedFilters:Te,onChangeFilters:an}),(0,o.jsx)(i.Ay,{components:{Header:dt,Body:dn,Toolbar:Ce,...pe},options:Ft,columns:Tt(xt,qt),icons:ht,title:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(c.A,{variant:"h5",component:"h2",children:It}),Mt&&(0,o.jsx)(c.A,{color:"textSecondary",variant:"body1",children:Mt})]}),data:ze,style:{width:"100%"},localization:{toolbar:{searchPlaceholder:"Filter",searchTooltip:"Filter"},...Wt},...de})]})}pt.icons=Object.freeze(ht);function Rt({columnCount:N,emptyContent:V,hasNoRows:xt,loading:wt}){return Ft=>wt?(0,o.jsx)(Ot,{colSpan:N}):V&&xt?(0,o.jsx)("tbody",{children:(0,o.jsx)("tr",{children:(0,o.jsx)("td",{colSpan:N,children:V})})}):(0,o.jsx)(i.C6,{...Ft})}function Ct(N,V,xt){const wt=It=>{const Mt=new Set,Wt=St=>{St!=null&&Mt.add(St)};return V&&V.forEach(St=>{var Nt;const Xt=vt(St,(Nt=xt.find(pe=>pe.title===It))===null||Nt===void 0?void 0:Nt.field);Array.isArray(Xt)?Xt.forEach(Wt):Wt(Xt)}),Mt},Ft=It=>({placeholder:"All results",label:It.column,multiple:It.type==="multiple-select",items:[...wt(It.column)].sort().map(Mt=>({label:Mt,value:Mt}))});return N.map(It=>({type:It.type,element:Ft(It)}))}},88640:function(Y,T,t){"use strict";t.d(T,{B:function(){return x}});var o=t(31085),i=t(268),d=t(58837),O=t(8973),m=t(29655),v=t(91567),f=t(42899),c=t(72501),C=t(9181),A=t(6924),w=t(14041),h=t(4650);const S=(z,_)=>(_.palette.type==="light"?i.e$:i.a)(_.palette[z].light,.6),g=(z,_)=>(_.palette.type==="light"?i.a:i.e$)(_.palette[z].light,.9),D=(0,d.A)(z=>({root:{marginRight:z.spacing(1),fill:({severity:_})=>S(_,z)}})),P=({severity:z})=>{const _=D({severity:z});return(0,o.jsx)(C.A,{classes:_})},y=({severity:z})=>{const _=D({severity:z});return(0,o.jsx)(A.A,{classes:_})},j=(0,d.A)(z=>({panel:{backgroundColor:({severity:_})=>g(_,z),color:({severity:_})=>S(_,z),verticalAlign:"middle"},summary:{display:"flex",flexDirection:"row"},summaryText:{color:({severity:_})=>S(_,z),fontWeight:z.typography.fontWeightBold},markdownContent:{"& p":{display:"inline"}},message:{width:"100%",display:"block",color:({severity:_})=>S(_,z),backgroundColor:({severity:_})=>g(_,z)},details:{width:"100%",display:"block",color:z.palette.textContrast,backgroundColor:z.palette.background.default,border:`1px solid ${z.palette.border}`,padding:z.spacing(2),fontFamily:"sans-serif"}}),{name:"BackstageWarningPanel"}),R=z=>z.charAt(0).toLocaleUpperCase("en-US")+z.slice(1);function x(z){const{severity:_="warning",title:tt,titleFormat:K,message:W,children:G,defaultExpanded:H}=z,J=j({severity:_}),q=R(_)+(tt?`: ${tt}`:"");return(0,o.jsxs)(O.A,{defaultExpanded:H!=null?H:!1,className:J.panel,role:"alert",children:[(0,o.jsxs)(m.A,{expandIcon:(0,o.jsx)(y,{severity:_}),className:J.summary,children:[(0,o.jsx)(P,{severity:_}),(0,o.jsx)(c.A,{className:J.summaryText,variant:"subtitle1",children:K==="markdown"?(0,o.jsx)(h.h,{content:q,className:J.markdownContent}):q})]}),(W||G)&&(0,o.jsx)(v.A,{children:(0,o.jsxs)(f.A,{container:!0,children:[W&&(0,o.jsx)(f.A,{item:!0,xs:12,children:(0,o.jsx)(c.A,{className:J.message,variant:"body1",children:W})}),G&&(0,o.jsx)(f.A,{item:!0,xs:12,className:J.details,children:G})]})})]})}},10795:function(Y,T,t){"use strict";t.d(T,{l:function(){return v}});var o=t(72427),i=t(65461),d=t(10315),O=t(87849);const m=()=>{const{t:f}=(0,O.i)(d.O);return{url:"https://github.com/backstage/backstage/issues",items:[{title:f("supportConfig.default.title"),icon:"warning",links:[{title:f("supportConfig.default.linkTitle"),url:"https://github.com/backstage/backstage/blob/master/app-config.yaml"}]}]}};function v(){const c=(0,o.Q2)().get(i.U),C=c==null?void 0:c.getOptionalConfig("app.support"),A=m();return C?{url:C.getString("url"),items:C.getConfigArray("items").flatMap(w=>{var h;return{title:w.getString("title"),icon:w.getOptionalString("icon"),links:((h=w.getOptionalConfigArray("links"))!==null&&h!==void 0?h:[]).flatMap(S=>({url:S.getString("url"),title:S.getString("title")}))}})}:A}},31129:function(Y,T,t){"use strict";t.d(T,{NT:function(){return g},z9:function(){return m}});var o=t(31085),i=t(82266),d=t(27799),O=t(14041);function m(y){const{id:j,Fallback:R=d.A,...x}=y,z=(0,i.n)();var _;const tt=(_=z.getSystemIcon(j))!==null&&_!==void 0?_:R;return(0,o.jsx)(tt,{...x})}function v(y){return _jsx(m,{id:"brokenImage",...y})}function f(y){return _jsx(m,{id:"catalog",...y})}function c(y){return _jsx(m,{id:"chat",...y})}function C(y){return _jsx(m,{id:"dashboard",...y})}function A(y){return _jsx(m,{id:"docs",...y})}function w(y){return _jsx(m,{id:"email",...y})}function h(y){return _jsx(m,{id:"github",...y})}function S(y){return _jsx(m,{id:"group",...y})}function g(y){return(0,o.jsx)(m,{id:"help",...y})}function D(y){return _jsx(m,{id:"user",...y})}function P(y){return _jsx(m,{id:"warning",...y})}},26280:function(Y,T,t){"use strict";t.d(T,{U:function(){return f}});var o=t(31085),i=t(58837),d=t(53373),O=t.n(d),m=t(14041);const v=(0,i.A)(c=>({root:{gridArea:"pageContent",minWidth:0,paddingTop:c.spacing(3),paddingBottom:c.spacing(3),paddingLeft:c.spacing(2),paddingRight:c.spacing(2),[c.breakpoints.up("sm")]:{paddingLeft:c.spacing(3),paddingRight:c.spacing(3)}},stretch:{display:"flex",flexDirection:"column",flexGrow:1},noPadding:{padding:0}}),{name:"BackstageContent"});function f(c){const{className:C,stretch:A,noPadding:w,children:h,...S}=c,g=v();return(0,o.jsx)("article",{...S,className:O()(g.root,C,{[g.stretch]:A,[g.noPadding]:w}),children:h})}},59428:function(Y,T,t){"use strict";t.d(T,{d:function(){return C}});var o=t(31085),i=t(10394),d=t(58837),O=t(72501),m=t(14041),v=t(93285);const f=A=>(0,d.A)(w=>({container:{width:"100%",display:"flex",flexDirection:"row",flexWrap:"wrap",justifyContent:"flex-end",alignItems:"center",marginBottom:w.spacing(2),textAlign:A.textAlign},leftItemsBox:{flex:"1 1 auto",minWidth:0,overflow:"visible"},rightItemsBox:{flex:"0 1 auto",display:"flex",flexDirection:"row",flexWrap:"wrap",alignItems:"center",marginLeft:w.spacing(1),minWidth:0,overflow:"visible"},description:{},title:{display:"inline-flex",marginBottom:0}}),{name:"BackstageContentHeader"}),c=({title:A="Unknown page",className:w})=>(0,o.jsx)(O.A,{variant:"h4",component:"h2",className:w,"data-testid":"header-title",children:A});function C(A){const{description:w,title:h,titleComponent:S=void 0,children:g,textAlign:D="left"}=A,P=f({textAlign:D})(),y=S||(0,o.jsx)(c,{title:h,className:P.title});return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(v.m,{title:h}),(0,o.jsxs)(i.A,{className:P.container,children:[(0,o.jsxs)(i.A,{className:P.leftItemsBox,children:[y,w&&(0,o.jsx)(O.A,{className:P.description,variant:"body2",children:w})]}),(0,o.jsx)(i.A,{className:P.rightItemsBox,children:g})]})]})}},12173:function(Y,T,t){"use strict";t.d(T,{M:function(){return j}});var o=t(31085),i=t(42899),d=t(58837),O=t(72501),m=t(14041),v=t(18690),f=t(72072),c=t(10795),C=t.p+"static/mic-drop.fe3ef4d0..svg";const A=(0,d.A)(R=>({micDrop:{maxWidth:"60%",bottom:R.spacing(2),right:R.spacing(2),[R.breakpoints.down("xs")]:{maxWidth:"96%",bottom:"unset",right:"unset",margin:R.spacing(10,"auto",4)}}}),{name:"BackstageErrorPageMicDrop"}),w=()=>{const R=A();return(0,o.jsx)("img",{src:C,className:R.micDrop,alt:"Girl dropping mic from her hands"})};var h=t(77310),S=t(87849),g=t(10315);const D=(0,d.A)(R=>({title:{paddingBottom:R.spacing(5),[R.breakpoints.down("xs")]:{paddingBottom:R.spacing(4),fontSize:R.typography.h3.fontSize}}}),{name:"BackstageErrorPageStackDetails"});function P(R){const{stack:x}=R,z=D(),{t:_}=(0,S.i)(g.O),[tt,K]=(0,m.useState)(!1);return tt?(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(O.A,{variant:"h6",className:z.title,children:(0,o.jsx)(f.N_,{to:"#",onClick:()=>K(!1),children:_("errorPage.showLessDetails")})}),(0,o.jsx)(h.z,{text:x,language:"text",showCopyCodeButton:!0,showLineNumbers:!0})]}):(0,o.jsx)(O.A,{variant:"h6",className:z.title,children:(0,o.jsx)(f.N_,{to:"#",onClick:()=>K(!0),children:_("errorPage.showMoreDetails")})})}const y=(0,d.A)(R=>({container:{padding:R.spacing(8),[R.breakpoints.down("xs")]:{padding:R.spacing(2)}},title:{paddingBottom:R.spacing(5),[R.breakpoints.down("xs")]:{paddingBottom:R.spacing(4),fontSize:R.typography.h3.fontSize}},subtitle:{color:R.palette.textSubtle}}),{name:"BackstageErrorPage"});function j(R){const{status:x="",statusMessage:z,additionalInfo:_,supportUrl:tt,stack:K}=R,W=y(),G=(0,v.Zp)(),H=(0,c.l)(),{t:J}=(0,S.i)(g.O);return(0,o.jsxs)(i.A,{container:!0,className:W.container,children:[(0,o.jsxs)(i.A,{item:!0,xs:12,sm:8,md:4,children:[(0,o.jsx)(O.A,{"data-testid":"error",variant:"body1",className:W.subtitle,children:J("errorPage.subtitle",{status:x,statusMessage:z})}),(0,o.jsx)(O.A,{variant:"body1",className:W.subtitle,children:_}),(0,o.jsx)(O.A,{variant:"h2",className:W.title,children:J("errorPage.title")}),(0,o.jsxs)(O.A,{variant:"h6",className:W.title,children:[(0,o.jsx)(f.N_,{to:"#","data-testid":"go-back-link",onClick:()=>G(-1),children:J("errorPage.goBack")}),"... or please"," ",(0,o.jsx)(f.N_,{to:tt||H.url,children:"contact support"})," if you think this is a bug."]}),K&&(0,o.jsx)(P,{stack:K})]}),(0,o.jsx)(w,{})]})}},69814:function(Y,T,t){"use strict";t.d(T,{Y:function(){return G}});var o=t(31085),i=t(72427),d=t(65461),O=t(10394),m=t(42899),v=t(58837),f=t(71677),c=t(72501),C=t(14041),A=t(93285),w=t(72072),h=t(45634),S=t(58007),g=t(8109),D=t(55197),P=t(87051);const y=(0,P.A)({root:{textDecoration:"underline",cursor:"pointer"}},{name:"BackstageBreadcrumbsClickableText"})(c.A),j=(0,P.A)({root:{textDecoration:"underline",color:"inherit"}},{name:"BackstageBreadcrumbsStyledBox"})(O.A),R=(0,P.A)({root:{fontStyle:"italic"}},{name:"BreadcrumbsCurrentPage"})(O.A);function x(H){const{children:J,...q}=H,[yt,at]=C.useState(null),Ot=C.Children.toArray(J),[ht,vt,...dt]=Ot,st=dt.length?dt.pop():Ot[Ot.length-1],mt=Ot.length>3,Et=it=>{at(it.currentTarget)},Tt=()=>{at(null)},gt=!!yt;return(0,o.jsxs)(C.Fragment,{children:[(0,o.jsxs)(h.A,{"aria-label":"breadcrumb",...q,children:[Ot.length>1&&(0,o.jsx)(j,{clone:!0,children:ht}),Ot.length>2&&(0,o.jsx)(j,{clone:!0,children:vt}),mt&&(0,o.jsx)(y,{onClick:Et,children:"..."}),(0,o.jsx)(R,{children:st})]}),(0,o.jsx)(D.Ay,{open:gt,anchorEl:yt,onClose:Tt,anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},children:(0,o.jsx)(S.A,{children:dt.map((it,ft)=>(0,o.jsx)(g.A,{button:!0,children:(0,o.jsx)(j,{clone:!0,children:it})},ft))})})]})}var z=t(73524);const _=(0,v.A)(H=>({header:{gridArea:"pageHeader",padding:H.spacing(3),width:"100%",boxShadow:H.shadows[4],position:"relative",zIndex:100,display:"flex",flexDirection:"row",alignItems:"center",backgroundImage:H.page.backgroundImage,backgroundPosition:"center",backgroundSize:"cover",[H.breakpoints.down("sm")]:{flexWrap:"wrap"}},leftItemsBox:{maxWidth:"100%",flexGrow:1},rightItemsBox:{width:"auto",alignItems:"center"},title:{color:H.page.fontColor,wordBreak:"break-word",fontSize:H.typography.h3.fontSize,marginBottom:0},subtitle:{color:H.page.fontColor,opacity:.8,display:"inline-block",marginTop:H.spacing(1),maxWidth:"75ch"},type:{textTransform:"uppercase",fontSize:11,opacity:.8,marginBottom:H.spacing(1),color:H.page.fontColor},breadcrumb:{color:H.page.fontColor},breadcrumbType:{fontSize:"inherit",opacity:.7,marginRight:-H.spacing(.3),marginBottom:H.spacing(.3)},breadcrumbTitle:{fontSize:"inherit",marginLeft:-H.spacing(.3),marginBottom:H.spacing(.3)}}),{name:"BackstageHeader"}),tt=({type:H,typeLink:J,classes:q,pageTitle:yt})=>H?J?(0,o.jsxs)(x,{className:q.breadcrumb,children:[(0,o.jsx)(w.N_,{to:J,children:H}),(0,o.jsx)(c.A,{children:yt})]}):(0,o.jsx)(c.A,{className:q.type,children:H}):null,K=({pageTitle:H,classes:J,tooltip:q})=>{const{contentRef:yt}=(0,z.H)(),at=(0,o.jsx)(c.A,{ref:yt,tabIndex:-1,className:J.title,variant:"h1",children:H});return q?(0,o.jsx)(f.Ay,{title:q,placement:"top-start",children:at}):at},W=({classes:H,subtitle:J})=>J?typeof J!="string"?(0,o.jsx)(o.Fragment,{children:J}):(0,o.jsx)(c.A,{className:H.subtitle,variant:"subtitle2",component:"span",children:J}):null;function G(H){const{children:J,pageTitleOverride:q,style:yt,subtitle:at,title:Ot,tooltip:ht,type:vt,typeLink:dt}=H,st=_(),Et=(0,i.gf)(d.U).getOptionalString("app.title")||"Backstage",Tt=q||Ot,gt=Ot||q,it=`${Tt} | %s | ${Et}`,ft=`${Tt} | ${Et}`;return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(A.m,{titleTemplate:it,defaultTitle:ft}),(0,o.jsxs)("header",{style:yt,className:st.header,children:[(0,o.jsxs)(O.A,{className:st.leftItemsBox,children:[(0,o.jsx)(tt,{classes:st,type:vt,typeLink:dt,pageTitle:gt}),(0,o.jsx)(K,{classes:st,pageTitle:gt,tooltip:ht}),(0,o.jsx)(W,{classes:st,subtitle:at})]}),(0,o.jsx)(m.A,{container:!0,className:st.rightItemsBox,spacing:4,children:J})]})]})}},24504:function(Y,T,t){"use strict";t.d(T,{Y:function(){return v}});var o=t(31085),i=t(14041),d=t(58837),O=t(50868);const m=(0,d.A)(f=>({root:{display:"grid",gridTemplateAreas:"'pageHeader pageHeader pageHeader' 'pageSubheader pageSubheader pageSubheader' 'pageNav pageContent pageSidebar'",gridTemplateRows:"max-content auto 1fr",gridTemplateColumns:"auto 1fr auto",overflowY:"auto",height:"100vh",[f.breakpoints.down("xs")]:{height:"100%"},"@media print":{display:"block",height:"auto",overflowY:"inherit"}}}),{name:"BackstagePage"});function v(f){const{themeId:c,children:C}=f,A=m();return(0,o.jsx)(O.A,{theme:w=>({...w,page:w.getPageTheme({themeId:c})}),children:(0,o.jsx)("main",{className:A.root,children:C})})}},27155:function(Y,T,t){"use strict";t.d(T,{d:function(){return m}});var o=t(31085),i=t(14041),d=t(69814),O=t(24504);function m(v){const{themeId:f,children:c,...C}=v;return(0,o.jsxs)(O.Y,{themeId:f,children:[(0,o.jsx)(d.Y,{...C}),c]})}},73524:function(Y,T,t){"use strict";t.d(T,{G:function(){return h},H:function(){return S}});var o=t(31085),i=t(10394),d=t(58837),O=t(5893),m=t(14041),v=t(72664),f;(function(g){g.SIDEBAR_PIN_STATE="sidebarPinState"})(f||(f={}));const c={getSidebarPinState(){let g;try{g=JSON.parse(window.localStorage.getItem("sidebarPinState")||"true")}catch{return!0}return!!g},setSidebarPinState(g){return window.localStorage.setItem("sidebarPinState",JSON.stringify(g))}};var C=t(34435);const A=(0,d.A)(g=>({root:{width:"100%",transition:"padding-left 0.1s ease-out",isolation:"isolate",[g.breakpoints.up("sm")]:{paddingLeft:D=>D.isPinned?D.sidebarConfig.drawerWidthOpen:D.sidebarConfig.drawerWidthClosed},[g.breakpoints.down("xs")]:{paddingBottom:D=>D.sidebarConfig.mobileSidebarHeight},"@media print":{padding:"0px !important"}},content:{zIndex:0,isolation:"isolate","&:focus":{outline:0}}}),{name:"BackstageSidebarPage"}),w=(0,m.createContext)({content:{contentRef:void 0}});function h(g){const[D,P]=(0,m.useState)(()=>c.getSidebarPinState()),{sidebarConfig:y}=(0,m.useContext)(v.yY),j=(0,m.useRef)(null),R=(0,m.useMemo)(()=>({content:{contentRef:j}}),[j]);(0,m.useEffect)(()=>{c.setSidebarPinState(D)},[D]);const x=(0,O.A)(tt=>tt.breakpoints.down("xs"),{noSsr:!0}),z=()=>P(!D),_=A({isPinned:D,sidebarConfig:y});return(0,o.jsx)(C.qj,{value:{isPinned:D,toggleSidebarPinState:z,isMobile:x},children:(0,o.jsx)(w.Provider,{value:R,children:(0,o.jsx)(i.A,{className:_.root,children:g.children})})})}function S(){const{content:g}=(0,m.useContext)(w);return{focusContent:(0,m.useCallback)(()=>{var P,y;g==null||(y=g.contentRef)===null||y===void 0||(P=y.current)===null||P===void 0||P.focus()},[g]),contentRef:g==null?void 0:g.contentRef}}},34435:function(Y,T,t){"use strict";t.d(T,{Ut:function(){return C},qj:function(){return c}});var o=t(31085),i=t(43836),d=t(10602),O=t(14041);const m={isPinned:!0,toggleSidebarPinState:()=>{},isMobile:!1},v=(0,O.createContext)(m),f=(0,i.tK)("sidebar-pin-state-context");function c(A){const{children:w,value:h}=A;return(0,o.jsx)(v.Provider,{value:h,children:(0,o.jsx)(f.Provider,{value:(0,d.B)({1:h}),children:w})})}const C=()=>{const A=(0,O.useContext)(f),w=(0,O.useContext)(v);if(A===void 0)return w||m;const h=A.atVersion(1);if(h===void 0)throw new Error("No context found for version 1.");return h}},72664:function(Y,T,t){"use strict";t.d(T,{Rv:function(){return v},U1:function(){return w},hC:function(){return m},i8:function(){return c},yY:function(){return A}});var o=t(14041);const i=72,d=24,O=18,m={drawerWidthClosed:i,drawerWidthOpen:224,defaultOpenDelayMs:100,defaultCloseDelayMs:0,defaultFadeDuration:200,logoHeight:32,iconContainerWidth:i,iconSize:i-d*2,iconPadding:d,selectedIndicatorWidth:3,userBadgePadding:O,userBadgeDiameter:i-O*2,mobileSidebarHeight:56},v=h=>({...m,...h,iconContainerWidth:m.drawerWidthClosed,iconSize:m.drawerWidthClosed-m.iconPadding*2,userBadgeDiameter:m.drawerWidthClosed-m.userBadgePadding*2}),f={drawerWidthClosed:0,drawerWidthOpen:202,defaultOpenDelayMs:m.defaultOpenDelayMs+200},c=h=>({...f,...h}),C="@backstage/core/sidebar-intro-dismissed",A=(0,o.createContext)({sidebarConfig:m,submenuConfig:f}),w=(0,o.createContext)({isHoveredOn:!1,setIsHoveredOn:()=>{}})},10315:function(Y,T,t){"use strict";t.d(T,{O:function(){return i}});var o=t(93184);const i=(0,o.h)({id:"core-components",messages:{signIn:{title:"Sign In",loginFailed:"Login failed",customProvider:{title:"Custom User",subtitle:`Enter your own User ID and credentials.
2
+ This selection will not be stored.`,userId:"User ID",tokenInvalid:"Token is not a valid OpenID Connect JWT Token",continue:"Continue",idToken:"ID Token (optional)"},guestProvider:{title:"Guest",subtitle:`Enter as a Guest User.
3
+ You will not have a verified identity, meaning some features might be unavailable.`,enter:"Enter"}},skipToContent:"Skip to content",copyTextButton:{tooltipText:"Text copied to clipboard"},simpleStepper:{reset:"Reset",finish:"Finish",next:"Next",skip:"Skip",back:"Back"},errorPage:{subtitle:"ERROR {{status}}: {{statusMessage}}",title:"Looks like someone dropped the mic!",goBack:"Go back",showMoreDetails:"Show more details",showLessDetails:"Show less details"},emptyState:{missingAnnotation:{title:"Missing Annotation",actionTitle:"Add the annotation to your component YAML as shown in the highlighted example below:",readMore:"Read more"}},supportConfig:{default:{title:"Support Not Configured",linkTitle:"Add `app.support` config key"}},errorBoundary:{title:"Please contact {{slackChannel}} for help."},oauthRequestDialog:{title:"Login Required",authRedirectTitle:"This will trigger a http redirect to OAuth Login.",login:"Log in",rejectAll:"Reject All"},supportButton:{title:"Support",close:"Close"},table:{filter:{title:"Filters",clearAll:"Clear all"}},alertDisplay:{message_one:"({{ count }} older message)",message_other:"({{ count }} older messages)"},autoLogout:{stillTherePrompt:{title:"Logging out due to inactivity",buttonText:"Yes! Don't log me out"}},proxiedSignInPage:{title:"You do not appear to be signed in. Please try reloading the browser page."}}})},25862:function(Y,T,t){"use strict";t.d(T,{Ig:function(){return f},pn:function(){return v}});var o=t(31085),i=t(43836),d=t(10602),O=t(14041);const m=(0,i.tK)("analytics-context"),v=()=>{const C=(0,O.useContext)(m);if(C===void 0)return{routeRef:"unknown",pluginId:"root",extension:"App"};const A=C.atVersion(1);if(A===void 0)throw new Error("No context found for version 1.");return A},f=C=>{const{attributes:A,children:w}=C,S={...v(),...A},g=(0,d.B)({1:S});return(0,o.jsx)(m.Provider,{value:g,children:w})};function c(C,A){const w=h=>_jsx(f,{attributes:A,children:_jsx(C,{...h})});return w.displayName=`WithAnalyticsContext(${C.displayName||C.name||"Component"})`,w}},67237:function(Y,T,t){"use strict";t.d(T,{J:function(){return m},t:function(){return O}});var o=t(18990),i=t(63544);const d=(0,i.Q)("core-plugin-api:analytics-tracker-events",()=>({mostRecentGatheredNavigation:void 0,mostRecentRoutableExtensionRender:void 0,beforeUnloadRegistered:!1})),O="_ROUTABLE-EXTENSION-RENDERED";class m{setContext(f){this.context=f}captureEvent(f,c,{value:C,attributes:A}={}){const{_routeNodeType:w,...h}=this.context;if(f===O){d.mostRecentGatheredNavigation&&(d.mostRecentRoutableExtensionRender={context:{...h,extension:"App"}});return}if(d.mostRecentGatheredNavigation){try{this.analyticsApi.captureEvent({...d.mostRecentGatheredNavigation,...d.mostRecentRoutableExtensionRender})}catch(S){console.warn("Error during analytics event capture. %o",S)}d.mostRecentGatheredNavigation=void 0,d.mostRecentRoutableExtensionRender=void 0}if(f==="navigate"&&w==="gathered"&&h.pluginId==="root"){d.mostRecentGatheredNavigation={action:f,subject:c,value:C,attributes:A,context:h};return}try{this.analyticsApi.captureEvent({action:f,subject:c,value:C,attributes:A,context:h})}catch(S){console.warn("Error during analytics event capture. %o",S)}}constructor(f,c={routeRef:"unknown",pluginId:"root",extension:"App"}){(0,o._)(this,"analyticsApi",void 0),(0,o._)(this,"context",void 0),this.analyticsApi=f,this.context=c,d.beforeUnloadRegistered||(addEventListener("beforeunload",()=>{d.mostRecentGatheredNavigation&&(this.analyticsApi.captureEvent({...d.mostRecentGatheredNavigation,...d.mostRecentRoutableExtensionRender}),d.mostRecentGatheredNavigation=void 0,d.mostRecentRoutableExtensionRender=void 0)},{once:!0,passive:!0}),d.beforeUnloadRegistered=!0)}}},93368:function(Y,T,t){"use strict";t.d(T,{s:function(){return f}});var o=t(25862),i=t(72427),d=t(99303),O=t(14041),m=t(67237);function v(){try{return(0,i.gf)(d.c)}catch{return{captureEvent:()=>{}}}}function f(){const c=(0,O.useRef)(null),C=(0,o.pn)(),A=v();function w(){return c.current===null&&(c.current=new m.J(A)),c.current}const h=w();return h.setContext(C),h}},36017:function(Y,T,t){"use strict";t.d(T,{k:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.alert"})},99303:function(Y,T,t){"use strict";t.d(T,{c:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.analytics"})},65461:function(Y,T,t){"use strict";t.d(T,{U:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.config"})},57405:function(Y,T,t){"use strict";t.d(T,{I:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.discovery"})},39837:function(Y,T,t){"use strict";t.d(T,{m:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.error"})},63636:function(Y,T,t){"use strict";t.d(T,{B:function(){return d},S:function(){return i}});var o=t(55309),i;(function(O){O[O.None=0]="None",O[O.Active=1]="Active"})(i||(i={}));const d=(0,o.y)({id:"core.featureflags"})},70795:function(Y,T,t){"use strict";t.d(T,{a:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.fetch"})},16009:function(Y,T,t){"use strict";t.d(T,{K:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.identity"})},56038:function(Y,T,t){"use strict";t.d(T,{J:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"core.translation"})},55309:function(Y,T,t){"use strict";t.d(T,{y:function(){return d}});var o=t(18990);class i{get id(){return this.config.id}get T(){throw new Error(`tried to read ApiRef.T of ${this}`)}toString(){return`apiRef{${this.config.id}}`}constructor(m){if((0,o._)(this,"config",void 0),this.config=m,!m.id.split(".").flatMap(f=>f.split("-")).every(f=>f.match(/^[a-z][a-z0-9]*$/)))throw new Error(`API id must only contain period separated lowercase alphanum tokens with dashes, got '${m.id}'`)}}function d(O){return new i(O)}},12935:function(Y,T,t){"use strict";t.d(T,{b:function(){return o}});function o(i,d){return"id"in i?{api:i,deps:{},factory:()=>d}:i}},72427:function(Y,T,t){"use strict";t.d(T,{Q2:function(){return m},gf:function(){return v}});var o=t(31085),i=t(14041),d=t(43836),O=t(97142);function m(){const c=(0,d.qO)("api-context");if(!c)throw new O.EH("API context is not available");const C=c.atVersion(1);if(!C)throw new O.EH("ApiContext v1 not available");return C}function v(c){const A=m().get(c);if(!A)throw new O.EH(`No implementation available for ${c}`);return A}function f(c){return function(A){const w=S=>{const g=m(),D={};for(const P in c)if(c.hasOwnProperty(P)){const y=c[P],j=g.get(y);if(!j)throw new NotImplementedError(`No implementation available for ${y}`);D[P]=j}return _jsx(A,{...S,...D})},h=A.displayName||A.name||"Component";return w.displayName=`withApis(${h})`,w}}},82266:function(Y,T,t){"use strict";t.d(T,{n:function(){return i}});var o=t(43836);const i=()=>{const d=(0,o.qO)("app-context");if(!d)throw new Error("App context is not available");const O=d.atVersion(1);if(!O)throw new Error("AppContext v1 not available");return O}},19402:function(Y,T,t){"use strict";t.d(T,{E:function(){return m},h:function(){return O}});var o=t(63544);const i=(0,o.Q)("component-data-store",()=>new WeakMap),d="__backstage_data";function O(v,f,c){const C=v;var A;let w=(A=C[d])!==null&&A!==void 0?A:i.get(v);if(w||(w={map:new Map},Object.defineProperty(C,d,{enumerable:!1,configurable:!0,writable:!1,value:w}),i.set(v,w)),w.map.has(f)){const h=v.displayName||v.name;throw new Error(`Attempted to attach duplicate data "${f}" to component "${h}"`)}w.map.set(f,c)}function m(v,f){if(!v)return;const c=v.type;if(!c)return;var C;const A=(C=c[d])!==null&&C!==void 0?C:i.get(c);if(A)return A.map.get(f)}},88758:function(Y,T,t){"use strict";t.d(T,{NC:function(){return h},zZ:function(){return S},QJ:function(){return w}});var o=t(31085),i=t(14041),d=t(93368),O=t(25862),m=t(82266),v=t(9222),f=t(19402),c=t(18990);class C extends i.Component{static getDerivedStateFromError(D){return{error:D}}render(){const{error:D}=this.state,{app:P,plugin:y}=this.props,{ErrorBoundaryFallback:j}=P.getComponents();return D?(0,o.jsx)(j,{error:D,resetError:this.handleErrorReset,plugin:y}):this.props.children}constructor(...D){super(...D),(0,c._)(this,"state",{error:void 0}),(0,c._)(this,"handleErrorReset",()=>{this.setState({error:void 0})})}}var A=t(67237);function w(g){const{component:D,mountPoint:P,name:y}=g;return S({component:{lazy:()=>D().then(j=>{const R=z=>{const _=(0,d.s)();try{(0,v.S)(P)}catch(tt){if(typeof tt=="object"&&tt!==null){const{message:K}=tt;if(typeof K=="string"&&K.startsWith("No path for "))throw new Error(`Routable extension component with mount point ${P} was not discovered in the app element tree. Routable extension components may not be rendered by other components and must be directly available as an element within the App provider component.`)}throw tt}return(0,i.useEffect)(()=>{_.captureEvent(A.t,"")},[_]),(0,o.jsx)(j,{...z})},x=y||j.displayName||j.name||"LazyComponent";return R.displayName=`RoutableExtension(${x})`,R},j=>x=>{const z=(0,m.n)(),{BootErrorPage:_}=z.getComponents();return(0,o.jsx)(_,{step:"load-chunk",error:j})})},data:{"core.mountPoint":P},name:y})}function h(g){const{component:D,name:P}=g;return S({component:D,name:P})}function S(g){const{data:D={},name:P}=g;P||console.warn("Declaring extensions without name is DEPRECATED. Make sure that all usages of createReactExtension, createComponentExtension and createRoutableExtension provide a name.");let y;if("lazy"in g.component){const R=g.component.lazy;y=(0,i.lazy)(()=>R().then(x=>({default:x})))}else y=g.component.sync;const j=P||y.displayName||y.name||"Component";return{expose(R){const x=z=>{const _=(0,m.n)(),{Progress:tt}=_.getComponents(),K=D==null?void 0:D["core.mountPoint"];return(0,o.jsx)(i.Suspense,{fallback:(0,o.jsx)(tt,{}),children:(0,o.jsx)(C,{app:_,plugin:R,children:(0,o.jsx)(O.Ig,{attributes:{pluginId:R.getId(),...P&&{extension:P},...K&&{routeRef:K.id}},children:(0,o.jsx)(y,{...z})})})})};(0,f.h)(x,"core.plugin",R),(0,f.h)(x,"core.extensionName",P);for(const[z,_]of Object.entries(D))(0,f.h)(x,z,_);return x.displayName=`Extension(${j})`,x}}}},82442:function(Y,T,t){"use strict";t.d(T,{O:function(){return c}});var o=t(18990),i=t(14041),d=t(19402),O=t(72427),m=t(63636);function v(C,A,w,h){return i.Children.toArray(C).flatMap(S=>{if(!(0,i.isValidElement)(S))return[];if(S.type===i.Fragment)return v(S.props.children,A,w,h);if((0,d.E)(S,"core.featureFlagged")){const g=S.props;return("with"in g?A.isActive(g.with):!A.isActive(g.without))?v(S.props.children,A,w,h):[]}if(w===void 0||w(S))return[S];if(h)throw new Error(h);return v(S.props.children,A,w,h)})}class f{selectByComponentData(A){const w=v(this.node,this.featureFlagsApi,h=>(0,d.E)(h,A.key)!==void 0,A.withStrictError);return new f(w,this.featureFlagsApi)}findComponentData(A){return v(this.node,this.featureFlagsApi,h=>(0,d.E)(h,A.key)!==void 0).map(h=>(0,d.E)(h,A.key)).filter(h=>h!==void 0)}getElements(){return v(this.node,this.featureFlagsApi)}constructor(A,w){(0,o._)(this,"node",void 0),(0,o._)(this,"featureFlagsApi",void 0),this.node=A,this.featureFlagsApi=w}}function c(C,A,w=[]){const h=(0,O.gf)(m.B),S=new f(C,h);return(0,i.useMemo)(()=>A(S),[C,...w])}},9803:function(Y,T,t){"use strict";t.d(T,{i:function(){return d}});var o=t(18990);class i{getId(){return this.config.id}getApis(){var m;return(m=this.config.apis)!==null&&m!==void 0?m:[]}getFeatureFlags(){var m,v;return(v=(m=this.config.featureFlags)===null||m===void 0?void 0:m.slice())!==null&&v!==void 0?v:[]}get routes(){var m;return(m=this.config.routes)!==null&&m!==void 0?m:{}}get externalRoutes(){var m;return(m=this.config.externalRoutes)!==null&&m!==void 0?m:{}}provide(m){return m.expose(this)}toString(){return`plugin{${this.config.id}}`}constructor(m){(0,o._)(this,"config",void 0),this.config=m}}function d(O){return new i(O)}},34569:function(Y,T,t){"use strict";t.d(T,{H:function(){return v}});var o=t(18990),i=t(59598);let d=i.b,O=d;class m{get title(){return this.id}toString(){return`routeRef{type=absolute,id=${this.id}}`}constructor(c,C){(0,o._)(this,"id",void 0),(0,o._)(this,"params",void 0),(0,o._)(this,O,void 0),this.id=c,this.params=C,this[d]="absolute"}}function v(f){var c;return new m(f.id,(c=f.params)!==null&&c!==void 0?c:[])}},59598:function(Y,T,t){"use strict";t.d(T,{b:function(){return i}});var o=t(63544);const i=(0,o.Q)("route-ref-type",()=>Symbol("route-ref-type"))},9222:function(Y,T,t){"use strict";t.d(T,{S:function(){return O}});var o=t(14041),i=t(18690),d=t(43836);function O(m){const{pathname:v}=(0,i.zy)(),f=(0,d.qO)("routing-context");if(!f)throw new Error("Routing context is not available");const c=f.atVersion(1),C=(0,o.useMemo)(()=>c&&c.resolve(m,{pathname:v}),[c,m,v]);if(!f)throw new Error("useRouteRef used outside of routing context");if(!c)throw new Error("RoutingContext v1 not available");const A="optional"in m&&m.optional;if(!C&&!A)throw new Error(`No path for ${m}`);return C}},93184:function(Y,T,t){"use strict";t.d(T,{h:function(){return w},v:function(){return h}});var o=t(96324),i=t(87081),d=t(33284),O=t(18990),m=t(99833);function v(S){const g=new Array;function D(P,y){for(const[j,R]of Object.entries(P))typeof R=="string"?g.push([y+j,R]):D(R,`${y}${j}.`)}return D(S,""),Object.fromEntries(g)}var f=new WeakMap,c=new WeakMap,C=new WeakMap;class A{get id(){return(0,o._)(this,f)}get T(){throw new Error("Not implemented")}getDefaultMessages(){return(0,o._)(this,c)}setDefaultResource(g){(0,d._)(this,C,g)}getDefaultResource(){return(0,o._)(this,C)}toString(){return`TranslationRef{id=${this.id}}`}constructor(g){(0,i._)(this,f,{writable:!0,value:void 0}),(0,i._)(this,c,{writable:!0,value:void 0}),(0,i._)(this,C,{writable:!0,value:void 0}),(0,O._)(this,"$$type","@backstage/TranslationRef"),(0,O._)(this,"version","v1"),(0,d._)(this,f,g.id),(0,d._)(this,c,v(g.messages))}}function w(S){const g=new A(S);return S.translations&&g.setDefaultResource((0,m.o)({ref:g,translations:S.translations})),g}function h(S){const g=S;if(g.$$type!=="@backstage/TranslationRef")throw new Error(`Invalid translation ref, bad type '${g.$$type}'`);if(g.version!=="v1")throw new Error(`Invalid translation ref, bad version '${g.version}'`);return g}},99833:function(Y,T,t){"use strict";t.d(T,{Y:function(){return o},o:function(){return i}});function o(d){const O=d;if(O.$$type!=="@backstage/TranslationResource")throw new Error(`Invalid translation resource, bad type '${O.$$type}'`);if(O.version!=="v1")throw new Error(`Invalid translation resource, bad version '${O.version}'`);return O}function i(d){return{$$type:"@backstage/TranslationResource",version:"v1",id:d.ref.id,resources:Object.entries(d.translations).map(([O,m])=>({language:O,loader:()=>m().then(v=>{const f=v.default;return{messages:(f==null?void 0:f.$$type)==="@backstage/TranslationMessages"?f.messages:f}})}))}}},87849:function(Y,T,t){"use strict";t.d(T,{i:function(){return v}});var o=t(14041),i=t(72427),d=t(39837),O=t(56038);const m=new WeakSet,v=f=>{const c=(0,i.gf)(d.m),C=(0,i.gf)(O.J),[A,w]=(0,o.useState)(()=>C.getTranslation(f)),h=(0,o.useMemo)(()=>C.translation$(f),[C,f]),S=(0,o.useCallback)(D=>{if(!m.has(f)){const P=`Failed to load translation resource '${f.id}'; caused by ${D}`;console.error(P),c.post(new Error(P)),m.add(f)}},[c,f]);(0,o.useEffect)(()=>{const D=h.subscribe({next(P){P.ready&&w(P)},error(P){S(P)}});return()=>{D.unsubscribe()}},[h,S]);const g=(0,o.useRef)(!0);if((0,o.useEffect)(()=>{g.current?g.current=!1:w(C.getTranslation(f))},[C,f]),!A.ready)throw new Promise(D=>{const P=h.subscribe({next(y){y.ready&&(P.unsubscribe(),D())},error(y){P.unsubscribe(),S(y),D()}})});return{t:A.t}}},70835:function(Y,T,t){"use strict";t.d(T,{o:function(){return O}});var o=t(18990),i=t(59750);async function d(m){try{const f=await m.text();if(f){var v;if(!((v=m.headers.get("content-type"))===null||v===void 0)&&v.startsWith("application/json"))try{const c=JSON.parse(f);if(c.error&&c.response)return c}catch{}return{error:{name:"Error",message:`Request failed with status ${m.status} ${m.statusText}, ${f}`},response:{statusCode:m.status}}}}catch{}return{error:{name:"Error",message:`Request failed with status ${m.status} ${m.statusText}`},response:{statusCode:m.status}}}class O extends Error{static async fromResponse(v){const f=await d(v),c=f.response.statusCode||v.status,C=v.statusText,A=`Request failed with ${c} ${C}`,w=(0,i.cy)(f.error);return new O({message:A,response:v,data:f,cause:w,statusCode:c,statusText:C})}constructor(v){super(v.message),(0,o._)(this,"response",void 0),(0,o._)(this,"body",void 0),(0,o._)(this,"cause",void 0),(0,o._)(this,"statusCode",void 0),(0,o._)(this,"statusText",void 0),this.name="ResponseError",this.response=v.response,this.body=v.data,this.cause=v.cause,this.statusCode=v.statusCode,this.statusText=v.statusText}}},93007:function(Y,T,t){"use strict";t.d(T,{b:function(){return o}});function o(d){if(typeof d!="object"||d===null||Array.isArray(d))return!1;const O=d;return!(typeof O.name!="string"||O.name===""||typeof O.message!="string")}function i(d){if(typeof d!="object"||d===null||Array.isArray(d))throw new Error(`Encountered invalid error, not an object, got '${d}'`);const O=d;if(typeof O.name!="string"||O.name==="")throw new Error(`Encountered error object without a name, got '${d}'`);if(typeof O.message!="string")throw new Error(`Encountered error object without a message, got '${d}'`)}},97142:function(Y,T,t){"use strict";t.d(T,{m_:function(){return c},EH:function(){return w}});var o=t(18990),i=t(93007),d=t(59750);class O extends Error{constructor(D,P){var y,j;let R=D;if(P!==void 0){const x=(0,d.M5)(P);R?R+=`; caused by ${x}`:R=`caused by ${x}`}super(R),(0,o._)(this,"cause",void 0),(y=(j=Error).captureStackTrace)===null||y===void 0||y.call(j,this,this.constructor),(!this.name||this.name==="Error")&&this.constructor.name!=="Error"&&(this.name=this.constructor.name),this.cause=(0,i.b)(P)?P:void 0}}class m extends O{constructor(...D){super(...D),(0,o._)(this,"name","InputError")}}class v extends O{constructor(...D){super(...D),(0,o._)(this,"name","AuthenticationError")}}class f extends O{constructor(...D){super(...D),(0,o._)(this,"name","NotAllowedError")}}class c extends O{constructor(...D){super(...D),(0,o._)(this,"name","NotFoundError")}}class C extends O{constructor(...D){super(...D),(0,o._)(this,"name","ConflictError")}}class A extends O{constructor(...D){super(...D),(0,o._)(this,"name","NotModifiedError")}}class w extends O{constructor(...D){super(...D),(0,o._)(this,"name","NotImplementedError")}}class h extends null{}class S extends O{constructor(D,P){super(D,P),this.name=(0,i.b)(P)?P.name:"Error"}}},59750:function(Y,T,t){"use strict";t.d(T,{M5:function(){return v},cy:function(){return m}});var o=t(69655),i=t.n(o),d=t(93007);function O(f,c){const A={name:"Unknown",message:"<no reason given>",...serializeErrorInternal(f)};return c!=null&&c.includeStack||delete A.stack,A}function m(f){const c=(0,o.deserializeError)(f);return f.stack||(c.stack=void 0),c}function v(f){if((0,d.b)(f)){const c=String(f);return c!=="[object Object]"?c:`${f.name}: ${f.message}`}return`unknown error '${f}'`}},3347:function(Y,T,t){"use strict";t.d(T,{L:function(){return un},Y:function(){return In}});var o=t(18990),i=t(59869);const d="amazonaws.com";function O(M){var u;const L=M.getOptionalString("endpoint");var U;const ot=(U=M.getOptionalBoolean("s3ForcePathStyle"))!==null&&U!==void 0?U:!1;let nt,ut;if(L){try{const Gt=new URL(L);nt=Gt.host,ut=Gt.pathname}catch{throw new Error(`invalid awsS3 integration config, endpoint '${L}' is not a valid URL`)}if(ut!=="/")throw new Error(`invalid awsS3 integration config, endpoints cannot contain path, got '${L}'`)}else nt=d;const jt=M.getOptionalString("accessKeyId"),$t=(u=M.getOptionalString("secretAccessKey"))===null||u===void 0?void 0:u.trim(),ue=M.getOptionalString("roleArn"),ae=M.getOptionalString("externalId");return{host:nt,endpoint:L,s3ForcePathStyle:ot,accessKeyId:jt,secretAccessKey:$t,roleArn:ue,externalId:ae}}function m(M){const u=M.map(O);return u.some(L=>L.host===d)||u.push({host:d}),u}class v{get type(){return"awsS3"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){return(0,i.ku)(u)}resolveEditUrl(u){return u}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(v,"factory",({config:M})=>{var u;const L=m((u=M.getOptionalConfigArray("integrations.awsS3"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new v(U)),U=>U.config.host)});const f="console.aws.amazon.com";function c(M){var u;const L=M.getOptionalString("accessKeyId"),U=(u=M.getOptionalString("secretAccessKey"))===null||u===void 0?void 0:u.trim(),ot=M.getOptionalString("roleArn"),nt=M.getOptionalString("externalId");return{host:f,accessKeyId:L,secretAccessKey:U,roleArn:ot,externalId:nt}}function C(M){const u=M.map(c);return u.some(L=>L.host===f)||u.push({host:f}),u}class A{get type(){return"awsCodeCommit"}get config(){return this.integrationConfig}get title(){return this.integrationConfig.host}resolveUrl(u){return(0,i.ku)(u)}resolveEditUrl(u){const U=new URL(u).pathname.match(/^\/codesuite\/codecommit\/repositories\/([^\/]+)\//);if(!U)throw new Error("");const[,ot]=U;return w(u,ot,"edit")}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(A,"factory",({config:M})=>{var u;const L=C((u=M.getOptionalConfigArray("integrations.awsCodeCommit"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new A(U)),U=>U.config.host)});function w(M,u,L){const U=L==="edit"?"files/edit":L;return M.replace(new RegExp(`/codesuite/codecommit/repositories/${u}/(browse|files/edit)/`),`/codesuite/codecommit/repositories/${u}/${U}/`)}var h=t(96324),S=t(87081),g=t(33284);const D="GB";var P=new WeakMap,y=new WeakMap,j=new WeakMap,R=new WeakMap,x=new WeakMap,z=new WeakMap,_=new WeakMap;class tt{static fromRepoUrl(u){const L=new URL(u);let U,ot,nt;const ut=L.pathname.split("/").map(Gt=>decodeURIComponent(Gt));if(ut[2]==="_git"?(U=ut[1],ot=nt=ut[3]):ut[3]==="_git"?(U=ut[1],ot=ut[2],nt=ut[4]):ut[4]==="_git"&&(U=`${ut[1]}/${ut[2]}`,ot=ut[3],nt=ut[5]),!U||!ot||!nt)throw new Error("Azure URL must point to a git repository");var jt;const $t=(jt=L.searchParams.get("path"))!==null&&jt!==void 0?jt:void 0;let ue;const ae=L.searchParams.get("version");if(ae){if(ae.slice(0,2)!=="GB")throw new Error("Azure URL version must point to a git branch");ue=ae.slice(2)}return new tt(L.origin,U,ot,nt,$t,ue)}toRepoUrl(){let u;return(0,h._)(this,j)===(0,h._)(this,R)?u=(0,h._)(this,_).call(this,(0,h._)(this,y),"_git",(0,h._)(this,R)):u=(0,h._)(this,_).call(this,(0,h._)(this,y),(0,h._)(this,j),"_git",(0,h._)(this,R)),(0,h._)(this,x)&&u.searchParams.set("path",(0,h._)(this,x)),(0,h._)(this,z)&&u.searchParams.set("version",D+(0,h._)(this,z)),u.toString()}toFileUrl(){if(!(0,h._)(this,x))throw new Error("Azure URL must point to a specific path to be able to download a file");const u=(0,h._)(this,_).call(this,(0,h._)(this,y),(0,h._)(this,j),"_apis","git","repositories",(0,h._)(this,R),"items");return u.searchParams.set("api-version","6.0"),u.searchParams.set("path",(0,h._)(this,x)),(0,h._)(this,z)&&u.searchParams.set("version",(0,h._)(this,z)),u.toString()}toArchiveUrl(){const u=(0,h._)(this,_).call(this,(0,h._)(this,y),(0,h._)(this,j),"_apis","git","repositories",(0,h._)(this,R),"items");return u.searchParams.set("recursionLevel","full"),u.searchParams.set("download","true"),u.searchParams.set("api-version","6.0"),(0,h._)(this,x)&&u.searchParams.set("scopePath",(0,h._)(this,x)),(0,h._)(this,z)&&u.searchParams.set("version",(0,h._)(this,z)),u.toString()}toCommitsUrl(){const u=(0,h._)(this,_).call(this,(0,h._)(this,y),(0,h._)(this,j),"_apis","git","repositories",(0,h._)(this,R),"commits");return u.searchParams.set("api-version","6.0"),(0,h._)(this,z)&&u.searchParams.set("searchCriteria.itemVersion.version",(0,h._)(this,z)),u.toString()}getOwner(){return(0,h._)(this,y)}getProject(){return(0,h._)(this,j)}getRepo(){return(0,h._)(this,R)}getPath(){return(0,h._)(this,x)}getRef(){return(0,h._)(this,z)}constructor(u,L,U,ot,nt,ut){(0,S._)(this,P,{writable:!0,value:void 0}),(0,S._)(this,y,{writable:!0,value:void 0}),(0,S._)(this,j,{writable:!0,value:void 0}),(0,S._)(this,R,{writable:!0,value:void 0}),(0,S._)(this,x,{writable:!0,value:void 0}),(0,S._)(this,z,{writable:!0,value:void 0}),(0,S._)(this,_,{writable:!0,value:(...jt)=>{const $t=new URL((0,h._)(this,P));return $t.pathname=jt.map(ue=>encodeURIComponent(ue)).join("/"),$t}}),(0,g._)(this,P,u),(0,g._)(this,y,L),(0,g._)(this,j,U),(0,g._)(this,R,ot),(0,g._)(this,x,nt),(0,g._)(this,z,ut)}}const K="dev.azure.com",W=["clientId","clientSecret","tenantId","personalAccessToken"],G=new Map([["ClientSecret",["clientId","clientSecret","tenantId"]],["ManagedIdentity",["clientId"]],["PersonalAccessToken",["personalAccessToken"]]]);function H(M){for(const u of G.entries()){const[L,U]=u,ot=W.filter(nt=>!U.includes(nt));if(U.every(nt=>M[nt]!==void 0)&&ot.every(nt=>M[nt]===void 0))return{kind:L,organizations:M.organizations,...U.reduce((nt,ut)=>(nt[ut]=M[ut],nt),{})}}throw new Error("is not a valid credential")}function J(M){var u,L,U;const ot=(U=M.getOptionalString("host"))!==null&&U!==void 0?U:K;let nt=(u=M.getOptionalConfigArray("credentials"))===null||u===void 0?void 0:u.map(ee=>{var Yt,se;return{organizations:ee.getOptionalStringArray("organizations"),personalAccessToken:(Yt=ee.getOptionalString("personalAccessToken"))===null||Yt===void 0?void 0:Yt.trim(),tenantId:ee.getOptionalString("tenantId"),clientId:ee.getOptionalString("clientId"),clientSecret:(se=ee.getOptionalString("clientSecret"))===null||se===void 0?void 0:se.trim()}});const ut=(L=M.getOptionalString("token"))===null||L===void 0?void 0:L.trim();if(M.getOptional("credential")!==void 0&&M.getOptional("credentials")!==void 0)throw new Error("Invalid Azure integration config, 'credential' and 'credentials' cannot be used together. Use 'credentials' instead.");if(M.getOptional("token")!==void 0&&M.getOptional("credentials")!==void 0)throw new Error("Invalid Azure integration config, 'token' and 'credentials' cannot be used together. Use 'credentials' instead.");if(ut!==void 0){const ee=[{personalAccessToken:ut}];var jt;nt=(jt=nt==null?void 0:nt.concat(ee))!==null&&jt!==void 0?jt:ee}if(M.getOptional("credential")!==void 0){var $t,ue;const ee=[{organizations:M.getOptionalStringArray("credential.organizations"),token:($t=M.getOptionalString("credential.token"))===null||$t===void 0?void 0:$t.trim(),tenantId:M.getOptionalString("credential.tenantId"),clientId:M.getOptionalString("credential.clientId"),clientSecret:(ue=M.getOptionalString("credential.clientSecret"))===null||ue===void 0?void 0:ue.trim()}];var ae;nt=(ae=nt==null?void 0:nt.concat(ee))!==null&&ae!==void 0?ae:ee}if(!(0,i.HO)(ot))throw new Error(`Invalid Azure integration config, '${ot}' is not a valid host`);let Gt;if(nt!==void 0){const ee=nt==null?void 0:nt.reduce((Yt,se,ne)=>{let Me;try{H(se)}catch(be){Me=be.message}return Me!==void 0&&Yt.push(`credential at position ${ne+1} ${Me}`),Yt},Array.of()).concat(Object.entries(nt.filter(Yt=>Yt.organizations!==void 0&&Yt.organizations.length>0).reduce((Yt,se,ne)=>{var Me;return(Me=se.organizations)===null||Me===void 0||Me.forEach(be=>{Yt[be]||(Yt[be]=[]),Yt[be].push(ne+1)}),Yt},{})).filter(([Yt,se])=>se.length>1).reduce((Yt,[se,ne])=>(Yt.push(`organization ${se} is specified multiple times in credentials at positions ${ne.slice(0,ne.length-1).join(", ")} and ${ne[ne.length-1]}`),Yt),Array.of()));if((ee==null?void 0:ee.length)>0)throw new Error(`Invalid Azure integration config for ${ot}: ${ee.join("; ")}`);if(Gt=nt.map(Yt=>H(Yt)),Gt.some(Yt=>Yt.kind!=="PersonalAccessToken")&&ot!==K)throw new Error(`Invalid Azure integration config for ${ot}, only personal access tokens can be used with hosts other than ${K}`);if(Gt.filter(Yt=>Yt.organizations===void 0||Yt.organizations.length===0).length>1)throw new Error(`Invalid Azure integration config for ${ot}, you cannot specify multiple credentials without organizations`)}return{host:ot,credentials:Gt}}function q(M){const u=M.map(J);return u.some(L=>L.host===K)||u.push({host:K}),u}class yt{get type(){return"azure"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){const{url:L,base:U}=u;if((0,i.AY)(L))return L;try{const nt=tt.fromRepoUrl(U),ut=new URL(U);var ot;const jt=new URL(`https://a.com${(ot=nt.getPath())!==null&&ot!==void 0?ot:""}`),$t=new URL(L,jt).pathname;return ut.searchParams.set("path",$t),u.lineNumber&&(ut.searchParams.set("line",String(u.lineNumber)),ut.searchParams.set("lineEnd",String(u.lineNumber+1)),ut.searchParams.set("lineStartColumn","1"),ut.searchParams.set("lineEndColumn","1")),ut.toString()}catch{return new URL(L,U).toString()}}resolveEditUrl(u){return u}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(yt,"factory",({config:M})=>{var u;const L=q((u=M.getOptionalConfigArray("integrations.azure"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new yt(U)),U=>U.config.host)});var at=t(52536),Ot=t.n(at);const ht="bitbucket.org",vt="https://api.bitbucket.org/2.0";function dt(M){var u;const L=ht,U=vt,ot=M.getString("username"),nt=(u=M.getString("appPassword"))===null||u===void 0?void 0:u.trim();return{host:L,apiBaseUrl:U,username:ot,appPassword:nt}}function st(M){const u=M.map(dt);return u.length===0&&u.push({host:ht,apiBaseUrl:vt}),u}class mt{get type(){return"bitbucketCloud"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){const L=(0,i.ku)(u);if(u.lineNumber){const U=new URL(L);return U.hash=`lines-${u.lineNumber}`,U.toString()}return L}resolveEditUrl(u){const L=Ot()(u),U=new URL(u);return U.searchParams.set("mode","edit"),U.searchParams.set("at",L.ref),U.toString()}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(mt,"factory",({config:M})=>{var u;const L=st((u=M.getOptionalConfigArray("integrations.bitbucketCloud"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new mt(U)),U=>U.config.host)});var Et=t(45250);const Tt="bitbucket.org",gt="https://api.bitbucket.org/2.0";function it(M){var u,L,U;const ot=(U=M.getOptionalString("host"))!==null&&U!==void 0?U:Tt;let nt=M.getOptionalString("apiBaseUrl");const ut=(u=M.getOptionalString("token"))===null||u===void 0?void 0:u.trim(),jt=M.getOptionalString("username"),$t=(L=M.getOptionalString("appPassword"))===null||L===void 0?void 0:L.trim();if(!(0,i.HO)(ot))throw new Error(`Invalid Bitbucket integration config, '${ot}' is not a valid host`);return nt?nt=(0,Et.trimEnd)(nt,"/"):ot===Tt?nt=gt:nt=`https://${ot}/rest/api/1.0`,{host:ot,apiBaseUrl:nt,token:ut,username:jt,appPassword:$t}}function ft(M){const u=M.map(it);return u.some(L=>L.host===Tt)||u.push({host:Tt,apiBaseUrl:gt}),u}class pt{get type(){return"bitbucket"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){const L=(0,i.ku)(u);if(!u.lineNumber)return L;const U=new URL(L);return this.integrationConfig.host==="bitbucket.org"?U.hash=`lines-${u.lineNumber}`:U.hash=`${u.lineNumber}`,U.toString()}resolveEditUrl(u){const L=Ot()(u),U=new URL(u);return U.searchParams.set("mode","edit"),U.searchParams.set("spa","0"),U.searchParams.set("at",L.ref),U.toString()}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(pt,"factory",({config:M})=>{var u,L,U;const ot=ft((U=M.getOptionalConfigArray("integrations.bitbucket"))!==null&&U!==void 0?U:[...(u=M.getOptionalConfigArray("integrations.bitbucketCloud"))!==null&&u!==void 0?u:[],...(L=M.getOptionalConfigArray("integrations.bitbucketServer"))!==null&&L!==void 0?L:[]]);return(0,i.oS)(ot.map(nt=>new pt(nt)),nt=>nt.config.host)});function Rt(M){var u;const L=M.getString("host");let U=M.getOptionalString("apiBaseUrl");const ot=(u=M.getOptionalString("token"))===null||u===void 0?void 0:u.trim(),nt=M.getOptionalString("username"),ut=M.getOptionalString("password");if(!(0,i.HO)(L))throw new Error(`Invalid Bitbucket Server integration config, '${L}' is not a valid host`);return U?U=(0,Et.trimEnd)(U,"/"):U=`https://${L}/rest/api/1.0`,{host:L,apiBaseUrl:U,token:ot,username:nt,password:ut}}function Ct(M){return M.map(Rt)}class N{get type(){return"bitbucketServer"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){const L=(0,i.ku)(u);if(u.lineNumber){const U=new URL(L);return U.hash=u.lineNumber.toString(),U.toString()}return L}resolveEditUrl(u){return u.includes("?")?u.substring(0,u.indexOf("?")):u}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(N,"factory",({config:M})=>{var u;const L=Ct((u=M.getOptionalConfigArray("integrations.bitbucketServer"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new N(U)),U=>U.config.host)});function V(M){var u;const L=M.getString("host");let U=M.getOptionalString("baseUrl"),ot=M.getOptionalString("cloneUrl"),nt=M.getOptionalString("gitilesBaseUrl");const ut=M.getOptionalString("username"),jt=(u=M.getOptionalString("password"))===null||u===void 0?void 0:u.trim();if((0,i.HO)(L)){if(U&&!(0,i.AY)(U))throw new Error(`Invalid Gerrit integration config, '${U}' is not a valid baseUrl`);if(ot&&!(0,i.AY)(ot))throw new Error(`Invalid Gerrit integration config, '${ot}' is not a valid cloneUrl`);if(nt&&!(0,i.AY)(nt))throw new Error(`Invalid Gerrit integration config, '${nt}' is not a valid gitilesBaseUrl`)}else throw new Error(`Invalid Gerrit integration config, '${L}' is not a valid host`);return U?U=(0,Et.trimEnd)(U,"/"):U=`https://${L}`,nt?nt=(0,Et.trimEnd)(nt,"/"):nt=`https://${L}`,ot?ot=(0,Et.trimEnd)(ot,"/"):ot=U,{host:L,baseUrl:U,cloneUrl:ot,gitilesBaseUrl:nt,username:ut,password:jt}}function xt(M){return M.map(V)}var wt=t(1048).hp;const Ft=")]}'";function It(M,u){const L=new URL(M.gitilesBaseUrl),U=new URL(u),nt=U.pathname.substring(U.pathname.startsWith("/a/")?2:0).replace(L.pathname,"").split("/").filter(Gt=>!!Gt),ut=nt.indexOf("+");if(ut<=0)throw new Error(`Unable to parse project from url: ${u}`);const jt=(0,Et.trimStart)(nt.slice(0,ut).join("/"),"/"),$t=nt.indexOf("heads");if($t<=0)throw new Error(`Unable to parse branch from url: ${u}`);const ue=nt[$t+1],ae=nt.slice($t+2).join("/");return{branch:ue,filePath:ae===""?"/":ae,project:jt}}function Mt(M,u,L,U){return`${M.gitilesBaseUrl}/${u}/+/refs/heads/${L}/${(0,Et.trimStart)(U,"/")}`}function Wt(M,u,L,U){const ot=U==="/"||U===""?".tar.gz":`/${U}.tar.gz`;return`${Nt(M)}/${u}/+archive/refs/heads/${L}${ot}`}function St(M){return M.password?"/a/":"/"}function Nt(M){if(!M.baseUrl||!M.gitilesBaseUrl)throw new Error("Unexpected Gerrit config values. baseUrl or gitilesBaseUrl not set.");if(M.gitilesBaseUrl.startsWith(M.baseUrl))return M.gitilesBaseUrl.replace(M.baseUrl.concat("/"),M.baseUrl.concat(St(M)));if(M.password)throw new Error("Since the baseUrl (Gerrit) is not part of the gitilesBaseUrl, an authentication URL could not be constructed.");return M.gitilesBaseUrl}function Xt(M,u){const{branch:L,project:U}=It(M,u);return`${M.baseUrl}${St(M)}projects/${encodeURIComponent(U)}/branches/${L}`}function pe(M,u){const{project:L}=It(M,u);return`${M.cloneUrl}${St(M)}${L}`}function ce(M,u){const{branch:L,filePath:U,project:ot}=It(M,u);return`${M.baseUrl}${St(M)}projects/${encodeURIComponent(ot)}/branches/${L}/files/${encodeURIComponent(U)}/content`}function de(M){return`${M.baseUrl}${St(M)}projects/`}function zt(M){const u={};if(!M.password)return u;const L=wt.from(`${M.username}:${M.password}`,"utf8");return u.Authorization=`Basic ${L.toString("base64")}`,{headers:u}}async function qt(M){const u=await M.text();if(u.startsWith(Ft))try{return JSON.parse(u.slice(Ft.length))}catch(L){throw new Error(`Invalid response from Gerrit: ${u.slice(0,10)} - ${L}`)}throw new Error(`Gerrit JSON body prefix missing. Found: ${u.slice(0,10)}`)}class ye{get type(){return"gerrit"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){const{url:L,base:U,lineNumber:ot}=u;let nt;if(L.startsWith("/")){const{branch:ut,project:jt}=It(this.config,U);return Mt(this.config,jt,ut,L)}return L?nt=new URL(L,U):nt=new URL(U),ot&&(nt.hash=ot.toString()),nt.toString()}resolveEditUrl(u){return u}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(ye,"factory",({config:M})=>{var u;const L=xt((u=M.getOptionalConfigArray("integrations.gerrit"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new ye(U)),U=>U.config.host)});var ke=t(36021);const Ue="gitlab.com",Ge="https://gitlab.com/api/v4";function Te(M){var u;const L=M.getString("host");let U=M.getOptionalString("apiBaseUrl");const ot=(u=M.getOptionalString("token"))===null||u===void 0?void 0:u.trim();let nt=M.getOptionalString("baseUrl");if(U?U=(0,Et.trimEnd)(U,"/"):L===Ue&&(U=Ge),nt?nt=(0,Et.trimEnd)(nt,"/"):nt=`https://${L}`,(0,i.HO)(L)){if(!U||!(0,i.AY)(U))throw new Error(`Invalid GitLab integration config, '${U}' is not a valid apiBaseUrl`);if(!(0,i.AY)(nt))throw new Error(`Invalid GitLab integration config, '${nt}' is not a valid baseUrl`)}else throw new Error(`Invalid GitLab integration config, '${L}' is not a valid host`);return{host:L,token:ot,apiBaseUrl:U,baseUrl:nt}}function an(M){const u=M.map(Te);return u.some(L=>L.host===Ue)||u.push({host:Ue,apiBaseUrl:Ge,baseUrl:`https://${Ue}`}),u}function qe(M){let u="";return M.host!==Ue&&(u=new URL(M.baseUrl).pathname),trimEnd(u,"/")}class re{get type(){return"gitlab"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(u){return(0,i.ku)(u)}resolveEditUrl(u){return Ke(u,"edit")}constructor(u){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=u}}(0,o._)(re,"factory",({config:M})=>{var u;const L=an((u=M.getOptionalConfigArray("integrations.gitlab"))!==null&&u!==void 0?u:[]);return(0,i.oS)(L.map(U=>new re(U)),U=>U.config.host)});function Ke(M,u){return M.replace(/\/\-\/(blob|tree|edit)\//,`/-/${u}/`)}function ze(M){var u;const L=M.getString("host");let U=M.getOptionalString("baseUrl");const ot=M.getOptionalString("username"),nt=(u=M.getOptionalString("password"))===null||u===void 0?void 0:u.trim();if((0,i.HO)(L)){if(U&&!(0,i.AY)(U))throw new Error(`Invalid Gitea integration config, '${U}' is not a valid baseUrl`)}else throw new Error(`Invalid Gitea integration config, '${L}' is not a valid host`);return U?U=(0,Et.trimEnd)(U,"/"):U=`https://${L}`,{host:L,baseUrl:U,username:ot,password:nt}}var tn=t(1048).hp;function Ye(M,u){const L=ge(M,u);return`${L.url}/${L.owner}/${L.name}/_edit/${L.ref}/${L.path}`}function Ce(M,u){const L=ge(M,u);return`${L.url}/api/v1/repos/${L.owner}/${L.name}/contents/${L.path}?ref=${L.ref}`}function ln(M,u){const L=ge(M,u);return`${L.url}/api/v1/repos/${L.owner}/${L.name}/archive/${L.ref}.tar.gz`}function cn(M,u){const L=ge(M,u);return`${L.url}/api/v1/repos/${L.owner}/${L.name}/git/commits/${L.ref}`}function dn(M){const u={},{username:L,password:U}=M;return U?(L?u.Authorization=`basic ${tn.from(`${L}:${U}`).toString("base64")}`:u.Authorization=`token ${U}`,{headers:u}):u}function ge(M,u){var L;const U=(L=M.baseUrl)!==null&&L!==void 0?L:`https://${M.host}`;try{const[ot,nt,ut,jt,$t,ue,...ae]=u.replace(U,"").split("/"),Gt=ae.join("/").replace(/^\//,"");return{url:U,owner:nt,name:ut,ref:ue,path:Gt}}catch(ot){throw new Error(`Incorrect URL: ${u}, ${ot}`)}}class De{get type(){return"gitea"}get title(){return this.config.host}resolveUrl(u){return(0,i.ku)(u)}resolveEditUrl(u){return Ye(this.config,u)}constructor(u){(0,o._)(this,"config",void 0),this.config=u}}(0,o._)(De,"factory",({config:M})=>{var u;const U=((u=M.getOptionalConfigArray("integrations.gitea"))!==null&&u!==void 0?u:[]).map(ot=>ze(ot));return(0,i.oS)(U.map(ot=>new De(ot)),ot=>ot.config.host)});function Qe(M){const u=M.getString("host"),L=M.getOptionalString("token"),U=M.getOptionalString("apiKey");if(!(0,i.HO)(u))throw new Error(`Invalid Harness Code integration config, '${u}' is not a valid host`);return{host:u,apiKey:U,token:L}}function Ze(M,u){try{const L=`https://${M.host}`,[U,ot,nt,ut,jt,$t,ue,ae,Gt,ee,Yt,se,ne,Me,be,...hn]=u.replace(L,"").split("/"),fn=hn.join("/").replace(/^\//,"");return`${L}/gateway/code/api/v1/repos/${ut}/${ae}/${ee}/${se}/+/edit/${fn}`}catch(L){throw new Error(`Incorrect URL: ${u}, ${L}`)}}function $e(M,u){try{const L=`https://${M.host}`,[U,ot,nt,ut,jt,$t,ue,ae,Gt,ee,Yt,se,ne,Me,be,...hn]=u.replace(L,"").split("/"),mn=u.replace(L,"").split("/").slice(13),Qt=mn.findIndex(yn=>yn==="~"),Ve=mn.slice(0,Qt),nn=hn.join("/").replace(/^\//,"");return`${L}/gateway/code/api/v1/repos/${ut}/${ae}/${ee}/${se}/+/raw/${nn}?routingId=${ut}&git_ref=${Ve}`}catch(L){throw new Error(`Incorrect URL: ${u}, ${L}`)}}function He(M){const u={},{token:L,apiKey:U}=M;return U?u["x-api-key"]=U:L&&(u.Authorization=`Bearer ${L}`),{headers:u}}class _e{get type(){return"harness"}get title(){return this.config.host}resolveUrl(u){return(0,i.ku)(u)}resolveEditUrl(u){return Ze(this.config,u)}constructor(u){(0,o._)(this,"config",void 0),this.config=u}}(0,o._)(_e,"factory",({config:M})=>{var u;const U=((u=M.getOptionalConfigArray("integrations.harness"))!==null&&u!==void 0?u:[]).map(ot=>Qe(ot));return(0,i.oS)(U.map(ot=>new _e(ot)),ot=>ot.config.host)});class en{static fromConfig(u){return new en({awsS3:v.factory({config:u}),awsCodeCommit:A.factory({config:u}),azure:yt.factory({config:u}),bitbucket:pt.factory({config:u}),bitbucketCloud:mt.factory({config:u}),bitbucketServer:N.factory({config:u}),gerrit:ye.factory({config:u}),github:ke.U.factory({config:u}),gitlab:re.factory({config:u}),gitea:De.factory({config:u}),harness:_e.factory({config:u})})}get awsS3(){return this.byType.awsS3}get awsCodeCommit(){return this.byType.awsCodeCommit}get azure(){return this.byType.azure}get bitbucket(){return this.byType.bitbucket}get bitbucketCloud(){return this.byType.bitbucketCloud}get bitbucketServer(){return this.byType.bitbucketServer}get gerrit(){return this.byType.gerrit}get github(){return this.byType.github}get gitlab(){return this.byType.gitlab}get gitea(){return this.byType.gitea}get harness(){return this.byType.harness}list(){return Object.values(this.byType).flatMap(u=>u.list())}byUrl(u){let L=Object.values(this.byType).map(U=>U.byUrl(u)).filter(Boolean);if(L.length>1){const U=L.filter(ot=>!(ot instanceof pt));U.length!==0&&(L=U)}return L[0]}byHost(u){return Object.values(this.byType).map(L=>L.byHost(u)).find(Boolean)}resolveUrl(u){const L=this.byUrl(u.base);return L?L.resolveUrl(u):(0,i.ku)(u)}resolveEditUrl(u){const L=this.byUrl(u);return L?L.resolveEditUrl(u):u}constructor(u){(0,o._)(this,"byType",void 0),this.byType=u}}var Rn=t(55309);class un{static fromConfig(u){return en.fromConfig(u)}}const In=(0,Rn.y)({id:"integration.scmintegrations"})},36021:function(Y,T,t){"use strict";t.d(T,{U:function(){return C},F:function(){return A}});var o=t(18990),i=t(59869),d=t(45250);const O="github.com",m="https://api.github.com",v="https://raw.githubusercontent.com";function f(w){var h,S,g;const D=(g=w.getOptionalString("host"))!==null&&g!==void 0?g:O;let P=w.getOptionalString("apiBaseUrl"),y=w.getOptionalString("rawBaseUrl");const j=(h=w.getOptionalString("token"))===null||h===void 0?void 0:h.trim(),R=(S=w.getOptionalConfigArray("apps"))===null||S===void 0?void 0:S.map(x=>({appId:x.getNumber("appId"),clientId:x.getString("clientId"),clientSecret:x.getString("clientSecret"),webhookSecret:x.getString("webhookSecret"),privateKey:x.getString("privateKey"),allowedInstallationOwners:x.getOptionalStringArray("allowedInstallationOwners")}));if(!(0,i.HO)(D))throw new Error(`Invalid GitHub integration config, '${D}' is not a valid host`);return P?P=(0,d.trimEnd)(P,"/"):D===O&&(P=m),y?y=(0,d.trimEnd)(y,"/"):D===O&&(y=v),{host:D,apiBaseUrl:P,rawBaseUrl:y,token:j,apps:R}}function c(w){const h=w.map(f);return h.some(S=>S.host===O)||h.push({host:O,apiBaseUrl:m,rawBaseUrl:v}),h}class C{get type(){return"github"}get title(){return this.integrationConfig.host}get config(){return this.integrationConfig}resolveUrl(h){return A((0,i.ku)(h),"tree")}resolveEditUrl(h){return A(h,"edit")}parseRateLimitInfo(h){return{isRateLimited:h.status===429||h.status===403&&h.headers.get("x-ratelimit-remaining")==="0"}}constructor(h){(0,o._)(this,"integrationConfig",void 0),this.integrationConfig=h}}(0,o._)(C,"factory",({config:w})=>{var h;const S=c((h=w.getOptionalConfigArray("integrations.github"))!==null&&h!==void 0?h:[]);return(0,i.oS)(S.map(g=>new C(g)),g=>g.config.host)});function A(w,h){return w.replace(/\/\/([^/]+)\/([^/]+)\/([^/]+)\/(blob|tree|edit)\//,(S,g,D,P)=>`//${g}/${D}/${P}/${h}/`)}},59869:function(Y,T,t){"use strict";t.d(T,{AY:function(){return v},HO:function(){return m},ku:function(){return c},oS:function(){return f}});var o=t(52536),i=t.n(o),d=t(45250),O=t.n(d);function m(A){const w=new URL("http://example.com");return w.host=A,w.host===A}function v(A){try{return new URL(A),!0}catch{return!1}}function f(A,w){return{list(){return A},byUrl(h){try{const S=typeof h=="string"?new URL(h):h;return A.find(g=>w(g)===S.host)}catch{return}},byHost(h){return A.find(S=>w(S)===h)}}}function c(A){const{url:w,base:h,lineNumber:S}=A;try{return new URL(w),w}catch{}let g;if(w.startsWith("/")){const{href:D,filepath:P}=i()(h);g=new URL(D);const y=(0,d.trimEnd)(g.pathname.substring(0,g.pathname.length-P.length),"/");g.pathname=`${y}${w}`}else g=new URL(w,h);return g.search=new URL(h).search,S&&(g.hash=`L${S}`),g.toString()}function C(A){beforeAll(()=>A.listen({onUnhandledRequest:"error"})),afterAll(()=>A.close()),afterEach(()=>A.resetHandlers())}},85318:function(Y,T,t){"use strict";var o={};t.r(o),t.d(o,{TechDocsPlugin:function(){return v.Ju}});var i=t(31085),d=t(14041),O=t(25873),m=t(18690),v=t(39278),f=t(85920),c=t(72020),C=t(99730),A=t(64947),w=t(12173),h=t(22020),S=t(68146),g=t(73970);function D({children:r}){return(0,m.Ri)()?(0,i.jsx)(i.Fragment,{children:r}):(0,i.jsx)(m.fS,{children:r})}const P=()=>(0,i.jsx)(w.M,{status:"404",statusMessage:"PAGE NOT FOUND"}),y=({step:r,error:e})=>{let n="";return r==="load-config"?n=`The configuration failed to load, someone should have a look at this error: ${e.message}`:r==="load-chunk"&&(n=`Lazy loaded chunk failed to load, try to reload the page: ${e.message}`),(0,i.jsx)(D,{children:(0,i.jsx)(w.M,{statusMessage:n,stack:e.stack})})},j=({error:r,resetError:e,plugin:n})=>(0,i.jsx)(h.b,{title:`Error in ${n==null?void 0:n.getId()}`,defaultExpanded:!0,error:r,children:(0,i.jsx)(A.A,{variant:"outlined",onClick:e,children:"Retry"})}),R={Progress:S.k,Router:g.Kd,NotFoundErrorPage:P,BootErrorPage:y,ErrorBoundaryFallback:j};var x=t(18990);const z="Invalid discovery URL pattern,";class _{static compile(e){const n=e.split(/\{\{\s*pluginId\s*\}\}/),s=n.join("pluginId");let a;try{a=new URL(s)}catch{throw new Error(`${z} URL '${s}' is invalid`)}if(a.hash)throw new Error(`${z} URL must not have a hash`);if(a.search)throw new Error(`${z} URL must not have a query`);if(s.endsWith("/"))throw new Error(`${z} URL must not end with a slash`);return new _(n)}async getBaseUrl(e){return this.parts.join(encodeURIComponent(e))}constructor(e){(0,x._)(this,"parts",void 0),this.parts=e}}var tt=t(96403),K=t.n(tt);let W=Symbol.observable;class G{[W](){return this}get closed(){return this.isClosed}next(e){if(this.isClosed)throw new Error("PublishSubject is closed");this.subscribers.forEach(n=>n.next(e))}error(e){if(this.isClosed)throw new Error("PublishSubject is closed");this.isClosed=!0,this.terminatingError=e,this.subscribers.forEach(n=>n.error(e))}complete(){if(this.isClosed)throw new Error("PublishSubject is closed");this.isClosed=!0,this.subscribers.forEach(e=>e.complete())}subscribe(e,n,s){const a=typeof e=="function"?{next:e,error:n,complete:s}:e;return this.observable.subscribe(a)}constructor(){(0,x._)(this,"isClosed",!1),(0,x._)(this,"terminatingError",void 0),(0,x._)(this,"observable",new(K())(e=>this.isClosed?(this.terminatingError?e.error(this.terminatingError):e.complete(),()=>{}):(this.subscribers.add(e),()=>{this.subscribers.delete(e)}))),(0,x._)(this,"subscribers",new Set)}}let H=Symbol.observable;class J{[H](){return this}get closed(){return this.isClosed}next(e){if(this.isClosed)throw new Error("BehaviorSubject is closed");this.currentValue=e,this.subscribers.forEach(n=>n.next(e))}error(e){if(this.isClosed)throw new Error("BehaviorSubject is closed");this.isClosed=!0,this.terminatingError=e,this.subscribers.forEach(n=>n.error(e))}complete(){if(this.isClosed)throw new Error("BehaviorSubject is closed");this.isClosed=!0,this.subscribers.forEach(e=>e.complete())}subscribe(e,n,s){const a=typeof e=="function"?{next:e,error:n,complete:s}:e;return this.observable.subscribe(a)}constructor(e){(0,x._)(this,"isClosed",void 0),(0,x._)(this,"currentValue",void 0),(0,x._)(this,"terminatingError",void 0),(0,x._)(this,"observable",void 0),(0,x._)(this,"subscribers",new Set),this.isClosed=!1,this.currentValue=e,this.terminatingError=void 0,this.observable=new(K())(n=>this.isClosed?(this.terminatingError?n.error(this.terminatingError):n.complete(),()=>{}):(n.next(this.currentValue),this.subscribers.add(n),()=>{this.subscribers.delete(n)}))}}class q{post(e){this.subject.next(e)}alert$(){return this.subject}constructor(){(0,x._)(this,"subject",new G)}}class yt{captureEvent(e){}}class at{post(e,n){return n!=null&&n.hidden||this.alertApi.post({message:e.message,severity:"error"}),this.errorApi.post(e,n)}error$(){return this.errorApi.error$()}constructor(e,n){(0,x._)(this,"alertApi",void 0),(0,x._)(this,"errorApi",void 0),this.alertApi=e,this.errorApi=n}}class Ot{post(e,n){this.subject.next({error:e,context:n})}error$(){return this.subject}constructor(){(0,x._)(this,"subject",new G)}}class ht{static forward(e,n){window.addEventListener("unhandledrejection",s=>{e.post(s.reason,n)})}}const vt=new Map;class dt{static create(e){var n;return new dt((n=e.namespace)!==null&&n!==void 0?n:"",e.errorApi)}static addStorageEventListener(){window.addEventListener("storage",e=>{for(const[s,a]of vt.entries()){var n;!((n=e.key)===null||n===void 0)&&n.startsWith(s)&&a.handleStorageChange(e.key)}})}get(e){return this.snapshot(e).value}snapshot(e){let n,s="absent";try{const a=localStorage.getItem(this.getKeyName(e));a&&(n=JSON.parse(a,(l,b)=>(typeof b=="object"&&b!==null&&Object.freeze(b),b)),s="present")}catch{this.errorApi.post(new Error(`Error when parsing JSON config from storage for: ${e}`))}return{key:e,value:n,presence:s}}forBucket(e){const n=`${this.namespace}/${e}`;return vt.has(n)||vt.set(n,new dt(n,this.errorApi)),vt.get(n)}async set(e,n){localStorage.setItem(this.getKeyName(e),JSON.stringify(n)),this.notifyChanges(e)}async remove(e){localStorage.removeItem(this.getKeyName(e)),this.notifyChanges(e)}observe$(e){return dt.hasSubscribed||(dt.addStorageEventListener(),dt.hasSubscribed=!0),this.observable.filter(({key:n})=>n===e)}handleStorageChange(e){if(!(e!=null&&e.startsWith(this.namespace)))return;const n=e==null?void 0:e.slice(`${this.namespace}/`.length);n.includes("/")||this.notifyChanges(decodeURIComponent(n))}getKeyName(e){return`${this.namespace}/${encodeURIComponent(e)}`}notifyChanges(e){const n=this.snapshot(e);for(const s of this.subscribers)s.next(n)}constructor(e,n){(0,x._)(this,"namespace",void 0),(0,x._)(this,"errorApi",void 0),(0,x._)(this,"subscribers",void 0),(0,x._)(this,"observable",void 0),this.namespace=e,this.errorApi=n,this.subscribers=new Set,this.observable=new(K())(s=>(this.subscribers.add(s),()=>{this.subscribers.delete(s)}))}}(0,x._)(dt,"hasSubscribed",!1);function st(r){let e=r.baseImplementation||t.g.fetch;var n;const s=[(n=r.middleware)!==null&&n!==void 0?n:[]].flat().reverse();for(const a of s)e=a.apply(e);return{fetch:e}}class mt{static create(e){var n,s;const a=Et(e),l=((n=e.header)===null||n===void 0?void 0:n.name)||"authorization",b=((s=e.header)===null||s===void 0?void 0:s.value)||(E=>`Bearer ${E}`);return new mt(e.identityApi,a,l,b)}apply(e){return async(n,s)=>{const a=new Request(n,s),{token:l}=await this.identityApi.getCredentials();return a.headers.get(this.headerName)||typeof l!="string"||!l||!this.allowUrl(a.url)?e(n,s):(a.headers.set(this.headerName,this.headerValue(l)),e(a))}}constructor(e,n,s,a){(0,x._)(this,"identityApi",void 0),(0,x._)(this,"allowUrl",void 0),(0,x._)(this,"headerName",void 0),(0,x._)(this,"headerValue",void 0),this.identityApi=e,this.allowUrl=n,this.headerName=s,this.headerValue=a}}function Et(r){return r.allowUrl?r.allowUrl:r.urlPrefixAllowlist?Tt(r.urlPrefixAllowlist):r.config?Tt([r.config.getString("backend.baseUrl")]):()=>!1}function Tt(r){const e=r.map(n=>n.replace(/\/$/,""));return n=>e.some(s=>n===s||n.startsWith(`${s}/`))}function gt(r,e){return!e||e==="/"?r:`${r.replace(/\/$/,"")}/${e.replace(/^\//,"")}`}class it{apply(e){return async(n,s)=>{const a=new Request(n,s),l="plugin://";if(!a.url.startsWith(l))return e(n,s);const{hostname:b,pathname:E,search:B,hash:k,username:Z,password:rt}=new URL(`http://${a.url.substring(l.length)}`);let et=await this.discoveryApi.getBaseUrl(b);if(Z||rt){const At=new URL(et),Ut=`${Z}${rt?`:${rt}`:""}@`;et=`${At.protocol}//${Ut}${At.host}${At.pathname}`}const ct=`${gt(et,E)}${B}${k}`;return e(ct,typeof n=="string"||ft(n)?s:n)}}constructor(e){(0,x._)(this,"discoveryApi",void 0),this.discoveryApi=e}}function ft(r){return typeof r=="object"&&(r==null?void 0:r.constructor)===URL}class pt{static resolvePluginProtocol(e){return new it(e.discoveryApi)}static injectIdentityAuth(e){return mt.create(e)}constructor(){}}function Rt(r,e){for(const n of e)if(!r.has(n))return!1;return!0}function Ct(r,...e){const n=new Set(r);for(const s of e)for(const a of s)n.add(a);return n}class N{request(e){return new Promise((n,s)=>{this.requests.push({scopes:e,resolve:n,reject:s}),this.subject.next(this.getCurrentPending())})}resolve(e,n){this.requests=this.requests.filter(s=>Rt(e,s.scopes)?(s.resolve(n),!1):!0),this.subject.next(this.getCurrentPending())}reject(e){this.requests.forEach(n=>n.reject(e)),this.requests=[],this.subject.next(this.getCurrentPending())}pending(){return this.subject}getCurrentPending(){const e=this.requests.length===0?void 0:this.requests.slice(1).reduce((n,s)=>Ct(n,s.scopes),this.requests[0].scopes);return{scopes:e,resolve:n=>{e&&this.resolve(e,n)},reject:n=>{e&&this.reject(n)}}}constructor(){(0,x._)(this,"requests",[]),(0,x._)(this,"subject",new J(this.getCurrentPending()))}}class V{createAuthRequester(e){const n=new N,s=this.handlerCount;return this.handlerCount++,n.pending().subscribe({next:a=>{const l=this.currentRequests.slice(),b=this.makeAuthRequest(a,e);b?l[s]=b:delete l[s],this.currentRequests=l,this.subject.next(l.filter(Boolean))}}),a=>n.request(a)}makeAuthRequest(e,n){const{scopes:s}=e;if(s)return{provider:n.provider,trigger:async()=>{const a=await n.onAuthRequest(s);e.resolve(a)},reject:()=>{const a=new Error("Login failed, rejected by user");a.name="RejectedError",e.reject(a)}}}authRequest$(){return this.subject}constructor(){(0,x._)(this,"subject",new J([])),(0,x._)(this,"currentRequests",[]),(0,x._)(this,"handlerCount",0)}}function xt(r){return new Promise((e,n)=>{const s=r.width||500,a=r.height||700,l=window.screen.width/2-s/2,b=window.screen.height/2-a/2,E=window.open(r.url,r.name,`menubar=no,location=no,resizable=no,scrollbars=no,status=no,width=${s},height=${a},top=${b},left=${l}`);let B="";if(!E||typeof E.closed=="undefined"||E.closed){const et=new Error("Failed to open auth popup.");et.name="PopupRejectedError",n(et);return}const k=et=>{if(et.source!==E||et.origin!==r.origin)return;const{data:ct}=et;if(ct.type==="config_info"){B=ct.targetOrigin;return}if(ct.type!=="authorization_response")return;const At=ct;if("error"in At){const Ut=new Error(At.error.message);Ut.name=At.error.name,n(Ut)}else e(At.response);rt()},Z=setInterval(()=>{if(E.closed){const et=`Login failed, ${B&&B!==window.location.origin?`Incorrect app origin, expected ${B}`:"popup was closed"}`,ct=new Error(et);ct.name="PopupClosedError",n(ct),rt()}},100);function rt(){window.removeEventListener("message",k),clearInterval(Z)}window.addEventListener("message",k)})}let wt=!1;function Ft(r){return[...r].join(" ")}class It{async createSession(e){return e.instantPopup?this.enableExperimentalRedirectFlow?this.executeRedirect(e.scopes):this.showPopup(e.scopes):this.authRequester(e.scopes)}async refreshSession(e){const n=await fetch(await this.buildUrl("/refresh",{optional:!0,...e&&{scope:this.joinScopesFunc(e)}}),{headers:{"x-requested-with":"XMLHttpRequest"},credentials:"include"}).catch(a=>{throw new Error(`Auth refresh request failed, ${a}`)});if(!n.ok){const a=new Error(`Auth refresh request failed, ${n.statusText}`);throw a.status=n.status,a}const s=await n.json();if(s.error){const a=new Error(s.error.message);throw s.error.name&&(a.name=s.error.name),a}return await this.sessionTransform(s)}async removeSession(){const e=await fetch(await this.buildUrl("/logout"),{method:"POST",headers:{"x-requested-with":"XMLHttpRequest"},credentials:"include"}).catch(n=>{throw new Error(`Logout request failed, ${n}`)});if(!e.ok){const n=new Error(`Logout request failed, ${e.statusText}`);throw n.status=e.status,n}}async showPopup(e){var n,s,a,l,b,E,B,k;const Z=this.joinScopesFunc(e),rt=await this.buildUrl("/start",{scope:Z,origin:window.location.origin,flow:"popup"}),et=!((s=this.popupOptions)===null||s===void 0||(n=s.size)===null||n===void 0)&&n.fullscreen?window.screen.width:((l=this.popupOptions)===null||l===void 0||(a=l.size)===null||a===void 0?void 0:a.width)||450,ct=!((E=this.popupOptions)===null||E===void 0||(b=E.size)===null||b===void 0)&&b.fullscreen?window.screen.height:((k=this.popupOptions)===null||k===void 0||(B=k.size)===null||B===void 0?void 0:B.height)||730,At=await xt({url:rt,name:`${this.provider.title} Login`,origin:new URL(rt).origin,width:et,height:ct});return await this.sessionTransform(At)}async executeRedirect(e){const n=this.joinScopesFunc(e);return window.location.href=await this.buildUrl("/start",{scope:n,origin:window.location.origin,redirectUrl:window.location.href,flow:"redirect"}),new Promise(()=>{})}async buildUrl(e,n){const s=await this.discoveryApi.getBaseUrl("auth"),a=this.buildQueryString({...n,env:this.environment});return`${s}/${this.provider.id}${e}${a}`}buildQueryString(e){if(!e)return"";const n=Object.entries(e).map(([s,a])=>{if(typeof a=="string")return`${encodeURIComponent(s)}=${encodeURIComponent(a)}`;if(a)return encodeURIComponent(s)}).filter(Boolean).join("&");return n?`?${n}`:""}constructor(e){(0,x._)(this,"discoveryApi",void 0),(0,x._)(this,"environment",void 0),(0,x._)(this,"provider",void 0),(0,x._)(this,"joinScopesFunc",void 0),(0,x._)(this,"authRequester",void 0),(0,x._)(this,"sessionTransform",void 0),(0,x._)(this,"enableExperimentalRedirectFlow",void 0),(0,x._)(this,"popupOptions",void 0);const{configApi:n,discoveryApi:s,environment:a,provider:l,joinScopes:b=Ft,oauthRequestApi:E,sessionTransform:B=rt=>rt,popupOptions:k}=e;!wt&&!n&&(console.warn("DEPRECATION WARNING: Authentication providers require a configApi instance to configure the authentication flow. Please provide one to the authentication provider constructor."),wt=!0);var Z;this.enableExperimentalRedirectFlow=n&&(Z=n.getOptionalBoolean("enableExperimentalRedirectFlow"))!==null&&Z!==void 0?Z:!1,this.authRequester=E.createAuthRequester({provider:l,onAuthRequest:async rt=>this.enableExperimentalRedirectFlow?this.executeRedirect(rt):this.showPopup(rt)}),this.discoveryApi=s,this.environment=a,this.provider=l,this.joinScopesFunc=b,this.sessionTransform=B,this.popupOptions=k}}function Mt(r,e){for(const n of e)if(!r.has(n))return!1;return!0}class Wt{sessionExistsAndHasScope(e,n){if(!e)return!1;if(!n||this.options.sessionScopes===void 0)return!0;const s=this.options.sessionScopes(e);return Mt(s,n)}getExtendedScope(e,n){const s=new Set(this.options.defaultScopes);if(e&&this.options.sessionScopes!==void 0){const a=this.options.sessionScopes(e);for(const l of a)s.add(l)}if(n)for(const a of n)s.add(a);return s}constructor(e){(0,x._)(this,"options",void 0),this.options=e}}var St=t(55309),Nt;(function(r){r.SignedIn="SignedIn",r.SignedOut="SignedOut"})(Nt||(Nt={}));const Xt=(0,St.y)({id:"core.auth.google"}),pe=(0,St.y)({id:"core.auth.github"}),ce=(0,St.y)({id:"core.auth.okta"}),de=(0,St.y)({id:"core.auth.gitlab"}),zt=(0,St.y)({id:"core.auth.microsoft"}),qt=(0,St.y)({id:"core.auth.onelogin"}),ye=(0,St.y)({id:"core.auth.bitbucket"}),ke=(0,St.y)({id:"core.auth.bitbucket-server"}),Ue=(0,St.y)({id:"core.auth.atlassian"}),Ge=(0,St.y)({id:"core.auth.vmware-cloud"});class Te{setIsSignedIn(e){this.signedIn!==e&&(this.signedIn=e,this.subject.next(this.signedIn?Nt.SignedIn:Nt.SignedOut))}sessionState$(){return this.subject}constructor(){(0,x._)(this,"subject",new J(Nt.SignedOut)),(0,x._)(this,"signedIn",!1)}}class an{async getSession(e){if(this.helper.sessionExistsAndHasScope(this.currentSession,e.scopes)){if(!this.sessionShouldRefreshFunc(this.currentSession))return this.currentSession;try{const s=await this.collapsedSessionRefresh(e.scopes),a=this.sessionScopesFunc(this.currentSession),l=this.sessionScopesFunc(s);return Mt(l,a)&&(this.currentSession=s),s}catch(s){if(e.optional)return;throw s}}if(!this.currentSession&&!e.instantPopup)try{const n=await this.collapsedSessionRefresh(e.scopes);return this.currentSession=n,this.getSession(e)}catch{}if(!e.optional)return this.currentSession=await this.connector.createSession({...e,scopes:this.helper.getExtendedScope(this.currentSession,e.scopes)}),this.stateTracker.setIsSignedIn(!0),this.currentSession}async removeSession(){this.currentSession=void 0,await this.connector.removeSession(),this.stateTracker.setIsSignedIn(!1)}sessionState$(){return this.stateTracker.sessionState$()}async collapsedSessionRefresh(e){if(this.refreshPromise)return this.refreshPromise;this.refreshPromise=this.connector.refreshSession(this.helper.getExtendedScope(this.currentSession,e));try{const n=await this.refreshPromise;return this.stateTracker.setIsSignedIn(!0),n}finally{delete this.refreshPromise}}constructor(e){(0,x._)(this,"connector",void 0),(0,x._)(this,"helper",void 0),(0,x._)(this,"sessionScopesFunc",void 0),(0,x._)(this,"sessionShouldRefreshFunc",void 0),(0,x._)(this,"stateTracker",new Te),(0,x._)(this,"refreshPromise",void 0),(0,x._)(this,"currentSession",void 0);const{connector:n,defaultScopes:s=new Set,sessionScopes:a,sessionShouldRefresh:l}=e;this.connector=n,this.sessionScopesFunc=a,this.sessionShouldRefreshFunc=l,this.helper=new Wt({sessionScopes:a,defaultScopes:s})}}const qe={id:"oauth2",title:"Your Identity Provider",icon:()=>null};class re{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=qe,oauthRequestApi:b,defaultScopes:E=[],scopeTransform:B=et=>et,popupOptions:k}=e,Z=new It({configApi:n,discoveryApi:s,environment:a,provider:l,oauthRequestApi:b,sessionTransform({backstageIdentity:et,...ct}){const At={...ct,providerInfo:{idToken:ct.providerInfo.idToken,accessToken:ct.providerInfo.accessToken,scopes:re.normalizeScopes(B,ct.providerInfo.scope),expiresAt:ct.providerInfo.expiresInSeconds?new Date(Date.now()+ct.providerInfo.expiresInSeconds*1e3):void 0}};return et&&(At.backstageIdentity={token:et.token,identity:et.identity,expiresAt:et.expiresInSeconds?new Date(Date.now()+et.expiresInSeconds*1e3):void 0}),At},popupOptions:k}),rt=new an({connector:Z,defaultScopes:new Set(E),sessionScopes:et=>et.providerInfo.scopes,sessionShouldRefresh:et=>{var ct,At;let Ut=1/0;return!((ct=et.providerInfo)===null||ct===void 0)&&ct.expiresAt&&(Ut=Math.min(Ut,(et.providerInfo.expiresAt.getTime()-Date.now())/1e3)),!((At=et.backstageIdentity)===null||At===void 0)&&At.expiresAt&&(Ut=Math.min(Ut,(et.backstageIdentity.expiresAt.getTime()-Date.now())/1e3)),Ut<60*5}});return new re({sessionManager:rt,scopeTransform:B})}async signIn(){await this.getAccessToken()}async signOut(){await this.sessionManager.removeSession()}sessionState$(){return this.sessionManager.sessionState$()}async getAccessToken(e,n){const s=re.normalizeScopes(this.scopeTransform,e),a=await this.sessionManager.getSession({...n,scopes:s});var l;return(l=a==null?void 0:a.providerInfo.accessToken)!==null&&l!==void 0?l:""}async getIdToken(e={}){const n=await this.sessionManager.getSession({...e,scopes:new Set(["openid"])});var s;return(s=n==null?void 0:n.providerInfo.idToken)!==null&&s!==void 0?s:""}async getBackstageIdentity(e={}){const n=await this.sessionManager.getSession(e);return n==null?void 0:n.backstageIdentity}async getProfile(e={}){const n=await this.sessionManager.getSession(e);return n==null?void 0:n.profile}static normalizeScopes(e,n){if(!n)return new Set;const s=Array.isArray(n)?n:n.split(/[\s|,]/).filter(Boolean);return new Set(e(s))}constructor(e){(0,x._)(this,"sessionManager",void 0),(0,x._)(this,"scopeTransform",void 0),this.sessionManager=e.sessionManager,this.scopeTransform=e.scopeTransform}}const Ke={id:"google",title:"Google",icon:()=>null},ze="https://www.googleapis.com/auth/";class tn{static create(e){const{configApi:n,discoveryApi:s,oauthRequestApi:a,environment:l="development",provider:b=Ke,defaultScopes:E=["openid",`${ze}userinfo.email`,`${ze}userinfo.profile`]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:a,provider:b,environment:l,defaultScopes:E,scopeTransform(B){return B.map(k=>k==="openid"?k:k==="profile"||k==="email"?`${ze}userinfo.${k}`:k.startsWith(ze)?k:`${ze}${k}`)}})}}const Ye={id:"microsoft",title:"Microsoft",icon:()=>null};class Ce{static create(e){return new Ce(e)}microsoftGraph(){return this.oauth2[Ce.MicrosoftGraphID]}static resourceForScopes(e){const n=[...new Set(e.split(" ").map(Ce.resourceForScope).filter(l=>l!=="openid"))];if(n.length>1)return Promise.reject(new Error(`Requested access token with scopes from multiple Azure resources: ${n.join(", ")}. Access tokens can only have a single audience.`));var s;const a=(s=n[0])!==null&&s!==void 0?s:Ce.MicrosoftGraphID;return Promise.resolve(a)}static resourceForScope(e){var n;const s=(n=e.match(RegExp("^(?<resourceURI>.*)\\/(?<scp>[^\\/]*)$")))===null||n===void 0?void 0:n.groups;if(s){const{resourceURI:a}=s;return a.replace(/^api:\/\//,"")}switch(e){case"email":case"openid":case"offline_access":case"profile":return"openid";default:return Ce.MicrosoftGraphID}}async getAccessToken(e,n){const s=e===void 0?Ce.MicrosoftGraphID:await Ce.resourceForScopes(Array.isArray(e)?e.join(" "):e);return s in this.oauth2||(this.oauth2[s]=re.create({configApi:this.configApi,discoveryApi:this.discoveryApi,oauthRequestApi:this.oauthRequestApi,provider:this.provider,environment:this.environment,scopeTransform:this.scopeTransform})),this.oauth2[s].getAccessToken(e,n)}getIdToken(e){return this.microsoftGraph().getIdToken(e)}getProfile(e){return this.microsoftGraph().getProfile(e)}getBackstageIdentity(e){return this.microsoftGraph().getBackstageIdentity(e)}signIn(){return this.microsoftGraph().signIn()}signOut(){return this.microsoftGraph().signOut()}sessionState$(){return this.microsoftGraph().sessionState$()}constructor(e){(0,x._)(this,"oauth2",void 0),(0,x._)(this,"configApi",void 0),(0,x._)(this,"environment",void 0),(0,x._)(this,"provider",void 0),(0,x._)(this,"oauthRequestApi",void 0),(0,x._)(this,"discoveryApi",void 0),(0,x._)(this,"scopeTransform",void 0);const{configApi:n,environment:s="development",provider:a=Ye,oauthRequestApi:l,discoveryApi:b,defaultScopes:E=["openid","offline_access","profile","email","User.Read"],scopeTransform:B=k=>k.concat("offline_access")}=e;this.configApi=n,this.environment=s,this.provider=a,this.oauthRequestApi=l,this.discoveryApi=b,this.scopeTransform=B,this.oauth2={[Ce.MicrosoftGraphID]:re.create({configApi:this.configApi,discoveryApi:this.discoveryApi,oauthRequestApi:this.oauthRequestApi,provider:this.provider,environment:this.environment,scopeTransform:this.scopeTransform,defaultScopes:E})}}}(0,x._)(Ce,"MicrosoftGraphID","00000003-0000-0000-c000-000000000000");const ln={id:"github",title:"GitHub",icon:()=>null};class cn{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=ln,oauthRequestApi:b,defaultScopes:E=["read:user"]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a,defaultScopes:E})}}const dn={id:"okta",title:"Okta",icon:()=>null},ge=new Set(["openid","profile","email","phone","address","groups","offline_access"]),De="okta.";class Qe{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=dn,oauthRequestApi:b,defaultScopes:E=["openid","email","profile","offline_access"]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a,defaultScopes:E,scopeTransform(B){return B.map(k=>ge.has(k)||k.startsWith(De)?k:`${De}${k}`)}})}}const Ze={id:"gitlab",title:"GitLab",icon:()=>null};class $e{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=Ze,oauthRequestApi:b,defaultScopes:E=["read_user"]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a,defaultScopes:E})}}const He={id:"onelogin",title:"onelogin",icon:()=>null},_e=new Set(["openid","profile","email","phone","address","groups","offline_access"]),en="onelogin.";class Rn{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=He,oauthRequestApi:b}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a,defaultScopes:["openid","email","profile","offline_access"],scopeTransform(E){return E.map(B=>_e.has(B)||B.startsWith(en)?B:`${en}${B}`)}})}}const un={id:"bitbucket",title:"Bitbucket",icon:()=>null};class In{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=un,oauthRequestApi:b,defaultScopes:E=["account"]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a,defaultScopes:E})}}const M={id:"bitbucketServer",title:"Bitbucket Server",icon:()=>null};class u{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=M,oauthRequestApi:b,defaultScopes:E=["PROJECT_ADMIN"]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a,defaultScopes:E})}}const L={id:"atlassian",title:"Atlassian",icon:()=>null};class U{static create(e){const{configApi:n,discoveryApi:s,environment:a="development",provider:l=L,oauthRequestApi:b}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:b,provider:l,environment:a})}}const ot={id:"vmwareCloudServices",title:"VMware Cloud",icon:()=>null};class nt{static create(e){const{configApi:n,discoveryApi:s,oauthRequestApi:a,environment:l="development",provider:b=ot,defaultScopes:E=["openid"]}=e;return re.create({configApi:n,discoveryApi:s,oauthRequestApi:a,provider:b,environment:l,defaultScopes:E})}}var ut=t(12935),jt=t(57405),$t=t(65461),ue=t(36017),ae=t(99303),Gt=t(39837);const ee=(0,St.y)({id:"core.storage"});var Yt=t(70795),se=t(16009);const ne=(0,St.y)({id:"core.oauthrequest"});var Me=t(96824),be=t(70835),hn=t(10288),fn=t.n(hn),mn=t(52964),Qt=t(46195),Ve=t(54241);const nn=Qt.z.lazy(()=>Qt.z.object({rule:Qt.z.string(),resourceType:Qt.z.string(),params:Qt.z.record(Qt.z.any()).optional()}).or(Qt.z.object({anyOf:Qt.z.array(nn).nonempty()})).or(Qt.z.object({allOf:Qt.z.array(nn).nonempty()})).or(Qt.z.object({not:nn}))),yn=Qt.z.object({result:Qt.z.literal(Ve.b.ALLOW).or(Qt.z.literal(Ve.b.DENY))}),Io=Qt.z.union([Qt.z.object({result:Qt.z.literal(Ve.b.ALLOW).or(Qt.z.literal(Ve.b.DENY))}),Qt.z.object({result:Qt.z.literal(Ve.b.CONDITIONAL),pluginId:Qt.z.string(),resourceType:Qt.z.string(),conditions:nn})]),Do=(r,e)=>Qt.z.object({items:Qt.z.array(Qt.z.intersection(Qt.z.object({id:Qt.z.string()}),r)).refine(n=>n.length===e.size&&n.every(({id:s})=>e.has(s)),{message:"Items in response do not match request"})});class Mo{async authorize(e,n){return this.makeRequest(e,yn,n)}async authorizeConditional(e,n){return this.makeRequest(e,Io,n)}async makeRequest(e,n,s){if(!this.enabled)return e.map(Z=>({result:Ve.b.ALLOW}));const a={items:e.map(Z=>({id:mn.A(),...Z}))},l=await this.discovery.getBaseUrl("permission"),b=await fn()(`${l}/authorize`,{method:"POST",body:JSON.stringify(a),headers:{...this.getAuthorizationHeader(s==null?void 0:s.token),"content-type":"application/json"}});if(!b.ok)throw await be.o.fromResponse(b);const E=await b.json(),k=Do(n,new Set(a.items.map(({id:Z})=>Z))).parse(E).items.reduce((Z,rt)=>(Z[rt.id]=rt,Z),{});return a.items.map(Z=>k[Z.id])}getAuthorizationHeader(e){return e?{Authorization:`Bearer ${e}`}:{}}constructor(e){(0,x._)(this,"enabled",void 0),(0,x._)(this,"discovery",void 0),this.discovery=e.discovery;var n;this.enabled=(n=e.config.getOptionalBoolean("permission.enabled"))!==null&&n!==void 0?n:!1}}class Dn{static create(e){const{config:n,discovery:s,identity:a}=e,l=new Mo({discovery:s,config:n});return new Dn(l,a)}async authorize(e){return(await this.permissionClient.authorize([e],await this.identityApi.getCredentials()))[0]}constructor(e,n){(0,x._)(this,"permissionClient",void 0),(0,x._)(this,"identityApi",void 0),this.permissionClient=e,this.identityApi=n}}const Lo=[(0,ut.b)({api:jt.I,deps:{configApi:$t.U},factory:({configApi:r})=>_.compile(`${r.getString("backend.baseUrl")}/api/{{ pluginId }}`)}),(0,ut.b)({api:ue.k,deps:{},factory:()=>new q}),(0,ut.b)({api:ae.c,deps:{},factory:()=>new yt}),(0,ut.b)({api:Gt.m,deps:{alertApi:ue.k},factory:({alertApi:r})=>{const e=new at(r,new Ot);return ht.forward(e,{hidden:!1}),e}}),(0,ut.b)({api:ee,deps:{errorApi:Gt.m},factory:({errorApi:r})=>dt.create({errorApi:r})}),(0,ut.b)({api:Yt.a,deps:{configApi:$t.U,identityApi:se.K,discoveryApi:jt.I},factory:({configApi:r,identityApi:e,discoveryApi:n})=>st({middleware:[pt.resolvePluginProtocol({discoveryApi:n}),pt.injectIdentityAuth({identityApi:e,config:r})]})}),(0,ut.b)({api:ne,deps:{},factory:()=>new V}),(0,ut.b)({api:Xt,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>tn.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:zt,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>Ce.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:pe,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>cn.create({configApi:n,discoveryApi:r,oauthRequestApi:e,defaultScopes:["read:user"],environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:ce,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>Qe.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:de,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>$e.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:qt,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>Rn.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:ye,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>In.create({configApi:n,discoveryApi:r,oauthRequestApi:e,defaultScopes:["account"],environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:ke,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>u.create({configApi:n,discoveryApi:r,oauthRequestApi:e,defaultScopes:["REPO_READ"]})}),(0,ut.b)({api:Ue,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>U.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:Ge,deps:{discoveryApi:jt.I,oauthRequestApi:ne,configApi:$t.U},factory:({discoveryApi:r,oauthRequestApi:e,configApi:n})=>nt.create({configApi:n,discoveryApi:r,oauthRequestApi:e,environment:n.getOptionalString("auth.environment")})}),(0,ut.b)({api:Me.x,deps:{discovery:jt.I,identity:se.K,config:$t.U},factory:({config:r,discovery:e,identity:n})=>Dn.create({config:r,discovery:e,identity:n})})];var Mn=t(14451),Ln=t(27799),Jn=t(94389),Bo=t(20947),jo=t(20473),Uo=t(45917),$o=t(39347),Fo=t(63309),No=t(82451),Wo=t(85121),Xn=t(17400),ko=t(42226),Ko=t(69550),qn=t(52755),to=t(89350),zo=t(8911),Bn=t(33602),jn=t(48108),Ho=t(77225),eo=t(55700),no=t(71865);const oo={brokenImage:Ln.A,catalog:zo.A,scaffolder:Bo.A,techdocs:jo.A,search:Uo.A,chat:$o.A,dashboard:Fo.A,docs:No.A,email:Wo.A,github:ko.A,group:Bn.A,help:Ko.A,"kind:api":Xn.A,"kind:component":to.A,"kind:domain":Mn.A,"kind:group":Bn.A,"kind:location":qn.A,"kind:system":Jn.A,"kind:user":jn.A,"kind:resource":eo.A,"kind:template":no.A,user:jn.A,warning:Ho.A};var _o=t(58733),Vo=t(55288),Go=t(91360),Yo=t(50868),Un=t(12285),Qo=t(88714);const $n=(0,Vo.A)({productionPrefix:"jss4-"});function ro(r){const{children:e,theme:n,noCssBaseline:s=!1}=r,a=n.getTheme("v4"),l=n.getTheme("v5");let b;s||(b=(0,i.jsx)(_o.Ay,{}));let E=(0,i.jsxs)(i.Fragment,{children:[b,e]});return a&&(E=(0,i.jsx)(Go.Ay,{generateClassName:$n,children:(0,i.jsx)(Yo.A,{theme:a,children:E})})),l&&(E=(0,i.jsx)(Un.A,{injectFirst:!0,children:(0,i.jsx)(Qo.A,{theme:l,children:E})})),E}const so={light:{type:"light",mode:"light",background:{default:"#F8F8F8",paper:"#FFFFFF"},status:{ok:"#1DB954",warning:"#FF9800",error:"#E22134",running:"#1F5493",pending:"#FFED51",aborted:"#757575"},bursts:{fontColor:"#FEFEFE",slackChannelText:"#ddd",backgroundColor:{default:"#7C3699"},gradient:{linear:"linear-gradient(-137deg, #4BB8A5 0%, #187656 100%)"}},primary:{main:"#1F5493"},banner:{info:"#2E77D0",error:"#E22134",text:"#FFFFFF",link:"#000000",closeButtonColor:"#FFFFFF",warning:"#FF9800"},border:"#E6E6E6",textContrast:"#000000",textVerySubtle:"#DDD",textSubtle:"#6E6E6E",highlight:"#FFFBCC",errorBackground:"#FFEBEE",warningBackground:"#F59B23",infoBackground:"#ebf5ff",errorText:"#CA001B",infoText:"#004e8a",warningText:"#000000",linkHover:"#2196F3",link:"#0A6EBE",gold:"#FFD600",navigation:{background:"#171717",indicator:"#9BF0E1",color:"#b5b5b5",selectedColor:"#FFF",navItem:{hoverBackground:"#404040"},submenu:{background:"#404040"}},pinSidebarButton:{icon:"#181818",background:"#BDBDBD"},tabbar:{indicator:"#9BF0E1"}},dark:{type:"dark",mode:"dark",background:{default:"#333333",paper:"#424242"},status:{ok:"#71CF88",warning:"#FFB84D",error:"#F84C55",running:"#3488E3",pending:"#FEF071",aborted:"#9E9E9E"},bursts:{fontColor:"#FEFEFE",slackChannelText:"#ddd",backgroundColor:{default:"#7C3699"},gradient:{linear:"linear-gradient(-137deg, #4BB8A5 0%, #187656 100%)"}},primary:{main:"#9CC9FF",dark:"#82BAFD"},secondary:{main:"#FF88B2"},banner:{info:"#2E77D0",error:"#E22134",text:"#FFFFFF",link:"#000000",closeButtonColor:"#FFFFFF",warning:"#FF9800"},border:"#E6E6E6",textContrast:"#FFFFFF",textVerySubtle:"#727272",textSubtle:"#CCCCCC",highlight:"#FFFBCC",errorBackground:"#FFEBEE",warningBackground:"#F59B23",infoBackground:"#ebf5ff",errorText:"#CA001B",infoText:"#004e8a",warningText:"#000000",linkHover:"#82BAFD",link:"#9CC9FF",gold:"#FFD600",navigation:{background:"#424242",indicator:"#9BF0E1",color:"#b5b5b5",selectedColor:"#FFF",navItem:{hoverBackground:"#404040"},submenu:{background:"#404040"}},pinSidebarButton:{icon:"#404040",background:"#BDBDBD"},tabbar:{indicator:"#9BF0E1"}}};var Dt=t(96324),fe=t(87081),p=t(33284),I=t(98392),$=t(56558);const F={wave:`url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='1368' height='400' fill='none'%3e%3cmask id='a' width='1368' height='401' x='0' y='0' maskUnits='userSpaceOnUse'%3e%3cpath fill='url(%23paint0_linear)' d='M437 116C223 116 112 0 112 0h1256v400c-82 0-225-21-282-109-112-175-436-175-649-175z'/%3e%3cpath fill='url(%23paint1_linear)' d='M1368 400V282C891-29 788 40 711 161 608 324 121 372 0 361v39h1368z'/%3e%3cpath fill='url(%23paint2_linear)' d='M1368 244v156H0V94c92-24 198-46 375 0l135 41c176 51 195 109 858 109z'/%3e%3cpath fill='url(%23paint3_linear)' d='M1252 400h116c-14-7-35-14-116-16-663-14-837-128-1013-258l-85-61C98 28 46 8 0 0v400h1252z'/%3e%3c/mask%3e%3cg mask='url(%23a)'%3e%3cpath fill='white' d='M-172-98h1671v601H-172z'/%3e%3c/g%3e%3cdefs%3e%3clinearGradient id='paint0_linear' x1='602' x2='1093.5' y1='-960.5' y2='272' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint1_linear' x1='482' x2='480' y1='1058.5' y2='70.5' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint2_linear' x1='424' x2='446.1' y1='-587.5' y2='274.6' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint3_linear' x1='587' x2='349' y1='-1120.5' y2='341' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e")`,wave2:`url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='1368' height='400' fill='none'%3e%3cmask id='a' width='1764' height='479' x='-229' y='-6' maskUnits='userSpaceOnUse'%3e%3cpath fill='url(%23paint0_linear)' d='M0 400h1350C1321 336 525 33 179-2c-345-34-395 236-408 402H0z'/%3e%3cpath fill='url(%23paint1_linear)' d='M1378 177v223H0V217s219 75 327 52C436 246 717-35 965 45s254 144 413 132z'/%3e%3cpath fill='url(%23paint2_linear)' d='M26 400l-78-16c-170 205-44-6-137-30l-4-1 4 1 137 30c37-45 89-110 159-201 399-514-45 238 1176-50 275-65 354-39 91 267H26z'/%3e%3c/mask%3e%3cg mask='url(%23a)'%3e%3cpath fill='white' d='M0 0h1368v400H0z'/%3e%3c/g%3e%3cdefs%3e%3clinearGradient id='paint0_linear' x1='431' x2='397.3' y1='-599' y2='372.8' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint1_linear' x1='236.5' x2='446.6' y1='-586' y2='381.5' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint2_linear' x1='851.8' x2='640.4' y1='-867.2' y2='363.7' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e")`,round:`url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='1368' height='400' fill='none'%3e%3cmask id='a' width='2269' height='1408' x='-610' y='-509' maskUnits='userSpaceOnUse'%3e%3ccircle cx='1212.8' cy='74.8' r='317.5' fill='url(%23paint0_linear)' transform='rotate(-52 1213 75)'/%3e%3ccircle cx='737.8' cy='445.8' r='317.5' fill='url(%23paint1_linear)' transform='rotate(-116 738 446)'/%3e%3ccircle cx='601.8' cy='52.8' r='418.6' fill='url(%23paint2_linear)' transform='rotate(-117 602 53)'/%3e%3ccircle cx='999.8' cy='364' r='389.1' fill='url(%23paint3_linear)' transform='rotate(31 1000 364)'/%3e%3cellipse cx='-109.2' cy='263.5' fill='url(%23paint4_linear)' rx='429.2' ry='465.8' transform='rotate(-85 -109 264)'/%3e%3c/mask%3e%3cg mask='url(%23a)'%3e%3cpath fill='white' d='M0 0h1368v400H0z'/%3e%3c/g%3e%3cdefs%3e%3clinearGradient id='paint0_linear' x1='1301.2' x2='161.4' y1='-1879.7' y2='-969.6' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint1_linear' x1='826.2' x2='-313.6' y1='-1508.7' y2='-598.6' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint2_linear' x1='718.4' x2='-784.3' y1='-2524' y2='-1324.2' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint3_linear' x1='1108.2' x2='-288.6' y1='-2031.1' y2='-915.9' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3clinearGradient id='paint4_linear' x1='10.4' x2='-1626.5' y1='-2603.8' y2='-1399.5' gradientUnits='userSpaceOnUse'%3e%3cstop stop-color='white'/%3e%3cstop offset='1' stop-color='white' stop-opacity='0'/%3e%3c/linearGradient%3e%3c/defs%3e%3c/svg%3e")`},Q={darkGrey:["#171717","#383838"],marineBlue:["#006D8F","#0049A1"],veryBlue:["#0027AF","#270094"],rubyRed:["#98002B","#8D1134"],toastyOrange:["#BE2200","#A41D00"],purpleSky:["#8912CA","#3E00EA"],eveningSea:["#00FFF2","#035355"],teal:["#005B4B"],pinkSea:["#C8077A","#C2297D"],greens:["#4BB8A5","#187656"]};function X(r){const{colors:e,shape:n,options:s}=r,l=`linear-gradient(90deg, ${(e.length===1?[e[0],e[0]]:e).join(", ")})`,b=`${n}, ${l}`;var E;const B=(E=s==null?void 0:s.fontColor)!==null&&E!==void 0?E:"#FFFFFF";return{colors:e,shape:n,backgroundImage:b,fontColor:B}}const lt={home:X({colors:Q.teal,shape:F.wave}),documentation:X({colors:Q.pinkSea,shape:F.wave2}),tool:X({colors:Q.purpleSky,shape:F.round}),service:X({colors:Q.marineBlue,shape:F.wave}),website:X({colors:Q.veryBlue,shape:F.wave}),library:X({colors:Q.rubyRed,shape:F.wave}),other:X({colors:Q.darkGrey,shape:F.wave}),app:X({colors:Q.toastyOrange,shape:F.wave}),apis:X({colors:Q.teal,shape:F.wave2}),card:X({colors:Q.greens,shape:F.wave})},bt=16,Bt='"Helvetica Neue", Helvetica, Roboto, Arial, sans-serif',kt="home",Zt={htmlFontSize:bt,fontFamily:Bt,h1:{fontSize:54,fontWeight:700,marginBottom:10},h2:{fontSize:40,fontWeight:700,marginBottom:8},h3:{fontSize:32,fontWeight:700,marginBottom:6},h4:{fontWeight:700,fontSize:28,marginBottom:6},h5:{fontWeight:700,fontSize:24,marginBottom:4},h6:{fontWeight:700,fontSize:20,marginBottom:2}};function Ht(r){const{palette:e,htmlFontSize:n=bt,fontFamily:s=Bt,defaultPageTheme:a=kt,pageTheme:l=lt,typography:b}=r;if(!l[a])throw new Error(`${a} is not defined in pageTheme.`);return Zt.htmlFontSize=n,Zt.fontFamily=s,{palette:e,typography:b!=null?b:Zt,page:l[a],getPageTheme:({themeId:E})=>{var B;return(B=l[E])!==null&&B!==void 0?B:l[a]}}}var Pt=t(80012);const he={MuiCssBaseline:{styleOverrides:r=>({html:{height:"100%",fontFamily:r.typography.fontFamily},body:{height:"100%",fontFamily:r.typography.fontFamily,overscrollBehaviorY:"none",fontSize:"0.875rem",lineHeight:1.43,"&::-webkit-scrollbar, & *::-webkit-scrollbar":{backgroundColor:r.palette.background.paper,width:"1em"},"&::-webkit-scrollbar-thumb, & *::-webkit-scrollbar-thumb":{borderRadius:8,backgroundColor:r.palette.textVerySubtle,border:`3px solid ${r.palette.background.paper}`},"&::-webkit-scrollbar-thumb:active, & *::-webkit-scrollbar-thumb:active":{backgroundColor:r.palette.mode==="dark"?(0,Pt.a)(r.palette.textVerySubtle,.2):(0,Pt.e$)(r.palette.textVerySubtle,.2)},"&::-webkit-scrollbar-thumb:hover, & *::-webkit-scrollbar-thumb:hover":{backgroundColor:r.palette.mode==="dark"?(0,Pt.a)(r.palette.textVerySubtle,.2):(0,Pt.e$)(r.palette.textVerySubtle,.2)}},a:{color:"inherit",textDecoration:"none"}})},MuiGrid:{defaultProps:{spacing:2}},MuiSwitch:{defaultProps:{color:"primary"}},MuiTableRow:{styleOverrides:{root:({theme:r})=>({"&:nth-of-type(odd)":{backgroundColor:r.palette.background.default}}),hover:{"&:hover":{cursor:"pointer"}},head:({theme:r})=>({"&:nth-of-type(odd)":{backgroundColor:r.palette.background.paper}})}},MuiTableCell:{styleOverrides:{root:({theme:r})=>({wordBreak:"break-word",overflow:"hidden",verticalAlign:"middle",lineHeight:"1",margin:0,padding:r.spacing(3,2,3,2.5),borderBottom:0}),sizeSmall:({theme:r})=>({padding:r.spacing(1.5,2,1.5,2.5)}),head:({theme:r})=>({wordBreak:"break-word",overflow:"hidden",color:r.palette.textSubtle,fontWeight:"normal",lineHeight:"1"})}},MuiTabs:{styleOverrides:{root:{minHeight:24}}},MuiTab:{styleOverrides:{root:({theme:r})=>({color:r.palette.link,minHeight:24,textTransform:"initial",letterSpacing:"0.07em","&:hover":{color:(0,Pt.e$)(r.palette.link,.3),background:(0,Pt.a)(r.palette.link,.95)},[r.breakpoints.up("md")]:{minWidth:120,fontSize:r.typography.pxToRem(14),fontWeight:500}}),textColorPrimary:({theme:r})=>({color:r.palette.link})}},MuiTableSortLabel:{styleOverrides:{root:{color:"inherit","&:hover":{color:"inherit"},"&:focus":{color:"inherit"},"&.Mui-active":{fontWeight:"bold",color:"inherit"}}}},MuiListItemText:{styleOverrides:{dense:{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"}}},MuiButton:{styleOverrides:{text:{padding:void 0}}},MuiChip:{styleOverrides:{root:({theme:r})=>({marginRight:r.spacing(1),marginBottom:r.spacing(1)}),label:({theme:r})=>({lineHeight:r.spacing(2.5),fontWeight:r.typography.fontWeightMedium,fontSize:r.spacing(1.75)}),labelSmall:({theme:r})=>({fontSize:r.spacing(1.5)}),deleteIcon:({theme:r})=>({width:r.spacing(3),height:r.spacing(3),margin:r.spacing(0,.75,0,-.75)}),deleteIconSmall:({theme:r})=>({width:r.spacing(2),height:r.spacing(2),margin:r.spacing(0,.5,0,-.5)})}},MuiCard:{styleOverrides:{root:{display:"flex",flexDirection:"column"}}},MuiCardHeader:{styleOverrides:{root:{paddingBottom:0}}},MuiCardContent:{styleOverrides:{root:{flexGrow:1,"&:last-child":{paddingBottom:void 0}}}},MuiCardActions:{styleOverrides:{root:{justifyContent:"flex-end"}}},MuiLink:{defaultProps:{underline:"hover"}},MuiPaper:{styleOverrides:{root:{backgroundImage:"unset"}}}},Ee=r=>(...e)=>{const n=e.length===0?[1]:e,s=(a,l)=>typeof a=="string"?a:l*a;return n.map(a=>{const l=s(a,r);return typeof l=="number"?`${l}px`:l}).join(" ")};function Jt(r,e){if(!e||typeof e=="string")return;const n=typeof e=="function"?e(r):e;if(n)return{"@global":n}}function _t(r,e){if(!(!e||typeof e=="string")){if(typeof e=="object"){const n={...r},s=r.spacing(1);return typeof s=="number"&&(n.spacing=Ee(s)),Object.fromEntries(Object.entries(e).map(([a,l])=>typeof l=="function"?[a,l({theme:n})]:[a,l]))}return e}}const le=/^&.Mui-([\w-]+)$/;function Ae(r){let e=r;if(!r||typeof r!="object")return e;for(const n of Object.keys(r)){const s=r[n];if(!(!s||typeof s!="object"))for(const a of Object.keys(s)){const l=a,b=l.match(le);if(b){const[,E]=b,{[l]:B,...k}=s;B&&(e={...e,[n]:k,[E]:B})}}}return e}function Lt(r,e={}){const n={},s={};for(const a of Object.keys(e)){const l=e[a];l&&("styleOverrides"in l&&(a==="MuiCssBaseline"?n[a]=Jt(r,l.styleOverrides):n[a]=Ae(_t(r,l.styleOverrides))),"defaultProps"in l&&(s[a]=l.defaultProps))}return{overrides:n,props:s}}var Vt=new WeakMap;class te{getTheme(e){return(0,Dt._)(this,Vt).get(e)}constructor(e,n){(0,fe._)(this,Vt,{writable:!0,value:new Map}),(0,p._)(this,Vt,new Map),e&&(0,Dt._)(this,Vt).set("v4",e),n&&(0,Dt._)(this,Vt).set("v5",n)}}function xe(r){const e=Ht(r),n={...he,...r.components},s=(0,$.A)({...e,components:n}),a=Lt(s,n),l={...(0,I.A)(e),...a};return new te(l,s)}function Le(r){const e=adaptV4Theme(r),n=createTheme(r);return new te(n,createV5Theme(e))}const Fe={light:xe({palette:so.light}),dark:xe({palette:so.dark})};var ve=t(75962),Be=t(87145);const ie=[{id:"light",title:"Light Theme",variant:"light",icon:(0,i.jsx)(Be.A,{}),Provider:({children:r})=>(0,i.jsx)(ro,{theme:Fe.light,children:r})},{id:"dark",title:"Dark Theme",variant:"dark",icon:(0,i.jsx)(ve.A,{}),Provider:({children:r})=>(0,i.jsx)(ro,{theme:Fe.dark,children:r})}];var Fn=t(73466),Nn=t(39067),Wn=t.n(Nn);class io{get(e){for(const n of this.holders){const s=n.get(e);if(s)return s}}constructor(...e){(0,x._)(this,"holders",void 0),this.holders=e}}var on=t(43836),En=t(10602);const mr=(0,on.tK)("api-context"),Zo=r=>{var e;const{apis:n,children:s}=r,a=(e=(0,d.useContext)(mr))===null||e===void 0?void 0:e.atVersion(1),l=a?new io(n,a):n;return(0,i.jsx)(mr.Provider,{value:(0,En.B)({1:l}),children:s})};Zo.propTypes={apis:Wn().shape({get:Wn().func.isRequired}).isRequired,children:Wn().node};const Es=/^[a-z][a-z0-9]*(?:[-_][a-z][a-z0-9]*)*$/i;function ao(r){return typeof r=="object"&&r!==null&&!Array.isArray(r)}function Jo(r){return typeof r!="object"||r===null?r:Array.isArray(r)?r.map(Jo):Object.fromEntries(Object.entries(r).map(([e,n])=>[e,Jo(n)]))}function kn(r,e){if(r===null)return;if(r===void 0)return e===void 0?void 0:kn(e);if(typeof r!="object"||Array.isArray(r))return r;const n=ao(e)?e:{},s={};for(const a of new Set([...Object.keys(r),...Object.keys(n)])){const l=kn(r[a],n[a]);l!==void 0&&(s[a]=l)}return s}function Xo(r){if(r===null)return"null";if(Array.isArray(r))return"array";const e=typeof r;return e==="number"&&isNaN(r)?"nan":e==="string"&&r===""?"empty-string":e}const Ne={type(r,e,n,s){return`Invalid type in config for key '${r}' in '${e}', got ${n}, wanted ${s}`},missing(r,e){return`Missing required config value at '${r}' in '${e}'`},convert(r,e,n){return`Unable to convert config value for key '${r}' in '${e}' to a ${n}`}};class An{static fromConfigs(e){return e.length===0?new An(void 0):e.reduce((n,{data:s,context:a,filteredKeys:l,deprecatedKeys:b})=>{const E=new An(s,a,n);if(E.filteredKeys=l,b)for(const{key:B,description:k}of b)console.warn(`The configuration key '${B}' of ${a} is deprecated and may be removed soon. ${k||""}`);return E},void 0)}has(e){var n;const s=this.readValue(e);if(s===null)return!1;if(s!==void 0)return!0;var a;return(a=(n=this.fallback)===null||n===void 0?void 0:n.has(e))!==null&&a!==void 0?a:!1}keys(){var e;const n=this.data?Object.keys(this.data):[];var s;const a=(s=(e=this.fallback)===null||e===void 0?void 0:e.keys())!==null&&s!==void 0?s:[];return[...new Set([...n,...a])].filter(l=>{var b;return((b=this.data)===null||b===void 0?void 0:b[l])!==null})}get(e){const n=this.getOptional(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e!=null?e:""),this.context));return n}getOptional(e){var n;const s=Jo(this.readValue(e)),a=(n=this.fallback)===null||n===void 0?void 0:n.getOptional(e);if(s!==null){if(s===void 0){if(0)var l;return kn(a)}else if(a===void 0)return kn(s);return kn(s,a)}}getConfig(e){const n=this.getOptionalConfig(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e),this.context));return n}getOptionalConfig(e){var n;const s=this.readValue(e),a=(n=this.fallback)===null||n===void 0?void 0:n.getOptionalConfig(e);if(ao(s))return this.copy(s,e,a);if(s!==null){if(s!==void 0)throw new TypeError(Ne.type(this.fullKey(e),this.context,Xo(s),"object"));return a}}getConfigArray(e){const n=this.getOptionalConfigArray(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e),this.context));return n}getOptionalConfigArray(e){const n=this.readConfigValue(e,a=>{if(!Array.isArray(a))return{expected:"object-array"};for(const[l,b]of a.entries())if(!ao(b))return{expected:"object-array",value:b,key:`${e}[${l}]`};return!0});if(!n){if(0)var s;return}return n.map((a,l)=>this.copy(a,`${e}[${l}]`))}getNumber(e){const n=this.getOptionalNumber(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e),this.context));return n}getOptionalNumber(e){const n=this.readConfigValue(e,a=>typeof a=="number"||typeof a=="string"||{expected:"number"});if(typeof n=="number"||n===void 0)return n;const s=Number(n);if(!Number.isFinite(s))throw new Error(Ne.convert(this.fullKey(e),this.context,"number"));return s}getBoolean(e){const n=this.getOptionalBoolean(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e),this.context));return n}getOptionalBoolean(e){const n=this.readConfigValue(e,a=>typeof a=="boolean"||typeof a=="number"||typeof a=="string"||{expected:"boolean"});if(typeof n=="boolean"||n===void 0)return n;const s=String(n).trim();if(/^(?:y|yes|true|1|on)$/i.test(s))return!0;if(/^(?:n|no|false|0|off)$/i.test(s))return!1;throw new Error(Ne.convert(this.fullKey(e),this.context,"boolean"))}getString(e){const n=this.getOptionalString(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e),this.context));return n}getOptionalString(e){return this.readConfigValue(e,n=>typeof n=="string"&&n!==""||{expected:"string"})}getStringArray(e){const n=this.getOptionalStringArray(e);if(n===void 0)throw new Error(Ne.missing(this.fullKey(e),this.context));return n}getOptionalStringArray(e){return this.readConfigValue(e,n=>{if(!Array.isArray(n))return{expected:"string-array"};for(const[s,a]of n.entries())if(typeof a!="string"||a==="")return{expected:"string-array",value:a,key:`${e}[${s}]`};return!0})}fullKey(e){return`${this.prefix}${this.prefix?".":""}${e}`}copy(e,n,s){const a=new An(e,this.context,s,this.fullKey(n));return a.filteredKeys=this.filteredKeys,a}readConfigValue(e,n){const s=this.readValue(e);if(s===void 0){var a;if(0)var l;return(a=this.fallback)===null||a===void 0?void 0:a.readConfigValue(e,n)}if(s===null)return;const b=n(s);if(b!==!0){const{key:E=e,value:B=s,expected:k}=b;throw new TypeError(Ne.type(this.fullKey(E),this.context,Xo(B),k))}return s}readValue(e){const n=e?e.split("."):[];for(const a of n)if(!Es.test(a))throw new TypeError(`Invalid config key '${e}'`);if(this.data===void 0)return;let s=this.data;for(const[a,l]of n.entries())if(ao(s))s=s[l];else if(s!=null){const b=this.fullKey(n.slice(0,a).join("."));throw new TypeError(Ne.type(b,this.context,Xo(s),"object"))}return s}constructor(e,n="mock-config",s,a=""){(0,x._)(this,"data",void 0),(0,x._)(this,"context",void 0),(0,x._)(this,"fallback",void 0),(0,x._)(this,"prefix",void 0),(0,x._)(this,"filteredKeys",void 0),(0,x._)(this,"notifiedFilteredKeys",void 0),this.data=e,this.context=n,this.fallback=s,this.prefix=a,this.notifiedFilteredKeys=new Set}}const Kn="theme";class lo{static createWithStorage(e){const n=new lo(e);if(!window.localStorage)return n;var s;const a=(s=window.localStorage.getItem(Kn))!==null&&s!==void 0?s:void 0;return n.setActiveThemeId(a),n.activeThemeId$().subscribe(l=>{l?window.localStorage.setItem(Kn,l):window.localStorage.removeItem(Kn)}),window.addEventListener("storage",l=>{if(l.key===Kn){var b;const E=(b=localStorage.getItem(Kn))!==null&&b!==void 0?b:void 0;n.setActiveThemeId(E)}}),n}getInstalledThemes(){return this.themes.slice()}activeThemeId$(){return this.subject}getActiveThemeId(){return this.activeThemeId}setActiveThemeId(e){this.activeThemeId=e,this.subject.next(e)}constructor(e){(0,x._)(this,"themes",void 0),(0,x._)(this,"activeThemeId",void 0),(0,x._)(this,"subject",void 0),this.themes=e,this.subject=new J(void 0)}}var xn=t(63636);function yr(r){if(r.length<3)throw new Error(`The '${r}' feature flag must have a minimum length of three characters.`);if(r.length>150)throw new Error(`The '${r}' feature flag must not exceed 150 characters.`);if(!r.match(/^[a-z]+[a-z0-9-]+$/))throw new Error(`The '${r}' feature flag must start with a lowercase letter and only contain lowercase letters, numbers and hyphens. Examples: feature-flag-one, alpha, release-2020`)}class As{registerFlag(e){yr(e.name),this.registeredFeatureFlags.push(e)}getRegisteredFlags(){return this.registeredFeatureFlags.slice()}isActive(e){return this.flags||(this.flags=this.load()),this.flags.get(e)===xn.S.Active}save(e){this.flags||(this.flags=this.load()),e.merge||this.flags.clear();for(const[s,a]of Object.entries(e.states))this.flags.set(s,a);const n=Array.from(this.flags.entries()).filter(([,s])=>s===xn.S.Active);window.localStorage.setItem("featureFlags",JSON.stringify(Object.fromEntries(n)))}load(){try{const e=window.localStorage.getItem("featureFlags");if(!e)return new Map;const n=JSON.parse(e);if(typeof n!="object"||n===null||Array.isArray(n))return new Map;const s=Object.entries(n).filter(([a,l])=>(yr(a),l===xn.S.Active));return new Map(s)}catch{return new Map}}constructor(){(0,x._)(this,"registeredFeatureFlags",[]),(0,x._)(this,"flags",void 0)}}const co=(0,St.y)({id:"core.apptheme"}),Er=(0,St.y)({id:"core.applanguage"});var xs=t(56038);class qo{static validateFactories(e,n){for(const s of n){const a=[s],l=new Set;for(;a.length;){const b=a.shift(),E=e.get(b);if(E)for(const B of Object.values(E.deps)){if(B.id===s.id)throw new Error(`Circular dependency of api factory for ${s}`);l.has(B)||(l.add(B),a.push(B))}}}}get(e){return this.load(e)}load(e,n=[]){const s=this.apis.get(e.id);if(s)return s;const a=this.factories.get(e);if(!a)return;if(n.includes(a.api))throw new Error(`Circular dependency of api factory for ${a.api}`);const l=this.loadDeps(e,a.deps,[...n,a.api]),b=a.factory(l);return this.apis.set(e.id,b),b}loadDeps(e,n,s){const a={};for(const l in n)if(n.hasOwnProperty(l)){const b=n[l],E=this.load(b,s);if(!E)throw new Error(`No API factory available for dependency ${b} of dependent ${e}`);a[l]=E}return a}constructor(e){(0,x._)(this,"factories",void 0),(0,x._)(this,"apis",void 0),this.factories=e,this.apis=new Map}}var tr;(function(r){r[r.default=10]="default",r[r.app=50]="app",r[r.static=100]="static"})(tr||(tr={}));class Cs{register(e,n){const s=tr[e],a=this.factories.get(n.api.id);return a&&a.priority>=s?!1:(this.factories.set(n.api.id,{priority:s,factory:n}),!0)}get(e){const n=this.factories.get(e.id);if(n)return n.factory}getAllApis(){const e=new Set;for(const{factory:n}of this.factories.values())e.add(n.api);return e}constructor(){(0,x._)(this,"factories",new Map)}}function bs(r){const e={};for(const s in r.collectors)r.collectors.hasOwnProperty(s)&&(e[s]=r.collectors[s]());const n=[{node:d.Children.toArray(r.root),parent:void 0,contexts:{}}];for(;n.length!==0;){const{node:s,parent:a,contexts:l}=n.shift();d.Children.forEach(s,b=>{if(!(0,d.isValidElement)(b))return;const E={};for(const B in e)if(e.hasOwnProperty(B)){const k=e[B];E[B]=k.visit(k.accumulator,b,a,l[B])}for(const B of r.discoverers){const k=B(b);k&&n.push({node:k,parent:b,contexts:E})}})}return Object.fromEntries(Object.entries(e).map(([s,a])=>[s,a.accumulator]))}function uo(r,e){return()=>({accumulator:r(),visit:e})}function Ss(r){var e;return(e=r.props)===null||e===void 0?void 0:e.children}function Os(r){var e,n;if(!((e=r.props)===null||e===void 0)&&e.path&&(!((n=r.props)===null||n===void 0)&&n.element)){var s;return(s=r.props)===null||s===void 0?void 0:s.element}}var Pe=t(19402);const ws=uo(()=>new Set,(r,e)=>{const n=(0,Pe.E)(e,"core.plugin");n&&r.add(n)});var zn=t(72427);const Ar=r=>{const{children:e}=r,n=(0,zn.gf)(xn.B),s="with"in r?n.isActive(r.with):!n.isActive(r.without);return(0,i.jsx)(i.Fragment,{children:s?e:null})};(0,Pe.h)(Ar,"core.featureFlagged",!0);const ho={caseSensitive:!1,path:"*",element:"match-all",routeRefs:new Set,plugins:new Set};function fo(r){const e=r;if(e!=null&&e.type){var n,s;return(s=(n=e.type.displayName)!==null&&n!==void 0?n:e.type.name)!==null&&s!==void 0?s:String(e.type)}return String(e)}const xr=r=>{const e=new Set;return r&&e.add(r),e};function Cr(r,e=new Array){return d.Children.forEach(r,n=>{if(!(0,d.isValidElement)(n))return;const s=(0,Pe.E)(n,"core.mountPoint");if(s){const a=(0,Pe.E)(n,"core.plugin");e.push({routeRef:s,plugin:a})}Cr(n.props.children,e)}),e}const Ps=uo(()=>({paths:new Map,parents:new Map,objects:new Array}),(r,e,n,s)=>{var a,l;if(s!=null&&s.isElementAncestor)return s;if((n==null?void 0:n.props.element)===e)return{...s,isElementAncestor:!0};const b=(a=e.props)===null||a===void 0?void 0:a.path,E=(0,Pe.E)(e,"core.mountPoint");if(E&&b)throw new Error(`Path property may not be set directly on a routable extension "${fo(e)}"`);var B;const k=(B=s==null||(l=s.obj)===null||l===void 0?void 0:l.children)!==null&&B!==void 0?B:r.objects;if(b!==void 0){if(typeof b!="string")throw new Error(`Element path must be a string at "${fo(e)}"`);const At=b.startsWith("/")?b.slice(1):b,Ut=e.props.element;if((0,Pe.E)(e,"core.gatherMountPoints")){var Z;if(Ut)throw new Error(`Mount point gatherers may not have an element prop "${fo(e)}"`);const Kt={path:At,element:"gathered",routeRefs:new Set,caseSensitive:!!(!((Z=e.props)===null||Z===void 0)&&Z.caseSensitive),children:[ho],plugins:new Set};return k.push(Kt),{obj:Kt,gatherPath:At,routeRef:s==null?void 0:s.routeRef,gatherRouteRef:s==null?void 0:s.routeRef}}if(Ut){var rt;const[Kt,...me]=Cr(Ut);if(me.length>0)throw new Error(`Route element with path "${b}" may not contain multiple routable extensions`);if(!Kt)return s;const{routeRef:oe,plugin:Ie}=Kt,Zn={path:At,element:"mounted",routeRefs:new Set([oe]),caseSensitive:!!(!((rt=e.props)===null||rt===void 0)&&rt.caseSensitive),children:[ho],plugins:xr(Ie)};return k.push(Zn),r.paths.set(oe,At),r.parents.set(oe,s==null?void 0:s.routeRef),{obj:Zn,routeRef:oe!=null?oe:s==null?void 0:s.routeRef,gatherPath:At,gatherRouteRef:s==null?void 0:s.gatherRouteRef}}}if(E){var et;if((s==null?void 0:s.gatherPath)===void 0)throw new Error(`Routable extension "${fo(e)}" with mount point "${E}" must be assigned a path`);s==null||(et=s.obj)===null||et===void 0||et.routeRefs.add(E);const At=(0,Pe.E)(e,"core.plugin");if(At){var ct;s==null||(ct=s.obj)===null||ct===void 0||ct.plugins.add(At)}return r.paths.set(E,s.gatherPath),r.parents.set(E,s==null?void 0:s.gatherRouteRef),{...s,routeRef:E}}return s}),Ts=uo(()=>({paths:new Map,parents:new Map,objects:new Array}),(r,e,n,s)=>{var a,l,b;if((n==null?void 0:n.props.element)===e)return s;let E=s==null?void 0:s.obj,B=s==null?void 0:s.routeRef,k=s==null?void 0:s.sticky;const Z=(a=e.props)===null||a===void 0?void 0:a.path;var rt;const et=(rt=E==null?void 0:E.children)!==null&&rt!==void 0?rt:r.objects,ct=!!(!((l=e.props)===null||l===void 0)&&l.caseSensitive);let At=s==null?void 0:s.path;if((0,Pe.E)(e,"core.gatherMountPoints")){if(!Z)throw new Error("Mount point gatherer must have a path");At=Z}const Ut=(b=e.props)===null||b===void 0?void 0:b.element;let Kt=(0,Pe.E)(e,"core.mountPoint");if(!Kt&&(0,d.isValidElement)(Ut)&&(Kt=(0,Pe.E)(Ut,"core.mountPoint")),Kt){let Ie=Z;if(At&&(Ie?At=void 0:Ie=At),!Ie)throw new Error("Mounted routable extension must have a path");r.paths.set(Kt,Ie),B&&k?(r.parents.set(Kt,B),Z&&(B=Kt,k=!1)):(r.parents.set(Kt,B),B=Kt),Z?(E={caseSensitive:ct,path:Z,element:"mounted",routeRefs:new Set([Kt]),children:[ho],plugins:xr((0,Pe.E)(e.props.element,"core.plugin"))},et.push(E)):E==null||E.routeRefs.add(Kt)}if((0,Pe.E)(e,"core.gatherMountPoints")&&(k=!0),(0,Pe.E)(e,"core.gatherMountPoints")){if(!Z)throw new Error("Mount point gatherer must have a path");if(!Kt){var oe;E={caseSensitive:ct,path:Z,element:"gathered",routeRefs:new Set,children:[ho],plugins:(s==null||(oe=s.obj)===null||oe===void 0?void 0:oe.plugins)||new Set},et.push(E)}}return{obj:E,path:At,routeRef:B,sticky:k}}),Rs=uo(()=>new Set,(r,e)=>{if(e.type===Ar){const n=e.props;r.add("with"in n?n.with:n.without)}});var Hn=t(74808),Is=t(63544);const _n=(0,Is.Q)("route-ref-type",()=>Symbol("route-ref-type"));function br(r){return r[_n]==="absolute"}function Sr(r){return r[_n]==="sub"}function Ds(r){return r[_n]==="external"}function po(...r){const e=r.join("/").replace(/\/\/+/g,"/");return e!=="/"&&e.endsWith("/")?e.slice(0,-1):e}var Ms=t(46155),Ls=t.n(Ms);function Bs(r,e,n){let s,a="";if(br(r))s=r;else if(Sr(r))s=r.parent,a=r.path;else if(Ds(r)){const E=n.get(r);if(!E)return[void 0,""];if(br(E))s=E;else if(Sr(E))s=E.parent,a=E.path;else throw new Error(`ExternalRouteRef was bound to invalid target, ${E}`)}else throw r[_n]?new Error(`Unknown or invalid route ref type, ${r[_n]}`):new Error(`Unknown object passed to useRouteRef, got ${r}`);if(!s)return[void 0,""];const l=e.get(s);if(l===void 0)return[void 0,""];const b=po(l,a);return[s,b]}function js(r,e,n,s,a){var l;const b=(l=(0,Hn.ue)(a,e))!==null&&l!==void 0?l:[],E=Array();let B=-1;for(let rt=r;rt&&(B=b.findIndex(et=>et.route.routeRefs.has(rt)),B===-1);rt=s.get(rt))E.unshift(rt);E.length===0&&(B-=1);const k=B===-1?"":b[B].pathname,Z=E.slice(0,-1).map(rt=>{const et=n.get(rt);if(et===void 0)throw new Error(`No path for ${rt}`);if(et.includes(":"))throw new Error(`Cannot route to ${r} with parent ${rt} as it has parameters`);return et});return`${po(k,...Z)}/`}class Us{resolve(e,n){const[s,a]=Bs(e,this.routePaths,this.routeBindings);if(!s)return;let l;typeof n=="string"?l=this.trimPath(n):n.pathname?l={...n,pathname:this.trimPath(n.pathname)}:l=n;const b=this.appBasePath+js(s,l,this.routePaths,this.routeParents,this.routeObjects);return(...[B])=>{const k=B&&Ls()(B,Z=>typeof Z=="string"?Z.replaceAll(/[&?#;\/]/g,rt=>encodeURIComponent(rt)):Z);return po(b,(0,Hn.tW)(a,k))}}trimPath(e){return e&&(e.startsWith(this.appBasePath)?e.slice(this.appBasePath.length):e)}constructor(e,n,s,a,l){(0,x._)(this,"routePaths",void 0),(0,x._)(this,"routeParents",void 0),(0,x._)(this,"routeObjects",void 0),(0,x._)(this,"routeBindings",void 0),(0,x._)(this,"appBasePath",void 0),this.routePaths=e,this.routeParents=n,this.routeObjects=s,this.routeBindings=a,this.appBasePath=l}}const $s=(0,on.tK)("routing-context"),Fs=({routePaths:r,routeParents:e,routeObjects:n,routeBindings:s,basePath:a="",children:l})=>{const b=new Us(r,e,n,s,a),E=(0,En.B)({1:b});return(0,i.jsx)($s.Provider,{value:E,children:l})};function Ns(r,e){const n=new Set(e.values());n.delete(void 0);for(const s of e.keys()){if(n.has(s))continue;let a=s,l="";for(;a;){const E=r.get(a);if(E===void 0)throw new Error(`No path for ${a}`);l=po(E,l),a=e.get(a)}const b=l.match(/:(\w+)/g);if(b){for(let E=0;E<b.length;E++)for(let B=E+1;B<b.length;B++)if(b[B]===b[E])throw new Error(`Parameter ${b[B]} is duplicated in path ${l}`)}}}function Ws(r,e){for(const n of e)if(n.externalRoutes){for(const[s,a]of Object.entries(n.externalRoutes))if(!a.optional&&!r.has(a))throw new Error(`External route '${s}' of the '${n.getId()}' plugin must be bound to a target route. See https://backstage.io/link?bind-routes for details.`)}}const ks=(0,on.tK)("app-context"),Ks=({appContext:r,children:e})=>{const n=(0,En.B)({1:r});return(0,i.jsx)(ks.Provider,{value:n,children:e})},Or="app",zs=`${Or}-auth-cookie-expires-at`,Hs=5*6e4,wr=5e3,_s=2,Vs=5*6e4;function Gs({discoveryApi:r,fetchApi:e,errorApi:n}){let s=!1,a,l=!0,b=wr;const E="BroadcastChannel"in window?new BroadcastChannel(zs):void 0,B=et=>{const ct=(1+3*Math.random())*6e4;return Math.max(et-Date.now(),Hs)-ct},k=async()=>{try{const ct=`${await r.getBaseUrl(Or)}/.backstage/auth/v1/cookie`,At=await e.fetch(ct,{credentials:"include"});if(!At.ok)throw new Error(`Request failed with status ${At.status} ${At.statusText}, see request towards ${ct} for more details`);const Ut=await At.json();if(!Ut.expiresAt)throw new Error("No expiration date in response");const Kt=Date.parse(Ut.expiresAt);if(Number.isNaN(Kt))throw new Error("Invalid expiration date in response");l=!0,E==null||E.postMessage({action:"COOKIE_REFRESH_SUCCESS",payload:{expiresAt:new Date(Kt).toISOString()}}),rt(B(Kt))}catch(et){l?(l=!1,b=wr):(b=Math.min(Vs,b*_s),console.error("Session cookie refresh failed",et),n.post(new Error("Session refresh failed, see developer console for details"))),rt(b)}},Z=et=>{const{data:ct}=et;if(!(ct===null||typeof ct!="object")&&"action"in ct&&ct.action==="COOKIE_REFRESH_SUCCESS"){const At=Date.parse(ct.payload.expiresAt);if(Number.isNaN(At)){console.warn("Received invalid expiration from session refresh channel");return}rt(B(At))}};function rt(et){s||(a&&clearTimeout(a),a=setTimeout(k,et))}return E==null||E.addEventListener("message",Z),k(),()=>{s=!0,a&&clearTimeout(a),E==null||E.removeEventListener("message",Z),E==null||E.close()}}function Pr(r){return new Error(`Tried to access IdentityApi ${r} before app was loaded`)}function er(r){console.warn(`WARNING: Call to ${r} is deprecated and will break in the future`)}var go=new WeakMap;class Ys{setTarget(e,n){this.target=e,this.signOutTargetUrl=n.signOutTargetUrl,this.resolveTarget(e)}getUserId(){if(!this.target)throw Pr("getUserId");if(!this.target.getUserId)throw new Error("IdentityApi does not implement getUserId");return er("getUserId"),this.target.getUserId()}getProfile(){if(!this.target)throw Pr("getProfile");if(!this.target.getProfile)throw new Error("IdentityApi does not implement getProfile");return er("getProfile"),this.target.getProfile()}async getProfileInfo(){return this.waitForTarget.then(e=>e.getProfileInfo())}async getBackstageIdentity(){const e=await this.waitForTarget.then(n=>n.getBackstageIdentity());return e.userEntityRef.match(/^.*:.*\/.*$/)||console.warn(`WARNING: The App IdentityApi provided an invalid userEntityRef, '${e.userEntityRef}'. It must be a full Entity Reference of the form '<kind>:<namespace>/<name>'.`),e}async getCredentials(){return this.waitForTarget.then(e=>e.getCredentials())}async getIdToken(){return this.waitForTarget.then(e=>{if(!e.getIdToken)throw new Error("IdentityApi does not implement getIdToken");return er("getIdToken"),e.getIdToken()})}async signOut(){var e,n,s;await this.waitForTarget.then(a=>a.signOut()),await((e=(0,Dt._)(s=n=this,go))===null||e===void 0?void 0:e.call(n)),window.location.href=this.signOutTargetUrl}enableCookieAuth(e){if((0,Dt._)(this,go))return;const n=Gs(e);(0,p._)(this,go,async()=>{n();const s=await e.discoveryApi.getBaseUrl("app");try{await e.fetchApi.fetch(`${s}/.backstage/auth/v1/cookie`,{method:"DELETE"})}catch{}})}constructor(){(0,x._)(this,"target",void 0),(0,x._)(this,"waitForTarget",void 0),(0,x._)(this,"resolveTarget",()=>{}),(0,x._)(this,"signOutTargetUrl","/"),(0,fe._)(this,go,{writable:!0,value:void 0}),this.waitForTarget=new Promise(e=>{this.resolveTarget=e})}}var Qs=t(1394);function Zs(r,e,n){if(r!==void 0){const a=n.find(l=>l.id===r);if(a)return a}if(e){const a=n.find(l=>l.variant==="dark");if(a)return a}const s=n.find(a=>a.variant==="light");return s||n[0]}const Js=()=>{const r=(0,d.useMemo)(()=>window.matchMedia("(prefers-color-scheme: dark)"),[]),[e,n]=(0,d.useState)(r.matches);return(0,d.useEffect)(()=>{const s=a=>{n(a.matches)};return r.addListener(s),()=>{r.removeListener(s)}},[r]),e};function Tr({children:r}){const e=(0,zn.gf)(co),n=(0,Qs.A)(e.activeThemeId$(),e.getActiveThemeId()),s=window.matchMedia?Js():!1,a=Zs(n,s,e.getInstalledThemes());if(!a)throw new Error("App has no themes");return(0,i.jsx)(a.Provider,{children:r})}const Rr=async()=>Xs();function Xs(r="__APP_INJECTED_RUNTIME_CONFIG__"){const e=[{context:"app-config.yaml",data:{app:{title:"Techdocs Preview App",baseUrl:"http://localhost:3000"},backend:{baseUrl:"http://localhost:3000"},techdocs:{builder:"external"}}}];if(!e)throw new Error("No static configuration provided");if(!Array.isArray(e))throw new Error("Static configuration has invalid format");const n=e.slice();if(r!=="__app_injected_runtime_config__".toLocaleUpperCase("en-US"))try{const a=JSON.parse(r);Array.isArray(a)?n.push(...a):n.push({data:a,context:"env"})}catch(a){throw new Error(`Failed to load runtime configuration, ${a}`)}const s=window.__APP_CONFIG__;return s&&n.push({context:"window",data:s}),n}class qs{add(e,n){return this.apis.push([e.id,n]),n}build(){return new Cn(new Map(this.apis))}constructor(){(0,x._)(this,"apis",[])}}class Cn{static builder(){return new qs}static from(e){return new Cn(new Map(e.map(([n,s])=>[n.id,s])))}static with(e,n){return new Cn(new Map([[e.id,n]]))}with(e,n){return new Cn(new Map([...this.apis,[e.id,n]]))}get(e){return this.apis.get(e.id)}constructor(e){(0,x._)(this,"apis",void 0),this.apis=e}}function ti(r){const e=new Map;return r&&r({bind:(s,a)=>{for(const[l,b]of Object.entries(a)){const E=s[l];if(!E)throw new Error(`Key ${l} is not an existing external route`);if(!b&&!E.optional)throw new Error(`External route ${l} is required but was undefined`);b&&e.set(E,b)}}}),e}function Vn(){const[r]=(0,m.AV)((0,i.jsx)(m.qh,{index:!0,element:(0,i.jsx)("div",{})}));return!r.index}const Ir=(0,d.createContext)(void 0);var Dr=t(82266),Mr=t(93368),ei=t(25862);const ni=(r,e)=>{try{const n=(0,Hn.ue)(e,{pathname:r}),s=n==null?void 0:n.filter(B=>{var k;return(B==null||(k=B.route.routeRefs)===null||k===void 0?void 0:k.size)>0}).pop(),a=s==null?void 0:s.route;if(!a||a.path===""&&r!=="/")return;let l;a.routeRefs.size===1&&(l=a.routeRefs.values().next().value);let b;a.plugins.size===1&&(b=a.plugins.values().next().value);const E=Object.entries((s==null?void 0:s.params)||{}).reduce((B,[k,Z])=>(Z!==void 0&&k!=="*"&&(B[k]=Z),B),{});return{extension:"App",pluginId:(b==null?void 0:b.getId())||"root",...l?{routeRef:l.id}:{},_routeNodeType:a.element,params:E}}catch{return}},oi=({pathname:r,search:e,hash:n,attributes:s})=>{const a=(0,Mr.s)();return(0,d.useEffect)(()=>{a.captureEvent("navigate",`${r}${e}${n}`,{attributes:s})},[a,r,e,n,s]),null},vo=({routeObjects:r})=>{const{pathname:e,search:n,hash:s}=(0,m.zy)(),{params:a,...l}=ni(e,r)||{params:{}};return(0,i.jsx)(ei.Ig,{attributes:l,children:(0,i.jsx)(oi,{pathname:e,search:n,hash:s,attributes:a})})};function ri(r){return Vn()?nr(r):""}function nr(r){var e;let{pathname:n}=new URL((e=r.getOptionalString("app.baseUrl"))!==null&&e!==void 0?e:"/","http://sample.dev");return n=n.replace(/\/*$/,""),n}function Lr({component:r,appIdentityProxy:e,children:n}){const[s,a]=(0,d.useState)(),l=(0,zn.gf)($t.U),b=nr(l);return s?(e.setTarget(s,{signOutTargetUrl:b||"/"}),(0,i.jsx)(i.Fragment,{children:n})):(0,i.jsx)(r,{onSignInSuccess:a})}function Br(r){const{Router:e,SignInPage:n}=(0,Dr.n)().getComponents(),s=(0,zn.gf)($t.U),a=nr(s),l=`${a}/*`,b=(0,d.useContext)(Ir);if(!b)throw new Error("AppRouter must be rendered within the AppProvider");const{routeObjects:E,appIdentityProxy:B}=b;return n?Vn()?(0,i.jsxs)(e,{children:[(0,i.jsx)(vo,{routeObjects:E}),(0,i.jsx)(Lr,{component:n,appIdentityProxy:B,children:(0,i.jsx)(m.BV,{children:(0,i.jsx)(m.qh,{path:l,element:(0,i.jsx)(i.Fragment,{children:r.children})})})})]}):(0,i.jsxs)(e,{basename:a,children:[(0,i.jsx)(vo,{routeObjects:E}),(0,i.jsx)(Lr,{component:n,appIdentityProxy:B,children:r.children})]}):(B.setTarget({getUserId:()=>"guest",getIdToken:async()=>{},getProfile:()=>({email:"guest@example.com",displayName:"Guest"}),getProfileInfo:async()=>({email:"guest@example.com",displayName:"Guest"}),getBackstageIdentity:async()=>({type:"user",userEntityRef:"user:default/guest",ownershipEntityRefs:["user:default/guest"]}),getCredentials:async()=>({}),signOut:async()=>{}},{signOutTargetUrl:a||"/"}),Vn()?(0,i.jsxs)(e,{children:[(0,i.jsx)(vo,{routeObjects:E}),(0,i.jsx)(m.BV,{children:(0,i.jsx)(m.qh,{path:l,element:(0,i.jsx)(i.Fragment,{children:r.children})})})]}):(0,i.jsxs)(e,{basename:a,children:[(0,i.jsx)(vo,{routeObjects:E}),r.children]}))}(0,Pe.h)(Br,"core.type","AppRouter");const Gn="language",Je="en";var Yn=new WeakMap,bn=new WeakMap,mo=new WeakMap;class yo{static create(e){var n;const s=(n=e==null?void 0:e.availableLanguages)!==null&&n!==void 0?n:[Je];if(s.length!==new Set(s).size)throw new Error(`Supported languages may not contain duplicates, got '${s.join("', '")}'`);if(!s.includes(Je))throw new Error(`Supported languages must include '${Je}'`);var a;const l=(a=e==null?void 0:e.defaultLanguage)!==null&&a!==void 0?a:Je;if(!s.includes(l))throw new Error(`Initial language must be one of the supported languages, got '${l}'`);return new yo(s,l)}static createWithStorage(e){const n=yo.create(e);if(!window.localStorage)return n;const s=window.localStorage.getItem(Gn),{languages:a}=n.getAvailableLanguages();return s&&a.includes(s)&&n.setLanguage(s),n.language$().subscribe(({language:l})=>{l!==window.localStorage.getItem(Gn)&&window.localStorage.setItem(Gn,l)}),window.addEventListener("storage",l=>{if(l.key===Gn){var b;const E=(b=localStorage.getItem(Gn))!==null&&b!==void 0?b:void 0;E&&n.setLanguage(E)}}),n}getAvailableLanguages(){return{languages:(0,Dt._)(this,Yn).slice()}}setLanguage(e){const n=e!=null?e:Je;if(n!==(0,Dt._)(this,bn)){if(n&&!(0,Dt._)(this,Yn).includes(n))throw new Error(`Failed to change language to '${n}', available languages are '${(0,Dt._)(this,Yn).join("', '")}'`);(0,p._)(this,bn,n),(0,Dt._)(this,mo).next({language:n})}}getLanguage(){return{language:(0,Dt._)(this,bn)}}language$(){return(0,Dt._)(this,mo)}constructor(e,n){(0,fe._)(this,Yn,{writable:!0,value:void 0}),(0,fe._)(this,bn,{writable:!0,value:void 0}),(0,fe._)(this,mo,{writable:!0,value:void 0}),(0,p._)(this,Yn,e),(0,p._)(this,bn,n),(0,p._)(this,mo,new J({language:(0,Dt._)(this,bn)}))}}var We=t(75944),pn=t(91196),si=t(47304),ii=t(99833),jr=t(93184);function Ur(r){return Object.fromEntries(Object.entries(r).filter(e=>e[1]!==null))}var Sn=new WeakMap,Eo=new WeakMap,On=new WeakMap,Ao=new WeakSet;class ai{addTranslationResource(e){const n=(0,ii.Y)(e);for(const s of n.resources){const a=(0,We._)(this,Ao,or).call(this,s.language,n.id);(0,Dt._)(this,On).has(a)||(0,Dt._)(this,On).set(a,s.loader)}}needsLoading(e,n){const s=(0,We._)(this,Ao,or).call(this,e,n);return(0,Dt._)(this,On).get(s)?!(0,Dt._)(this,Sn).has(s):!1}async load(e,n){const s=(0,We._)(this,Ao,or).call(this,e,n),a=(0,Dt._)(this,On).get(s);if(!a||(0,Dt._)(this,Sn).has(s))return;const l=(0,Dt._)(this,Eo).get(s);if(l){await l;return}const b=a().then(E=>{this.onLoad({language:e,namespace:n,messages:E.messages}),(0,Dt._)(this,Sn).add(s)},E=>{throw(0,Dt._)(this,Sn).add(s),E});(0,Dt._)(this,Eo).set(s,b),await b}constructor(e){(0,pn._)(this,Ao),(0,x._)(this,"onLoad",void 0),(0,fe._)(this,Sn,{writable:!0,value:void 0}),(0,fe._)(this,Eo,{writable:!0,value:void 0}),(0,fe._)(this,On,{writable:!0,value:void 0}),this.onLoad=e,(0,p._)(this,Sn,new Set),(0,p._)(this,Eo,new Map),(0,p._)(this,On,new Map)}}function or(r,e){return`${r}/${e}`}var Qn=new WeakMap,wn=new WeakMap,gn=new WeakMap,rr=new WeakMap,xo=new WeakMap,$r=new WeakSet,Co=new WeakSet,sr=new WeakSet;class ir{static create(e){const{languages:n}=e.languageApi.getAvailableLanguages(),s=(0,si.Q_)({fallbackLng:Je,supportedLngs:n,interpolation:{escapeValue:!1},ns:[],defaultNS:!1,fallbackNS:!1,initImmediate:!1});if(s.init(),!s.isInitialized)throw new Error("i18next was unexpectedly not initialized");const{language:a}=e.languageApi.getLanguage();a!==Je&&s.changeLanguage(a);const l=new ai(B=>{s.addResourceBundle(B.language,B.namespace,Ur(B.messages),!1,!0)}),b=(e==null?void 0:e.resources)||[];for(let B=b.length-1;B>=0;B--){const k=b[B];k.$$type==="@backstage/TranslationResource"?l.addTranslationResource(k):k.$$type==="@backstage/TranslationMessages"&&s.addResourceBundle(Je,k.id,Ur(k.messages),!0,!1)}const E=new ir(s,l,e.languageApi.getLanguage().language);return e.languageApi.language$().subscribe(({language:B})=>{(0,We._)(E,$r,li).call(E,B)}),E}getTranslation(e){const n=(0,jr.v)(e);return(0,We._)(this,sr,Fr).call(this,n),(0,We._)(this,Co,ar).call(this,n)}translation$(e){const n=(0,jr.v)(e);return(0,We._)(this,sr,Fr).call(this,n),new(K())(s=>{let a={};const l=()=>{a={};const E=a;(0,Dt._)(this,wn).load((0,Dt._)(this,gn),n.id).then(()=>{if(E===a){const B=(0,We._)(this,Co,ar).call(this,n);B.ready&&s.next(B)}},B=>{E===a&&s.error(Array.isArray(B)?B[0]:B)})},b=()=>{const E=(0,We._)(this,Co,ar).call(this,n);E.ready?s.next(E):l()};return(0,Dt._)(this,wn).needsLoading((0,Dt._)(this,gn),n.id)&&l(),(0,Dt._)(this,xo).add(b),()=>{(0,Dt._)(this,xo).delete(b)}})}constructor(e,n,s){(0,pn._)(this,$r),(0,pn._)(this,Co),(0,pn._)(this,sr),(0,fe._)(this,Qn,{writable:!0,value:void 0}),(0,fe._)(this,wn,{writable:!0,value:void 0}),(0,fe._)(this,gn,{writable:!0,value:void 0}),(0,fe._)(this,rr,{writable:!0,value:new Set}),(0,fe._)(this,xo,{writable:!0,value:new Set}),(0,p._)(this,Qn,e),(0,p._)(this,wn,n),(0,p._)(this,gn,s)}}function li(r){(0,Dt._)(this,gn)!==r&&((0,p._)(this,gn,r),(0,Dt._)(this,Qn).changeLanguage(r),(0,Dt._)(this,xo).forEach(e=>e()))}function ar(r){return(0,Dt._)(this,wn).needsLoading((0,Dt._)(this,gn),r.id)?{ready:!1}:{ready:!0,t:(0,Dt._)(this,Qn).getFixedT(null,r.id)}}function Fr(r){if((0,Dt._)(this,rr).has(r.id))return;(0,Dt._)(this,rr).add(r.id);const e=r.getDefaultMessages();(0,Dt._)(this,Qn).addResourceBundle(Je,r.id,e,!0,!1);const n=r.getDefaultResource();n&&(0,Dt._)(this,wn).addTranslationResource(n)}function Nr(r){const e=new URL(r);return e.protocol=document.location.protocol,e.hostname=document.location.hostname,e.port=document.location.port,e.toString().replace(/\/$/,"")}function ci(r){const e=An.fromConfigs(r),n=e.getOptionalString("app.baseUrl"),s=e.getOptionalString("backend.baseUrl");let a=r,l,b;if(n&&s){const E=new URL(n).origin,B=new URL(s).origin;if(E===B){const k=Nr(s);s!==k&&(l=k)}}if(n){const E=Nr(n);n!==E&&(b=E)}return(b||l)&&(a=a.concat({data:{app:b&&{baseUrl:b},backend:l&&{baseUrl:l}},context:"relative-resolver"})),a}function di(){const r=document.querySelector('meta[name="backstage-app-mode"]');var e;return((e=r==null?void 0:r.getAttribute("content"))!==null&&e!==void 0?e:"public")==="protected"}function ui(r,e,n){var s;const a=!!r,l=(0,Fn.A)(r||(()=>Promise.resolve([])));let b;if(a&&l.loading){const{Progress:k}=e;b=(0,i.jsx)(k,{})}else if(l.error){const{BootErrorPage:k}=e;b=(0,i.jsx)(k,{step:"load-config",error:l.error})}const{ThemeProvider:E=Tr}=e;return b?{node:(0,i.jsx)(Zo,{apis:Cn.with(co,n),children:(0,i.jsx)(E,{children:b})})}:{api:An.fromConfigs(!((s=l.value)===null||s===void 0)&&s.length?ci(l.value):[])}}class hi{getPlugins(){return this.app.getPlugins()}getSystemIcon(e){return this.app.getSystemIcon(e)}getSystemIcons(){return this.app.getSystemIcons()}getComponents(){return this.app.getComponents()}constructor(e){(0,x._)(this,"app",void 0),this.app=e}}var lr=new WeakMap;class fi{getPlugins(){return Array.from(this.plugins)}getSystemIcon(e){return this.icons[e]}getSystemIcons(){return this.icons}getComponents(){return this.components}createRoot(e){const n=this.getProvider();return()=>(0,i.jsx)(n,{children:e})}getProvider(){if((0,Dt._)(this,lr))throw new Error("app.getProvider() or app.createRoot() has already been called, and can only be called once");(0,p._)(this,lr,!0);const e=new hi(this);let n=!1;return({children:a})=>{const l=(0,d.useRef)(!0),b=(0,d.useMemo)(()=>lo.createWithStorage(this.themes),[]),{routing:E,featureFlags:B,routeBindings:k}=(0,d.useMemo)(()=>{const Ut=Vn();Ut&&console.warn(`
4
+ DEPRECATION WARNING: React Router Beta is deprecated and support for it will be removed in a future release.
5
+ Please migrate to use React Router v6 stable.
6
+ See https://backstage.io/docs/tutorials/react-router-stable-migration
7
+ `);const Kt=bs({root:a,discoverers:[Ss,Os],collectors:{routing:Ut?Ts:Ps,collectedPlugins:ws,featureFlags:Rs}});return Kt.collectedPlugins.forEach(me=>this.plugins.add(me)),this.verifyPlugins(this.plugins),this.getApiHolder(),{...Kt,routeBindings:ti(this.bindRoutes)}},[a]);n||(n=!0,Ns(E.paths,E.parents),Ws(k,this.plugins));const Z=ui(this.configLoader,this.components,b),rt="api"in Z;if(rt){const{api:Ut}=Z;this.configApi=Ut}if("node"in Z)return Z.node;if(rt&&l.current){l.current=!1;const Ut=this.getApiHolder().get(xn.B);if(Ut){for(const oe of this.featureFlags)Ut.registerFlag({...oe,pluginId:""});for(const oe of this.plugins.values())if("getFeatureFlags"in oe)for(const Ie of oe.getFeatureFlags())Ut.registerFlag({name:Ie.name,pluginId:oe.getId()});else for(const Ie of oe.output())Ie.type==="feature-flag"&&Ut.registerFlag({name:Ie.name,pluginId:oe.getId()});const Kt=Ut.getRegisteredFlags(),me=new Set(Kt.map(oe=>oe.name));for(const oe of B)me.has(oe)||Ut.registerFlag({name:oe,pluginId:""})}}const{ThemeProvider:et=Tr,Progress:ct}=this.components,At=this.getApiHolder();if(di()){const Ut=At.get(Gt.m),Kt=At.get(Yt.a),me=At.get(jt.I);if(!Ut||!Kt||!me)throw new Error("App is running in protected mode but missing required APIs");this.appIdentityProxy.enableCookieAuth({errorApi:Ut,fetchApi:Kt,discoveryApi:me})}return(0,i.jsx)(Zo,{apis:At,children:(0,i.jsx)(Ks,{appContext:e,children:(0,i.jsx)(et,{children:(0,i.jsx)(Fs,{routePaths:E.paths,routeParents:E.parents,routeObjects:E.objects,routeBindings:k,basePath:ri(Z.api),children:(0,i.jsx)(Ir.Provider,{value:{routeObjects:E.objects,appIdentityProxy:this.appIdentityProxy},children:(0,i.jsx)(d.Suspense,{fallback:(0,i.jsx)(ct,{}),children:a})})})})})})}}getRouter(){return Br}getApiHolder(){if(this.apiHolder){for(const e of this.plugins)for(const n of e.getApis())this.apiFactoryRegistry.get(n.api)||this.apiFactoryRegistry.register("default",n);return qo.validateFactories(this.apiFactoryRegistry,this.apiFactoryRegistry.getAllApis()),this.apiHolder}this.apiFactoryRegistry.register("static",{api:co,deps:{},factory:()=>lo.createWithStorage(this.themes)}),this.apiFactoryRegistry.register("static",{api:$t.U,deps:{},factory:()=>{if(!this.configApi)throw new Error("Tried to access config API before config was loaded");return this.configApi}}),this.apiFactoryRegistry.register("static",{api:se.K,deps:{},factory:()=>this.appIdentityProxy}),this.apiFactoryRegistry.register("static",{api:Er,deps:{},factory:()=>this.appLanguageApi}),this.apiFactoryRegistry.register("default",{api:xs.J,deps:{languageApi:Er},factory:({languageApi:e})=>ir.create({languageApi:e,resources:this.translationResources})}),this.apiFactoryRegistry.register("default",{api:xn.B,deps:{},factory:()=>new As});for(const e of this.defaultApis)this.apiFactoryRegistry.register("default",e);for(const e of this.plugins)for(const n of e.getApis())if(!this.apiFactoryRegistry.register("default",n))throw new Error(`Plugin ${e.getId()} tried to register duplicate or forbidden API factory for ${n.api}`);for(const e of this.apis)if(!this.apiFactoryRegistry.register("app",e))throw new Error(`Duplicate or forbidden API factory for ${e.api} in app`);return qo.validateFactories(this.apiFactoryRegistry,this.apiFactoryRegistry.getAllApis()),this.apiHolder=new qo(this.apiFactoryRegistry),this.apiHolder}verifyPlugins(e){const n=new Set;for(const s of e){const a=s.getId();if(n.has(a))throw new Error(`Duplicate plugin found '${a}'`);n.add(a)}}constructor(e){var n,s,a;(0,x._)(this,"apiHolder",void 0),(0,x._)(this,"configApi",void 0),(0,x._)(this,"apis",void 0),(0,x._)(this,"icons",void 0),(0,x._)(this,"plugins",void 0),(0,x._)(this,"featureFlags",void 0),(0,x._)(this,"components",void 0),(0,x._)(this,"themes",void 0),(0,x._)(this,"configLoader",void 0),(0,x._)(this,"defaultApis",void 0),(0,x._)(this,"bindRoutes",void 0),(0,x._)(this,"appLanguageApi",void 0),(0,x._)(this,"translationResources",void 0),(0,x._)(this,"appIdentityProxy",new Ys),(0,x._)(this,"apiFactoryRegistry",void 0),(0,fe._)(this,lr,{writable:!0,value:!1});var l;this.apis=(l=e.apis)!==null&&l!==void 0?l:[],this.icons=e.icons;var b;this.plugins=new Set((b=e.plugins)!==null&&b!==void 0?b:[]);var E;this.featureFlags=(E=e.featureFlags)!==null&&E!==void 0?E:[],this.components=e.components,this.themes=e.themes;var B;this.configLoader=(B=e.configLoader)!==null&&B!==void 0?B:Rr;var k;this.defaultApis=(k=e.defaultApis)!==null&&k!==void 0?k:[],this.bindRoutes=e.bindRoutes,this.apiFactoryRegistry=new Cs,this.appLanguageApi=yo.createWithStorage({defaultLanguage:(n=e.__experimentalTranslations)===null||n===void 0?void 0:n.defaultLanguage,availableLanguages:(s=e.__experimentalTranslations)===null||s===void 0?void 0:s.availableLanguages});var Z;this.translationResources=(Z=(a=e.__experimentalTranslations)===null||a===void 0?void 0:a.resources)!==null&&Z!==void 0?Z:[]}}function pi(r){return new fi(r)}function gi(r){var e,n,s,a;return pi({...r,apis:(e=r==null?void 0:r.apis)!==null&&e!==void 0?e:[],bindRoutes:r==null?void 0:r.bindRoutes,components:{...R,...r==null?void 0:r.components},configLoader:r==null?void 0:r.configLoader,defaultApis:Lo,icons:{...oo,...r==null?void 0:r.icons},plugins:(n=r==null?void 0:r.plugins)!==null&&n!==void 0?n:[],featureFlags:(s=r==null?void 0:r.featureFlags)!==null&&s!==void 0?s:[],themes:(a=r==null?void 0:r.themes)!==null&&a!==void 0?a:ie})}var bo=t(82442);let Wr=!1;const kr=r=>{const e=(0,Dr.n)(),{NotFoundErrorPage:n}=e.getComponents(),s=(0,d.useMemo)(()=>Vn(),[]),l=[...(0,bo.O)(r.children,b=>b.getElements().flatMap(E=>{let B=E.props.path;if(B==="")return[];var k;B=(k=B==null?void 0:B.replace(/\/\*$/,""))!==null&&k!==void 0?k:"/";let Z=s?E:E.props.element;return!s&&!Z&&(Z=E,Wr||(console.warn("DEPRECATION WARNING: All elements within <FlatRoutes> must be of type <Route> with an element prop. Existing usages of <Navigate key=[path] to=[to] /> should be replaced with <Route path=[path] element={<Navigate to=[to] />} />."),Wr=!0)),[{path:B,element:Z,children:E.props.children?[{path:B==="/"?"/":"*",element:E.props.children}]:void 0}]}).sort((E,B)=>B.path.localeCompare(E.path)).map(E=>({...E,path:E.path==="/"?"/":`${E.path}/*`}))),{path:"*",element:(0,i.jsx)(n,{})}];return(0,m.Ye)(l)};(0,Pe.h)(kr,"core.type","FlatRoutes");var rn=t(6820),vi=t(78692),mi=t(86519);function Kr(r){return!r.cursor}function Ga(r){return!Kr(r)}const Se="catalog";var Oe=t(94214);class yi{async analyzeLocation(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/analyze-location").expand({});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"POST",body:JSON.stringify(e.body)})}async createLocation(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/locations{?dryRun}").expand({...e.query});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"POST",body:JSON.stringify(e.body)})}async deleteEntityByUid(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities/by-uid/{uid}").expand({uid:e.path.uid});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"DELETE"})}async deleteLocation(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/locations/{id}").expand({id:e.path.id});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"DELETE"})}async getEntities(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities{?fields,limit,filter*,offset,after,order*}").expand({...e.query});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getEntitiesByQuery(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities/by-query{?fields,limit,orderField*,cursor,filter*,fullTextFilterTerm,fullTextFilterFields}").expand({...e.query});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getEntitiesByRefs(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities/by-refs/{?filter*}").expand({...e.query});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"POST",body:JSON.stringify(e.body)})}async getEntityAncestryByName(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities/by-name/{kind}/{namespace}/{name}/ancestry").expand({kind:e.path.kind,namespace:e.path.namespace,name:e.path.name});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getEntityByName(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities/by-name/{kind}/{namespace}/{name}").expand({kind:e.path.kind,namespace:e.path.namespace,name:e.path.name});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getEntityByUid(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entities/by-uid/{uid}").expand({uid:e.path.uid});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getEntityFacets(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/entity-facets{?facet*,filter*}").expand({...e.query});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getLocation(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/locations/{id}").expand({id:e.path.id});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getLocationByEntity(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/locations/by-entity/{kind}/{namespace}/{name}").expand({kind:e.path.kind,namespace:e.path.namespace,name:e.path.name});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async getLocations(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/locations").expand({});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"GET"})}async refreshEntity(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/refresh").expand({});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"POST",body:JSON.stringify(e.body)})}async validateEntity(e,n){const s=await this.discoveryApi.getBaseUrl(Se),l=Oe.parse("/validate-entity").expand({});return await this.fetchApi.fetch(`${s}${l}`,{headers:{"Content-Type":"application/json",...(n==null?void 0:n.token)&&{Authorization:`Bearer ${n==null?void 0:n.token}`}},method:"POST",body:JSON.stringify(e.body)})}constructor(e){(0,x._)(this,"discoveryApi",void 0),(0,x._)(this,"fetchApi",void 0),this.discoveryApi=e.discoveryApi,this.fetchApi=e.fetchApi||{fetch:fn()}}}class Ei{async getEntityAncestors(e,n){return await this.requestRequired(await this.apiClient.getEntityAncestryByName({path:(0,rn.KU)(e.entityRef)},n))}async getLocationById(e,n){return await this.requestOptional(await this.apiClient.getLocation({path:{id:e}},n))}async getLocationByEntity(e,n){return await this.requestOptional(await this.apiClient.getLocationByEntity({path:(0,rn.KU)(e)},n))}async getEntities(e,n){const{filter:s=[],fields:a=[],order:l,offset:b,limit:E,after:B}=e!=null?e:{},k=[];if(l)for(const et of[l].flat())et&&k.push(`${et.order}:${et.field}`);const Z=await this.requestRequired(await this.apiClient.getEntities({query:{fields:a,limit:E,filter:this.getFilterValue(s),offset:b,after:B,order:l?k:void 0}},n));if(k.length)return{items:Z};const rt=(et,ct)=>{var At,Ut;if(((At=et.metadata)===null||At===void 0?void 0:At.name)===void 0||et.kind===void 0||((Ut=ct.metadata)===null||Ut===void 0?void 0:Ut.name)===void 0||ct.kind===void 0)return 0;const Kt=(0,rn.U2)(et),me=(0,rn.U2)(ct);return Kt<me?-1:Kt>me?1:0};return{items:Z.sort(rt)}}async getEntitiesByRefs(e,n){const s=await this.apiClient.getEntitiesByRefs({body:{entityRefs:e.entityRefs,fields:e.fields},query:{filter:this.getFilterValue(e.filter)}},n);if(!s.ok)throw await be.o.fromResponse(s);const{items:a}=await s.json();return{items:a.map(l=>l!=null?l:void 0)}}async queryEntities(e={},n){const s={};if(Kr(e)){var a,l;const{fields:b=[],filter:E,limit:B,orderFields:k,fullTextFilter:Z}=e;s.filter=this.getFilterValue(E),B!==void 0&&(s.limit=B),k!==void 0&&(s.orderField=(Array.isArray(k)?k:[k]).map(({field:et,order:ct})=>`${et},${ct}`)),b.length&&(s.fields=b);const rt=Z==null||(a=Z.term)===null||a===void 0?void 0:a.trim();rt&&(s.fullTextFilterTerm=rt),!(Z==null||(l=Z.fields)===null||l===void 0)&&l.length&&(s.fullTextFilterFields=Z.fields)}else{const{fields:b=[],limit:E,cursor:B}=e;s.cursor=B,E!==void 0&&(s.limit=E),b.length&&(s.fields=b)}return this.apiClient.getEntitiesByQuery({query:s},n).then(b=>b.json())}async getEntityByRef(e,n){return this.requestOptional(await this.apiClient.getEntityByName({path:(0,rn.KU)(e)},n))}async getEntityByName(e,n){const{kind:s,namespace:a="default",name:l}=e;return this.requestOptional(await this.apiClient.getEntityByName({path:{kind:s,namespace:a,name:l}},n))}async refreshEntity(e,n){const s=await this.apiClient.refreshEntity({body:{entityRef:e}},n);if(s.status!==200)throw new Error(await s.text())}async getEntityFacets(e,n){const{filter:s=[],facets:a}=e;return await this.requestOptional(await this.apiClient.getEntityFacets({query:{facet:a,filter:this.getFilterValue(s)}},n))}async addLocation(e,n){const{type:s="url",target:a,dryRun:l}=e,b=await this.apiClient.createLocation({body:{type:s,target:a},query:{dryRun:l?"true":void 0}},n);if(b.status!==201)throw new Error(await b.text());const{location:E,entities:B,exists:k}=await b.json();if(!E)throw new Error(`Location wasn't added: ${a}`);return{location:E,entities:B,exists:k}}async getLocationByRef(e,n){return(await this.requestRequired(await this.apiClient.getLocations({},n))).map(a=>a.data).find(a=>e===(0,vi.KL)(a))}async removeLocationById(e,n){await this.requestIgnored(await this.apiClient.deleteLocation({path:{id:e}},n))}async removeEntityByUid(e,n){await this.requestIgnored(await this.apiClient.deleteEntityByUid({path:{uid:e}},n))}async validateEntity(e,n,s){const a=await this.apiClient.validateEntity({body:{entity:e,location:n}},s);if(a.ok)return{valid:!0};if(a.status!==400)throw await be.o.fromResponse(a);const{errors:l=[]}=await a.json();return{valid:!1,errors:l}}async requestIgnored(e){if(!e.ok)throw await be.o.fromResponse(e)}async requestRequired(e){if(!e.ok)throw await be.o.fromResponse(e);return e.json()}async requestOptional(e){if(!e.ok){if(e.status===404)return;throw await be.o.fromResponse(e)}return await e.json()}getFilterValue(e=[]){const n=[];for(const s of[e].flat()){const a=[];for(const[l,b]of Object.entries(s))for(const E of[b].flat())E===mi.c?a.push(l):typeof E=="string"&&a.push(`${l}=${E}`);a.length&&n.push(a.join(","))}return n}constructor(e){(0,x._)(this,"apiClient",void 0),this.apiClient=new yi(e)}}var zr=t(7341),Ai=t(18),xi=t(82292),Hr=t(29207),Pn=t(95203),Ci=t(9803),je=t(88758),bi=t(54560),Tn=t(45250);async function Si({storageApi:r}){const e=r.forBucket("settings"),n=r.forBucket("starredEntities"),s=e.snapshot("starredEntities").value;if(!(0,Tn.isArray)(s))return;var a;const l=new Set((a=n.snapshot("entityRefs").value)!==null&&a!==void 0?a:[]);s.filter(Tn.isString).map(b=>b.split(":")).filter(b=>b.length===4&&b[0]==="entity").map(([b,E,B,k])=>(0,rn.U2)({kind:E,namespace:B,name:k})).forEach(b=>l.add(b)),await n.set("entityRefs",Array.from(l)),await e.remove("starredEntities")}class Oi{async toggleStarred(e){this.starredEntities.has(e)?this.starredEntities.delete(e):this.starredEntities.add(e),await this.settingsStore.set("entityRefs",Array.from(this.starredEntities))}starredEntitie$(){return this.observable}notifyChanges(){for(const e of this.subscribers)e.next(new Set(this.starredEntities))}constructor(e){(0,x._)(this,"settingsStore",void 0),(0,x._)(this,"starredEntities",void 0),(0,x._)(this,"subscribers",new Set),(0,x._)(this,"observable",new(K())(s=>(s.next(new Set(this.starredEntities)),this.subscribers.add(s),()=>{this.subscribers.delete(s)}))),Si(e).then(),this.settingsStore=e.storageApi.forBucket("starredEntities");var n;this.starredEntities=new Set((n=this.settingsStore.snapshot("entityRefs").value)!==null&&n!==void 0?n:[]),this.settingsStore.observe$("entityRefs").subscribe({next:s=>{var a;this.starredEntities=new Set((a=s.value)!==null&&a!==void 0?a:[]),this.notifyChanges()}})}}function cr(r){const{years:e=0,months:n=0,weeks:s=0,days:a=0,hours:l=0,minutes:b=0,seconds:E=0,milliseconds:B=0}=r;return((((e*365+n*30+s*7+a)*24+l)*60+b)*60+E)*1e3+B}var wi=t(25033),Pi=t.n(wi),Ti=t(25295),Ri=t.n(Ti),Ii=t(88083);const Di={seconds:10},Mi={milliseconds:50},Li={api:Xn.A,component:to.A,system:Jn.A,resource:eo.A,domain:Mn.A,location:qn.A,user:jn.A,group:Bn.A,template:no.A};function _r(r){return{async:r.async,render:({entityRef:e,entity:n,context:s})=>({snapshot:(0,Ii.T)(n||e,s),loadEntity:r.async})}}var So=new WeakMap,dr=new WeakMap,Oo=new WeakMap,ur=new WeakMap,wo=new WeakMap,Vr=new WeakSet,Gr=new WeakSet,Yr=new WeakSet;class Po{static createLocal(){return new Po({renderer:_r({async:!1})})}static create(e){return new Po(e)}forEntity(e,n){const{entityRef:s,kind:a,entity:l,needsLoad:b}=(0,We._)(this,Vr,Bi).call(this,e),E=et=>{const{snapshot:ct}=(0,Dt._)(this,wo).render({entityRef:s,loading:et.loading,entity:et.entity,context:n||{}});return{...ct,entityRef:s,Icon:(0,We._)(this,Yr,Ui).call(this,ct.Icon,a)}};let B;try{B=E({loading:b,entity:l})}catch{B={primaryTitle:s,entityRef:s}}if(!b)return{snapshot:B,promise:Promise.resolve(B)};const k=Promise.resolve().then(()=>{var et;return(et=(0,Dt._)(this,Oo))===null||et===void 0?void 0:et.load(s)}).then(et=>E({loading:!1,entity:et!=null?et:l})).catch(()=>{}),Z=new(K())(et=>{let ct=!1;return k.then(At=>{At&&et.next(At)}).finally(()=>{ct||et.complete()}),()=>{ct=!0}}),rt=k.then(et=>et!=null?et:B);return{snapshot:B,update$:Z,promise:rt}}constructor(e){(0,pn._)(this,Vr),(0,pn._)(this,Gr),(0,pn._)(this,Yr),(0,fe._)(this,So,{writable:!0,value:void 0}),(0,fe._)(this,dr,{writable:!0,value:void 0}),(0,fe._)(this,Oo,{writable:!0,value:void 0}),(0,fe._)(this,ur,{writable:!0,value:void 0}),(0,fe._)(this,wo,{writable:!0,value:void 0});var n;const s=(n=e.cacheTtl)!==null&&n!==void 0?n:Di;var a;const l=(a=e.batchDelay)!==null&&a!==void 0?a:Mi;var b;const E=(b=e.renderer)!==null&&b!==void 0?b:_r({async:!0}),B={};Object.entries(Li).forEach(([Z,rt])=>{B[Z.toLocaleLowerCase("en-US")]=rt});var k;if(Object.entries((k=e.kindIcons)!==null&&k!==void 0?k:{}).forEach(([Z,rt])=>{B[Z.toLocaleLowerCase("en-US")]=rt}),E.async){if(!e.catalogApi)throw new TypeError("Asynchronous rendering requires a catalog API");(0,p._)(this,Oo,(0,We._)(this,Gr,ji).call(this,{cacheTtl:s,batchDelay:l,renderer:E,catalogApi:e.catalogApi}))}(0,p._)(this,dr,cr(s)),(0,p._)(this,So,new Map),(0,p._)(this,ur,B),(0,p._)(this,wo,E)}}function Bi(r){if(typeof r!="string")return{entity:r,kind:r.kind,entityRef:(0,rn.U2)(r),needsLoad:!1};const e=(0,Dt._)(this,So).get(r),n=e==null?void 0:e.entity,a=(!e||Date.now()-e.updatedAt>(0,Dt._)(this,dr))&&(0,Dt._)(this,wo).async!==!1&&(0,Dt._)(this,Oo)!==void 0;return{entity:n,kind:(0,rn.KU)(r).kind,entityRef:r,needsLoad:a}}function ji(r){const e=cr(r.cacheTtl),n=cr(r.batchDelay);return new(Pi())(async s=>{const{items:a}=await r.catalogApi.getEntitiesByRefs({entityRefs:s}),l=Date.now();return s.forEach((b,E)=>{(0,Dt._)(this,So).set(b,{updatedAt:l,entity:a[E]})}),a},{name:"DefaultEntityPresentationApi",cacheMap:new(Ri())(e),maxBatchSize:100,batchScheduleFn:n?s=>setTimeout(s,n):void 0})}function Ui(r,e){return r||(r===!1?!1:(0,Dt._)(this,ur)[e.toLocaleLowerCase("en-US")])}const Re=(0,Ci.i)({id:"catalog",apis:[(0,ut.b)({api:zr.v,deps:{discoveryApi:jt.I,fetchApi:Yt.a},factory:({discoveryApi:r,fetchApi:e})=>new Ei({discoveryApi:r,fetchApi:e})}),(0,ut.b)({api:Ai.a,deps:{storageApi:ee},factory:({storageApi:r})=>new Oi({storageApi:r})}),(0,ut.b)({api:xi.n,deps:{catalogApi:zr.v},factory:({catalogApi:r})=>Po.create({catalogApi:r})})],routes:{catalogIndex:Pn.rQ,catalogEntity:Hr.s},externalRoutes:{createComponent:Pn.qP,viewTechDoc:Pn.UJ,createFromTemplate:Pn.Zg,unregisterRedirect:Pn.pS}}),Ya=Re.provide((0,je.QJ)({name:"CatalogIndexPage",component:()=>Promise.all([t.e(3720),t.e(4919),t.e(5974)]).then(t.bind(t,5974)).then(r=>r.CatalogPage),mountPoint:Pn.rQ})),$i=Re.provide((0,je.QJ)({name:"CatalogEntityPage",component:()=>t.e(4516).then(t.bind(t,54516)).then(r=>r.CatalogEntityPage),mountPoint:Hr.s})),Qa=Re.provide((0,je.NC)({name:"EntityAboutCard",component:{lazy:()=>Promise.all([t.e(3720),t.e(1902),t.e(73)]).then(t.bind(t,40073)).then(r=>r.AboutCard)}})),Za=Re.provide((0,je.NC)({name:"EntityLinksCard",component:{lazy:()=>t.e(8307).then(t.bind(t,18307)).then(r=>r.EntityLinksCard)}})),Ja=Re.provide((0,je.NC)({name:"EntityLabelsCard",component:{lazy:()=>t.e(3182).then(t.bind(t,63182)).then(r=>r.EntityLabelsCard)}})),Xa=Re.provide((0,je.NC)({name:"EntityHasSystemsCard",component:{lazy:()=>t.e(9652).then(t.bind(t,9652)).then(r=>r.HasSystemsCard)}})),qa=Re.provide((0,je.NC)({name:"EntityHasComponentsCard",component:{lazy:()=>t.e(2420).then(t.bind(t,52420)).then(r=>r.HasComponentsCard)}})),tl=Re.provide((0,je.NC)({name:"EntityHasSubcomponentsCard",component:{lazy:()=>t.e(8384).then(t.bind(t,78384)).then(r=>r.HasSubcomponentsCard)}})),el=Re.provide((0,je.NC)({name:"EntityHasResourcesCard",component:{lazy:()=>t.e(6271).then(t.bind(t,56271)).then(r=>r.HasResourcesCard)}})),nl=Re.provide((0,je.NC)({name:"EntityDependsOnComponentsCard",component:{lazy:()=>t.e(3632).then(t.bind(t,3632)).then(r=>r.DependsOnComponentsCard)}})),ol=Re.provide((0,je.NC)({name:"EntityDependencyOfComponentsCard",component:{lazy:()=>t.e(124).then(t.bind(t,124)).then(r=>r.DependencyOfComponentsCard)}})),rl=Re.provide((0,je.NC)({name:"EntityDependsOnResourcesCard",component:{lazy:()=>t.e(287).then(t.bind(t,20287)).then(r=>r.DependsOnResourcesCard)}})),sl=Re.provide((0,je.NC)({name:"RelatedEntitiesCard",component:{lazy:()=>t.e(2401).then(t.bind(t,52401)).then(r=>r.RelatedEntitiesCard)}})),il=Re.provide((0,bi.ec)({name:"CatalogSearchResultListItem",component:()=>t.e(1297).then(t.bind(t,61297)).then(r=>r.CatalogSearchResultListItem),predicate:r=>r.type==="software-catalog"}));var Qr=t(3347),Zr=t(26679);class Fi{async getApiOrigin(){return await this.discoveryApi.getBaseUrl("techdocs")}async getStorageUrl(){return`${await this.discoveryApi.getBaseUrl("techdocs")}/static/docs`}async getBuilder(){return this.configApi.getOptionalString("techdocs.builder")||"local"}async getEntityDocs(e,n){const a=`${await this.getApiOrigin()}/${n}`,l=await fetch(`${a.endsWith("/")?a:`${a}/`}index.html`);if(l.status===404)throw new Error("Page not found");return l.text()}async syncEntityDocs(e){return"cached"}async getBaseUrl(e,n,s){const a=await this.getApiOrigin();return new URL(e,`${a}/${s}`).toString()}constructor({configApi:e,discoveryApi:n,identityApi:s}){(0,x._)(this,"configApi",void 0),(0,x._)(this,"discoveryApi",void 0),(0,x._)(this,"identityApi",void 0),this.configApi=e,this.discoveryApi=n,this.identityApi=s}}class Ni{async getCookie(){return{expiresAt:new Date(Date.now()+6e5).toISOString()}}async getApiOrigin(){return await this.discoveryApi.getBaseUrl("techdocs")}async getEntityMetadata(e){return{apiVersion:"backstage.io/v1alpha1",kind:"Component",metadata:{name:"local"},spec:{owner:"test",lifecycle:"experimental"}}}async getTechDocsMetadata(e){return{site_name:"Live preview environment",site_description:""}}constructor({configApi:e,discoveryApi:n,identityApi:s}){(0,x._)(this,"configApi",void 0),(0,x._)(this,"discoveryApi",void 0),(0,x._)(this,"identityApi",void 0),this.configApi=e,this.discoveryApi=n,this.identityApi=s}}const Wi=[(0,ut.b)({api:Zr.s,deps:{configApi:$t.U,discoveryApi:jt.I,identityApi:se.K},factory:({configApi:r,discoveryApi:e,identityApi:n})=>new Fi({configApi:r,discoveryApi:e,identityApi:n})}),(0,ut.b)({api:Zr.l,deps:{configApi:$t.U,discoveryApi:jt.I,identityApi:se.K},factory:({configApi:r,discoveryApi:e,identityApi:n})=>new Ni({configApi:r,discoveryApi:e,identityApi:n})}),(0,ut.b)({api:Qr.Y,deps:{configApi:$t.U},factory:({configApi:r})=>Qr.L.fromConfig(r)})],ki={backend:{baseUrl:"http://localhost:3000"},techdocs:{builder:"external"}},Ki={backend:{baseUrl:"http://localhost:7007"},techdocs:{builder:"external"}};async function zi(){const r=await fetch("/.detect");return r.ok?(await r.text()).trim()==="techdocs-cli-server":!1}async function Hi(){const r=await Rr(),e=await zi();return[...r,{context:"detected",data:e?ki:Ki}]}var Xe=t(58837),_i=t(3210);const Vi=(0,Xe.A)({svg:{width:"auto",height:30},path:{fill:"#7df3e1"}});var Gi=()=>{const r=Vi();return(0,i.jsx)("svg",{className:r.svg,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 2079.95 456.05",children:(0,i.jsx)("path",{className:r.path,d:"M302.9,180a80.62,80.62,0,0,0,13.44-10.37c.8-.77,1.55-1.54,2.31-2.31a81.89,81.89,0,0,0,7.92-9.37,62.37,62.37,0,0,0,6.27-10.77,48.6,48.6,0,0,0,4.36-16.4c1.49-19.39-10-38.67-35.62-54.22L198.42,14,78.16,129.22l-78.29,75,108.6,65.9a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.8,66.42-25.69,19.16-18.36,25.52-42.12,13.7-61.87a49.69,49.69,0,0,0-6.8-8.87,89.78,89.78,0,0,0,19.28,2.15H259a85.09,85.09,0,0,0,31-5.79A80.88,80.88,0,0,0,302.9,180Zm-100.59,59.8c-19.32,18.51-50.4,21.24-75.7,5.9l-75.13-45.6,67.44-64.65,76.42,46.39C222.88,198.57,221.36,221.6,202.31,239.84Zm8.94-82.21L140.6,114.74,205,53l69.37,42.11c25.94,15.73,29.31,37.05,10.55,55A60.71,60.71,0,0,1,211.25,157.63Zm29.86,190c-19.57,18.75-46.17,29.08-74.88,29.08a123.84,123.84,0,0,1-64.11-18.19L-.13,296.51v24.67l108.6,65.91a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.81,66.42-25.69,12.88-12.34,20-27.13,19.68-41.49v-1.79A87.85,87.85,0,0,1,241.11,347.67Zm0-39c-19.57,18.76-46.17,29.09-74.88,29.09a123.84,123.84,0,0,1-64.11-18.19L-.13,257.52V282.2l108.6,65.91a111.59,111.59,0,0,0,57.76,16.41c24.92,0,48.8-8.8,66.42-25.68,12.88-12.35,20-27.13,19.68-41.5v-1.79A86.86,86.86,0,0,1,241.11,308.68Zm0-39c-19.57,18.76-46.17,29.09-74.88,29.09a123.84,123.84,0,0,1-64.11-18.19L-.13,218.54v24.68l108.6,65.91a111.59,111.59,0,0,0,57.76,16.41c24.92,0,48.8-8.8,66.42-25.69,12.88-12.34,20-27.12,19.68-41.49v-1.82A87.14,87.14,0,0,1,241.11,269.7Zm83.69,25.74a94.16,94.16,0,0,1-60.19,25.86h0V348a81.6,81.6,0,0,0,51.73-22.37c14-13.38,21.15-28.11,21-42.64v-2.2A95.14,95.14,0,0,1,324.8,295.44Zm-83.69,91.21c-19.57,18.75-46.17,29.09-74.88,29.09a123.76,123.76,0,0,1-64.11-18.2L-.13,335.49v24.67l108.6,65.91a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.81,66.42-25.69,12.88-12.34,20-27.13,19.68-41.49v-1.79A87.35,87.35,0,0,1,241.11,386.65Zm85.75-210.21c-.68.69-1.35,1.38-2.06,2.05a99.19,99.19,0,0,1-22.23,15.69,94.53,94.53,0,0,1-26.24,8.71,97.84,97.84,0,0,1-14.16,1.57c.5,1.61.9,3.25,1.25,4.9a52.7,52.7,0,0,1,1.13,12V231h.05A84.48,84.48,0,0,0,290,225.47a80.83,80.83,0,0,0,26.38-16.82c.81-.77,1.51-1.56,2.27-2.34a82,82,0,0,0,7.92-9.38,62.85,62.85,0,0,0,6.29-10.78,48.5,48.5,0,0,0,4.32-16.44c.09-1.23.2-2.47.19-3.7v-2c-.72,1-1.48,2.06-2.26,3.09A98,98,0,0,1,326.86,176.44Zm0,77.92c-.68.7-1.3,1.41-2,2.1a94.09,94.09,0,0,1-60.19,25.85h0V309h0a81.65,81.65,0,0,0,51.73-22.37,73.51,73.51,0,0,0,16.48-22.49,48.56,48.56,0,0,0,4.32-16.44c.09-1.24.2-2.48.19-3.71v-2.2c-.74,1.08-1.47,2.16-2.27,3.22A95.81,95.81,0,0,1,326.82,254.36Zm0-39c-.68.7-1.3,1.41-2,2.1a92.22,92.22,0,0,1-10.62,8.65,93.53,93.53,0,0,1-11.63,7,95.63,95.63,0,0,1-37.94,10.18h-.05l0,26.67h0a81.63,81.63,0,0,0,51.73-22.37c.81-.77,1.51-1.56,2.27-2.34a82,82,0,0,0,7.92-9.38,63.16,63.16,0,0,0,6.29-10.77,48.55,48.55,0,0,0,4.32-16.45c.09-1.23.2-2.47.19-3.7v-2.2c-.74,1.08-1.47,2.16-2.27,3.22A98.19,98.19,0,0,1,326.82,215.38Zm241-88.84q7.94,0,17.09.17t18.12,1a139.3,139.3,0,0,1,16.74,2.57,42.78,42.78,0,0,1,13.3,5.14,64.27,64.27,0,0,1,20.54,19.89Q662,168,662,186.54q0,19.54-9.49,33.78t-27.1,21.09v.68q22.78,4.82,34.87,20.58t12.08,38.4a72.62,72.62,0,0,1-4.83,26.06,65.29,65.29,0,0,1-14.33,22.46,71.57,71.57,0,0,1-23.47,15.78q-14,6-32.28,6H478.38V126.54Zm9,105.27q28,0,40.21-9.78t12.26-29.31q0-13-4.14-20.58a29.47,29.47,0,0,0-11.4-11.66A45,45,0,0,0,597,155.17a161.2,161.2,0,0,0-20.19-1.2h-65.6v77.84Zm16.57,112.13q21.74,0,34-11.66T639.59,300q0-12-4.48-19.88a34.85,34.85,0,0,0-11.91-12.52,50.14,50.14,0,0,0-17.09-6.52,105,105,0,0,0-20-1.88H511.17v84.7Zm274.79,26.74q-7.61,4.45-21.06,4.46-11.4,0-18.12-6.34t-6.74-20.75a70.17,70.17,0,0,1-28.13,20.75,97.87,97.87,0,0,1-57.65,3.6,53.51,53.51,0,0,1-18.82-8.58A41.19,41.19,0,0,1,705,348.56q-4.65-9.42-4.66-22.8,0-15.09,5.18-24.69a44.92,44.92,0,0,1,13.64-15.6,62.63,62.63,0,0,1,19.33-9.09q10.88-3.08,22.27-5.14,12.08-2.4,23-3.6a128,128,0,0,0,19.16-3.43c5.53-1.48,9.89-3.65,13.12-6.51s4.83-7,4.83-12.52q0-9.6-3.62-15.43a24.94,24.94,0,0,0-9.32-8.92,38.38,38.38,0,0,0-12.78-4.11,96.54,96.54,0,0,0-14-1q-18.63,0-31.07,7T736.6,249.29H707.26q.69-16.46,6.9-27.77a52.21,52.21,0,0,1,16.57-18.35,70,70,0,0,1,23.65-10.11A125.51,125.51,0,0,1,782.86,190a168.63,168.63,0,0,1,24,1.72,63.26,63.26,0,0,1,21.58,7A41.23,41.23,0,0,1,844,213.59q5.87,9.57,5.87,25v91q0,10.26,1.21,15.05t8.11,4.79a35.57,35.57,0,0,0,9-1.37Zm-47.64-90.87c-3.69,2.74-8.52,4.72-14.5,6s-12.26,2.27-18.82,3.07-13.17,1.71-19.85,2.73a73.7,73.7,0,0,0-18,4.94,32.62,32.62,0,0,0-12.94,9.73q-5,6.32-5,17.23a23.31,23.31,0,0,0,2.94,12.11,24.11,24.11,0,0,0,7.59,8,32,32,0,0,0,10.88,4.44,60.94,60.94,0,0,0,13.11,1.36q14.5,0,24.86-3.92a52.49,52.49,0,0,0,16.91-9.9,39.1,39.1,0,0,0,9.67-13,32.53,32.53,0,0,0,3.11-13.14ZM1002.07,225q-11.05-9.25-29.69-9.26-15.89,0-26.58,5.83A47.29,47.29,0,0,0,928.71,237a64.66,64.66,0,0,0-9.15,22.12A119.83,119.83,0,0,0,916.8,285a98.22,98.22,0,0,0,2.93,24,64.18,64.18,0,0,0,9.15,20.74,46.2,46.2,0,0,0,16.23,14.58q10,5.49,23.82,5.48,21.75,0,34-11.31t15-31.89h30q-4.83,32.91-24.68,50.75t-54,17.83q-20.37,0-36.07-6.52A69.86,69.86,0,0,1,907,350.11a79.92,79.92,0,0,1-15.88-28.63A118.64,118.64,0,0,1,885.73,285a129.41,129.41,0,0,1,5.18-37.21,85.63,85.63,0,0,1,15.71-30.17A73.46,73.46,0,0,1,933,197.35Q948.91,190,970,190a108.54,108.54,0,0,1,28.48,3.6,69.59,69.59,0,0,1,23.48,11.15,61,61,0,0,1,16.74,19q6.55,11.49,8.29,27.26h-30.38Q1013.11,234.21,1002.07,225Zm109.77-98.41v145l81.47-77.49h39.36l-70.77,64.46,75.95,112.82h-37.29l-61.1-92.59-27.62,25.38v67.21H1082.5V126.54Zm170.54,205.22a31.07,31.07,0,0,0,10.87,10.63,49,49,0,0,0,15.19,5.66,87.06,87.06,0,0,0,17.44,1.71,109.18,109.18,0,0,0,14.5-1,53.22,53.22,0,0,0,14-3.78,26.27,26.27,0,0,0,10.53-8q4.14-5.32,4.14-13.55,0-11.31-8.63-17.14a73.69,73.69,0,0,0-21.58-9.43q-12.94-3.6-28.13-6.52a146,146,0,0,1-28.14-8.23A58.16,58.16,0,0,1,1261,267.13q-8.64-9.6-8.63-26.75,0-13.38,6-23a49.26,49.26,0,0,1,15.53-15.61,71.76,71.76,0,0,1,21.4-8.91A99.41,99.41,0,0,1,1319,190a141.31,141.31,0,0,1,28,2.58,64.85,64.85,0,0,1,22.62,8.91,46.16,46.16,0,0,1,15.7,17.15q5.87,10.8,6.91,26.91h-29.35q-.69-8.57-4.48-14.23a29.36,29.36,0,0,0-9.67-9.08,44.16,44.16,0,0,0-12.94-5,67.68,67.68,0,0,0-14.33-1.54,87.29,87.29,0,0,0-13.29,1,45.28,45.28,0,0,0-12.26,3.6,24.49,24.49,0,0,0-9,6.86q-3.46,4.29-3.46,11.14a16.32,16.32,0,0,0,5.36,12.52,42.75,42.75,0,0,0,13.63,8.23,120,120,0,0,0,18.64,5.48q10.37,2.24,20.72,4.63,11,2.4,21.57,5.83A70.74,70.74,0,0,1,1382,284.1a44.55,44.55,0,0,1,13.12,14.23q5,8.58,5,21.26,0,16.13-6.73,26.75a52.5,52.5,0,0,1-17.61,17.14,73.89,73.89,0,0,1-24.51,9.09,146.3,146.3,0,0,1-27.1,2.57,126.24,126.24,0,0,1-28.31-3.09A69.56,69.56,0,0,1,1272,361.94a51.74,51.74,0,0,1-16.57-18.52q-6.21-11.49-6.9-27.95h29.34A32.65,32.65,0,0,0,1282.38,331.76Zm226.46-137.67v25.72h-35.56V329.88a31.37,31.37,0,0,0,.87,8.23,8.42,8.42,0,0,0,3.28,4.8,14.61,14.61,0,0,0,6.73,2.23,99.19,99.19,0,0,0,11.22.51h13.46v25.72H1486.4a105.8,105.8,0,0,1-19.5-1.55,28.65,28.65,0,0,1-13.12-5.65,24.09,24.09,0,0,1-7.42-11.66q-2.43-7.54-2.42-19.89V219.81h-30.38V194.09h30.38V140.94h29.34v53.15ZM1699.4,370.68q-7.61,4.45-21.06,4.46-11.4,0-18.12-6.34t-6.74-20.75a70.17,70.17,0,0,1-28.13,20.75,97.87,97.87,0,0,1-57.65,3.6,53.51,53.51,0,0,1-18.82-8.58,41.19,41.19,0,0,1-12.6-15.26q-4.65-9.42-4.66-22.8,0-15.09,5.18-24.69a44.92,44.92,0,0,1,13.64-15.6,62.63,62.63,0,0,1,19.33-9.09q10.88-3.08,22.27-5.14,12.07-2.4,23-3.6a128,128,0,0,0,19.16-3.43c5.53-1.48,9.89-3.65,13.12-6.51s4.83-7,4.83-12.52q0-9.6-3.62-15.43a24.94,24.94,0,0,0-9.32-8.92,38.38,38.38,0,0,0-12.78-4.11,96.54,96.54,0,0,0-14-1q-18.63,0-31.07,7t-13.46,26.57h-29.34q.67-16.46,6.9-27.77A52.21,52.21,0,0,1,1562,203.17a70,70,0,0,1,23.65-10.11,125.51,125.51,0,0,1,28.48-3.09,168.63,168.63,0,0,1,24,1.72,63.26,63.26,0,0,1,21.58,7,41.23,41.23,0,0,1,15.53,14.89q5.87,9.57,5.87,25v91q0,10.26,1.21,15.05t8.11,4.79a35.57,35.57,0,0,0,9-1.37Zm-47.64-90.87c-3.69,2.74-8.52,4.72-14.5,6s-12.26,2.27-18.82,3.07-13.17,1.71-19.85,2.73a73.7,73.7,0,0,0-17.95,4.94,32.62,32.62,0,0,0-12.94,9.73q-5,6.32-5,17.23a23.31,23.31,0,0,0,2.94,12.11,24.11,24.11,0,0,0,7.59,8,32,32,0,0,0,10.88,4.44,60.94,60.94,0,0,0,13.11,1.36q14.51,0,24.86-3.92a52.49,52.49,0,0,0,16.91-9.9,39.1,39.1,0,0,0,9.67-13,32.53,32.53,0,0,0,3.11-13.14Zm208.85,141.62q-20,21.6-62.83,21.6a122.11,122.11,0,0,1-25.37-2.74,78,78,0,0,1-23.48-8.92,54.41,54.41,0,0,1-17.43-16.11q-6.91-10-7.6-24.35h29.35a21.47,21.47,0,0,0,5,13.38,36.67,36.67,0,0,0,11.4,8.91,55.52,55.52,0,0,0,14.67,5,79.51,79.51,0,0,0,15.19,1.55q14.49,0,24.51-5A46,46,0,0,0,1840.59,401a56.53,56.53,0,0,0,9.49-21.09,117.46,117.46,0,0,0,2.94-27.09V341.19h-.7q-7.59,16.46-23,24.18a71.8,71.8,0,0,1-32.63,7.71q-20,0-34.86-7.2A72.88,72.88,0,0,1,1737,346.51a82.13,82.13,0,0,1-15-28.46,116.62,116.62,0,0,1-5-34.47,133.92,133.92,0,0,1,4.14-32.4A88.17,88.17,0,0,1,1735,221a75.49,75.49,0,0,1,25.55-22.29q15.87-8.75,39-8.75a66.21,66.21,0,0,1,31.07,7.38,52.13,52.13,0,0,1,22.09,22.11h.35V194.09h27.61V356.28Q1880.63,399.83,1860.61,421.43Zm-37.46-79.72a47.94,47.94,0,0,0,16.4-15.78,71.89,71.89,0,0,0,9.15-22.11,106.77,106.77,0,0,0,2.93-24.69,96.71,96.71,0,0,0-2.76-23,64,64,0,0,0-8.8-20.4,45.76,45.76,0,0,0-15.71-14.57q-9.66-5.49-23.47-5.49-14.16,0-24.17,5.32a46.77,46.77,0,0,0-16.4,14.23,60.14,60.14,0,0,0-9.32,20.57,99.69,99.69,0,0,0-2.93,24.35,120.63,120.63,0,0,0,2.42,24,67.5,67.5,0,0,0,8.28,21.77,46.37,46.37,0,0,0,15.54,15.78q9.66,6,24.16,6T1823.15,341.71Zm228,18.34q-20,15.09-50.41,15.09-21.4,0-37.11-6.86a73.16,73.16,0,0,1-26.41-19.2,81.52,81.52,0,0,1-16-29.49,141.12,141.12,0,0,1-6-37.38,106.1,106.1,0,0,1,6.21-37A88.56,88.56,0,0,1,1938.8,216a79.09,79.09,0,0,1,26.58-19.2A81.66,81.66,0,0,1,1999,190q23.82,0,39.53,9.78a78,78,0,0,1,25.2,24.86,98.18,98.18,0,0,1,13.12,32.91,140.6,140.6,0,0,1,2.93,34h-133.6a70,70,0,0,0,2.76,22.12,49.9,49.9,0,0,0,10,18.51A49.1,49.1,0,0,0,1976.6,345q10.7,4.82,25.2,4.8,18.65,0,30.55-8.57t15.71-26.06h29Q2071.18,345,2051.17,360.05Zm-7.08-113.84a50,50,0,0,0-10.7-16,53.1,53.1,0,0,0-56.62-10.63,47.48,47.48,0,0,0-15.71,10.81,51.69,51.69,0,0,0-10.35,15.94,60.18,60.18,0,0,0-4.49,19.37h102.53A59.47,59.47,0,0,0,2044.09,246.21ZM302.9,180a80.62,80.62,0,0,0,13.44-10.37c.8-.77,1.55-1.54,2.31-2.31a81.89,81.89,0,0,0,7.92-9.37,62.37,62.37,0,0,0,6.27-10.77,48.6,48.6,0,0,0,4.36-16.4c1.49-19.39-10-38.67-35.62-54.22L198.42,14,78.16,129.22l-78.29,75,108.6,65.9a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.8,66.42-25.69,19.16-18.36,25.52-42.12,13.7-61.87a49.69,49.69,0,0,0-6.8-8.87,89.78,89.78,0,0,0,19.28,2.15H259a85.09,85.09,0,0,0,31-5.79A80.88,80.88,0,0,0,302.9,180Zm-100.59,59.8c-19.32,18.51-50.4,21.24-75.7,5.9l-75.13-45.6,67.44-64.65,76.42,46.39C222.88,198.57,221.36,221.6,202.31,239.84Zm8.94-82.21L140.6,114.74,205,53l69.37,42.11c25.94,15.73,29.31,37.05,10.55,55A60.71,60.71,0,0,1,211.25,157.63Zm29.86,190c-19.57,18.75-46.17,29.08-74.88,29.08a123.84,123.84,0,0,1-64.11-18.19L-.13,296.51v24.67l108.6,65.91a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.81,66.42-25.69,12.88-12.34,20-27.13,19.68-41.49v-1.79A87.85,87.85,0,0,1,241.11,347.67Zm0-39c-19.57,18.76-46.17,29.09-74.88,29.09a123.84,123.84,0,0,1-64.11-18.19L-.13,257.52V282.2l108.6,65.91a111.59,111.59,0,0,0,57.76,16.41c24.92,0,48.8-8.8,66.42-25.68,12.88-12.35,20-27.13,19.68-41.5v-1.79A86.86,86.86,0,0,1,241.11,308.68Zm0-39c-19.57,18.76-46.17,29.09-74.88,29.09a123.84,123.84,0,0,1-64.11-18.19L-.13,218.54v24.68l108.6,65.91a111.59,111.59,0,0,0,57.76,16.41c24.92,0,48.8-8.8,66.42-25.69,12.88-12.34,20-27.12,19.68-41.49v-1.82A87.14,87.14,0,0,1,241.11,269.7Zm83.69,25.74a94.16,94.16,0,0,1-60.19,25.86h0V348a81.6,81.6,0,0,0,51.73-22.37c14-13.38,21.15-28.11,21-42.64v-2.2A95.14,95.14,0,0,1,324.8,295.44Zm-83.69,91.21c-19.57,18.75-46.17,29.09-74.88,29.09a123.76,123.76,0,0,1-64.11-18.2L-.13,335.49v24.67l108.6,65.91a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.81,66.42-25.69,12.88-12.34,20-27.13,19.68-41.49v-1.79A87.35,87.35,0,0,1,241.11,386.65Zm85.75-210.21c-.68.69-1.35,1.38-2.06,2.05a99.19,99.19,0,0,1-22.23,15.69,94.53,94.53,0,0,1-26.24,8.71,97.84,97.84,0,0,1-14.16,1.57c.5,1.61.9,3.25,1.25,4.9a52.7,52.7,0,0,1,1.13,12V231h.05A84.48,84.48,0,0,0,290,225.47a80.83,80.83,0,0,0,26.38-16.82c.81-.77,1.51-1.56,2.27-2.34a82,82,0,0,0,7.92-9.38,62.85,62.85,0,0,0,6.29-10.78,48.5,48.5,0,0,0,4.32-16.44c.09-1.23.2-2.47.19-3.7v-2c-.72,1-1.48,2.06-2.26,3.09A98,98,0,0,1,326.86,176.44Zm0,77.92c-.68.7-1.3,1.41-2,2.1a94.09,94.09,0,0,1-60.19,25.85h0V309h0a81.65,81.65,0,0,0,51.73-22.37,73.51,73.51,0,0,0,16.48-22.49,48.56,48.56,0,0,0,4.32-16.44c.09-1.24.2-2.48.19-3.71v-2.2c-.74,1.08-1.47,2.16-2.27,3.22A95.81,95.81,0,0,1,326.82,254.36Zm0-39c-.68.7-1.3,1.41-2,2.1a92.22,92.22,0,0,1-10.62,8.65,93.53,93.53,0,0,1-11.63,7,95.63,95.63,0,0,1-37.94,10.18h-.05l0,26.67h0a81.63,81.63,0,0,0,51.73-22.37c.81-.77,1.51-1.56,2.27-2.34a82,82,0,0,0,7.92-9.38,63.16,63.16,0,0,0,6.29-10.77,48.55,48.55,0,0,0,4.32-16.45c.09-1.23.2-2.47.19-3.7v-2.2c-.74,1.08-1.47,2.16-2.27,3.22A98.19,98.19,0,0,1,326.82,215.38Z"})})};const Yi=(0,Xe.A)({svg:{width:"auto",height:28},path:{fill:"#7df3e1"}});var Qi=()=>{const r=Yi();return(0,i.jsx)("svg",{className:r.svg,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 337.46 428.5",children:(0,i.jsx)("path",{className:r.path,d:"M303,166.05a80.69,80.69,0,0,0,13.45-10.37c.79-.77,1.55-1.53,2.3-2.3a83.12,83.12,0,0,0,7.93-9.38A63.69,63.69,0,0,0,333,133.23a48.58,48.58,0,0,0,4.35-16.4c1.49-19.39-10-38.67-35.62-54.22L198.56,0,78.3,115.23,0,190.25l108.6,65.91a111.59,111.59,0,0,0,57.76,16.41c24.92,0,48.8-8.8,66.42-25.69,19.16-18.36,25.52-42.12,13.7-61.87a49.22,49.22,0,0,0-6.8-8.87A89.17,89.17,0,0,0,259,178.29h.15a85.08,85.08,0,0,0,31-5.79A80.88,80.88,0,0,0,303,166.05ZM202.45,225.86c-19.32,18.51-50.4,21.23-75.7,5.9L51.61,186.15l67.45-64.64,76.41,46.38C223,184.58,221.49,207.61,202.45,225.86Zm8.93-82.22-70.65-42.89L205.14,39,274.51,81.1c25.94,15.72,29.31,37,10.55,55A60.69,60.69,0,0,1,211.38,143.64Zm29.86,190c-19.57,18.75-46.17,29.09-74.88,29.09a123.73,123.73,0,0,1-64.1-18.2L0,282.52v24.67L108.6,373.1a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.81,66.42-25.69,12.88-12.34,20-27.13,19.68-41.49v-1.79A87.27,87.27,0,0,1,241.24,333.68Zm0-39c-19.57,18.75-46.17,29.08-74.88,29.08a123.81,123.81,0,0,1-64.1-18.19L0,243.53v24.68l108.6,65.91a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.81,66.42-25.69,12.88-12.34,20-27.13,19.68-41.5v-1.78A87.27,87.27,0,0,1,241.24,294.7Zm0-39c-19.57,18.76-46.17,29.09-74.88,29.09a123.81,123.81,0,0,1-64.1-18.19L0,204.55v24.68l108.6,65.91a111.59,111.59,0,0,0,57.76,16.41c24.92,0,48.8-8.8,66.42-25.68,12.88-12.35,20-27.13,19.68-41.5v-1.82A86.09,86.09,0,0,1,241.24,255.71Zm83.7,25.74a94.15,94.15,0,0,1-60.2,25.86h0V334a81.6,81.6,0,0,0,51.74-22.37c14-13.38,21.14-28.11,21-42.64v-2.19A94.92,94.92,0,0,1,324.94,281.45Zm-83.7,91.21c-19.57,18.76-46.17,29.09-74.88,29.09a123.73,123.73,0,0,1-64.1-18.2L0,321.5v24.68l108.6,65.9a111.6,111.6,0,0,0,57.76,16.42c24.92,0,48.8-8.8,66.42-25.69,12.88-12.34,20-27.13,19.68-41.49v-1.79A86.29,86.29,0,0,1,241.24,372.66ZM327,162.45c-.68.69-1.35,1.38-2.05,2.06a94.37,94.37,0,0,1-10.64,8.65,91.35,91.35,0,0,1-11.6,7,94.53,94.53,0,0,1-26.24,8.71,97.69,97.69,0,0,1-14.16,1.57c.5,1.61.9,3.25,1.25,4.9a53.27,53.27,0,0,1,1.14,12V217h.05a84.41,84.41,0,0,0,25.35-5.55,81,81,0,0,0,26.39-16.82c.8-.77,1.5-1.56,2.26-2.34a82.08,82.08,0,0,0,7.93-9.38A63.76,63.76,0,0,0,333,172.17a48.55,48.55,0,0,0,4.32-16.45c.09-1.23.2-2.47.19-3.7V150q-1.08,1.54-2.25,3.09A96.73,96.73,0,0,1,327,162.45Zm0,77.92c-.69.7-1.31,1.41-2,2.1a94.2,94.2,0,0,1-60.2,25.86h0l0,26.67h0a81.6,81.6,0,0,0,51.74-22.37A73.51,73.51,0,0,0,333,250.13a48.56,48.56,0,0,0,4.32-16.44c.09-1.24.2-2.47.19-3.71v-2.19c-.74,1.07-1.46,2.15-2.27,3.21A95.68,95.68,0,0,1,327,240.37Zm0-39c-.69.7-1.31,1.41-2,2.1a93.18,93.18,0,0,1-10.63,8.65,91.63,91.63,0,0,1-11.63,7,95.47,95.47,0,0,1-37.94,10.18h0V256h0a81.65,81.65,0,0,0,51.74-22.37c.8-.77,1.5-1.56,2.26-2.34a82.08,82.08,0,0,0,7.93-9.38A63.76,63.76,0,0,0,333,211.15a48.56,48.56,0,0,0,4.32-16.44c.09-1.24.2-2.48.19-3.71v-2.2c-.74,1.08-1.46,2.16-2.27,3.22A95.68,95.68,0,0,1,327,201.39Z"})})},we=t(72664);const Jr={isOpen:!1,setOpen:()=>{}},Xr=(0,d.createContext)(Jr),qr=(0,on.tK)("sidebar-open-state-context");function ts(r){const{children:e,value:n}=r;return(0,i.jsx)(Xr.Provider,{value:n,children:(0,i.jsx)(qr.Provider,{value:(0,En.B)({1:n}),children:e})})}const hr=()=>{const r=(0,d.useContext)(qr),e=(0,d.useContext)(Xr);if(r===void 0)return e||Jr;const n=r.atVersion(1);if(n===void 0)throw new Error("No context found for version 1.");return n};var es=t(72072),ns=t(73524),sn=t(10394),os=t(5893),Zi=t(53373),vn=t.n(Zi),Ji=t(1125),rs=t(29365),Xi=t(73845),fr=t(72501),qi=t(32881),ta=t(27326),ea=t(13085);const ss=(0,d.createContext)({selectedMenuItemIndex:-1,setSelectedMenuItemIndex:()=>{}});var pr=t(34435);const na=(0,Xe.A)(r=>({root:{flexGrow:0,margin:r.spacing(0,2),color:r.palette.navigation.color},selected:e=>({color:`${r.palette.navigation.selectedColor}!important`,borderTop:`solid ${e.sidebarConfig.selectedIndicatorWidth}px ${r.palette.navigation.indicator}`,marginTop:"-1px"}),label:{display:"none"}})),oa=r=>{const{to:e,label:n,icon:s,value:a}=r,{sidebarConfig:l}=(0,d.useContext)(we.yY),b=na({sidebarConfig:l}),E=(0,m.zy)(),{selectedMenuItemIndex:B,setSelectedMenuItemIndex:k}=(0,d.useContext)(ss),Z=(et,ct)=>{k(ct===B?-1:ct)},rt=a===B&&B>=0||a!==B&&!(B>=0)&&e===E.pathname;return(0,i.jsx)(ea.A,{"aria-label":n,label:n,icon:s,component:es.N_,to:e||E.pathname,onChange:Z,value:a,selected:rt,classes:b})},is=r=>{const{children:e,to:n,label:s,icon:a,value:l}=r,{isMobile:b}=(0,pr.Ut)();return b?(0,i.jsx)(oa,{to:n,label:s,icon:a,value:l}):(0,i.jsx)(i.Fragment,{children:e})},as=(0,Xe.A)(r=>({root:{position:"fixed",backgroundColor:r.palette.navigation.background,color:r.palette.navigation.color,bottom:0,left:0,right:0,zIndex:r.zIndex.snackbar,borderTop:"1px solid #383838","@media print":{display:"none"}},overlay:e=>({background:r.palette.navigation.background,width:"100%",bottom:`${e.sidebarConfig.mobileSidebarHeight}px`,height:`calc(100% - ${e.sidebarConfig.mobileSidebarHeight}px)`,flex:"0 1 auto",overflow:"auto"}),overlayHeader:{display:"flex",color:r.palette.navigation.color,alignItems:"center",justifyContent:"space-between",padding:r.spacing(2,3)},overlayHeaderClose:{color:r.palette.navigation.color},marginMobileSidebar:e=>({marginBottom:`${e.sidebarConfig.mobileSidebarHeight}px`})})),ra=r=>(0,Tn.orderBy)(r,({props:{priority:e}})=>Number.isInteger(e)?e:-1,"desc"),sa=d.createElement(is).type,ia=({children:r,label:e="Menu",open:n,onClose:s})=>{const{sidebarConfig:a}=(0,d.useContext)(we.yY),l=as({sidebarConfig:a});return(0,i.jsxs)(Xi.Ay,{anchor:"bottom",open:n,onClose:s,ModalProps:{BackdropProps:{classes:{root:l.marginMobileSidebar}}},classes:{root:l.marginMobileSidebar,paperAnchorBottom:l.overlay},children:[(0,i.jsxs)(sn.A,{className:l.overlayHeader,children:[(0,i.jsx)(fr.A,{variant:"h3",children:e}),(0,i.jsx)(rs.A,{onClick:s,classes:{root:l.overlayHeaderClose},children:(0,i.jsx)(qi.A,{})})]}),(0,i.jsx)(sn.A,{component:"nav",children:r})]})},aa=r=>{const{sidebarConfig:e}=(0,d.useContext)(we.yY),{children:n}=r,s=as({sidebarConfig:e}),a=(0,m.zy)(),[l,b]=(0,d.useState)(-1);(0,d.useEffect)(()=>{b(-1)},[a.pathname]);let E=(0,bo.O)(n,k=>k.getElements().filter(Z=>Z.type===sa));if(n)E.length?E=ra(E):E.push((0,i.jsx)(is,{icon:(0,i.jsx)(ta.A,{}),children:n},"default_menu"));else return null;const B=l>=0&&!E[l].props.to;return(0,i.jsx)(ts,{value:{isOpen:!0,setOpen:()=>{}},children:(0,i.jsxs)(ss.Provider,{value:{selectedMenuItemIndex:l,setSelectedMenuItemIndex:b},children:[(0,i.jsx)(ia,{label:E[l]&&E[l].props.label,open:B,onClose:()=>b(-1),children:E[l]&&E[l].props.children}),(0,i.jsx)(Ji.A,{className:s.root,"data-testid":"mobile-sidebar-root",component:"nav",children:E})]})})};var la=t(87849),ca=t(10315);const ls=(0,Xe.A)(r=>({drawer:{display:"flex",flexFlow:"column nowrap",alignItems:"flex-start",position:"fixed",left:0,top:0,bottom:0,zIndex:r.zIndex.appBar,background:r.palette.navigation.background,overflowX:"hidden",msOverflowStyle:"none",scrollbarWidth:"none",transition:r.transitions.create("width",{easing:r.transitions.easing.sharp,duration:r.transitions.duration.shortest}),"& > *":{flexShrink:0},"&::-webkit-scrollbar":{display:"none"},"@media print":{display:"none"}},drawerWidth:e=>({width:e.sidebarConfig.drawerWidthClosed}),drawerOpen:e=>({width:e.sidebarConfig.drawerWidthOpen,transition:r.transitions.create("width",{easing:r.transitions.easing.sharp,duration:r.transitions.duration.shorter})}),visuallyHidden:{top:0,position:"absolute",zIndex:1e3,transform:"translateY(-200%)","&:focus":{transform:"translateY(5px)"}}}),{name:"BackstageSidebar"});var cs;(function(r){r[r.Closed=0]="Closed",r[r.Idle=1]="Idle",r[r.Open=2]="Open"})(cs||(cs={}));const da=r=>{const{sidebarConfig:e}=(0,d.useContext)(we.yY),{openDelayMs:n=e.defaultOpenDelayMs,closeDelayMs:s=e.defaultCloseDelayMs,disableExpandOnHover:a,children:l}=r,b=ls({sidebarConfig:e}),E=(0,os.A)(me=>me.breakpoints.down("md"),{noSsr:!0}),[B,k]=(0,d.useState)(0),Z=(0,d.useRef)(),{isPinned:rt,toggleSidebarPinState:et}=(0,pr.Ut)(),ct=()=>{rt||a||(Z.current&&(clearTimeout(Z.current),Z.current=void 0),B!==2&&!E&&(Z.current=window.setTimeout(()=>{Z.current=void 0,k(2)},n),k(1)))},At=()=>{rt||a||(Z.current&&(clearTimeout(Z.current),Z.current=void 0),B===1?k(0):B===2&&(Z.current=window.setTimeout(()=>{Z.current=void 0,k(0)},s)))},Ut=B===2&&!E||rt,Kt=me=>{me?(k(2),et()):(k(0),et())};return(0,i.jsxs)("nav",{style:{},"aria-label":"sidebar nav",children:[(0,i.jsx)(ha,{}),(0,i.jsx)(ts,{value:{isOpen:Ut,setOpen:Kt},children:(0,i.jsx)(sn.A,{className:b.root,"data-testid":"sidebar-root",onMouseEnter:a?()=>{}:ct,onFocus:a?()=>{}:ct,onMouseLeave:a?()=>{}:At,onBlur:a?()=>{}:At,children:(0,i.jsx)(sn.A,{className:vn()(b.drawer,b.drawerWidth,{[b.drawerOpen]:Ut}),children:l})})})]})},ua=r=>{var e;const n=(0,we.Rv)((e=r.sidebarOptions)!==null&&e!==void 0?e:{});var s;const a=(0,we.i8)((s=r.submenuOptions)!==null&&s!==void 0?s:{}),{children:l,disableExpandOnHover:b,openDelayMs:E,closeDelayMs:B}=r,{isMobile:k}=(0,pr.Ut)();return k?(0,i.jsx)(aa,{children:l}):(0,i.jsx)(we.yY.Provider,{value:{sidebarConfig:n,submenuConfig:a},children:(0,i.jsx)(da,{openDelayMs:E,closeDelayMs:B,disableExpandOnHover:b,children:l})})};function ha(){const{sidebarConfig:r}=(0,d.useContext)(we.yY),{focusContent:e,contentRef:n}=(0,ns.H)(),s=ls({sidebarConfig:r}),{t:a}=(0,la.i)(ca.O);return n!=null&&n.current?(0,i.jsx)(A.A,{onClick:e,variant:"contained",className:vn()(s.visuallyHidden),children:a("skipToContent")}):null}var fa=t(94509),To=t(44209),pa=t(79065),ga=t(55704),ds=t(62248);const va=(0,Xe.A)(r=>({root:{zIndex:1e3,position:"relative",overflow:"visible",width:r.spacing(7)+1},drawer:e=>{var n,s;return{display:"flex",flexFlow:"column nowrap",alignItems:"flex-start",position:"fixed",[r.breakpoints.up("sm")]:{marginLeft:e.left,transition:r.transitions.create("margin-left",{easing:r.transitions.easing.sharp,duration:r.transitions.duration.shortest})},top:0,bottom:0,padding:0,background:(s=(n=r.palette.navigation.submenu)===null||n===void 0?void 0:n.background)!==null&&s!==void 0?s:"#404040",overflowX:"hidden",msOverflowStyle:"none",scrollbarWidth:"none",cursor:"default",width:e.submenuConfig.drawerWidthClosed,transitionDelay:`${e.submenuConfig.defaultOpenDelayMs}ms`,"& > *":{flexShrink:0},"&::-webkit-scrollbar":{display:"none"}}},drawerOpen:e=>({width:e.submenuConfig.drawerWidthOpen,[r.breakpoints.down("xs")]:{width:"100%",position:"relative",paddingLeft:r.spacing(3),left:0,top:0}}),title:{fontSize:r.typography.h5.fontSize,fontWeight:r.typography.fontWeightMedium,color:r.palette.common.white,padding:r.spacing(2.5),[r.breakpoints.down("xs")]:{display:"none"}}}),{name:"BackstageSidebarSubmenu"}),ma=r=>{const{isOpen:e}=hr(),{sidebarConfig:n,submenuConfig:s}=(0,d.useContext)(we.yY),a=e?n.drawerWidthOpen:n.drawerWidthClosed,l=va({left:a,submenuConfig:s}),{isHoveredOn:b}=(0,d.useContext)(we.U1),[E,B]=(0,d.useState)(!1);return(0,d.useEffect)(()=>{B(b)},[b]),(0,i.jsxs)(sn.A,{className:vn()(l.drawer,{[l.drawerOpen]:E}),children:[(0,i.jsx)(fr.A,{variant:"h5",component:"span",className:l.title,children:r.title}),r.children]})};var ya=t(45810),us=t.n(ya);function hs(r,e,n=!1){const s=new URLSearchParams(e.search).toString(),a=us().parse(s),l=new URLSearchParams(r.search).toString(),b=us().parse(l),E=n?Tn.isEqual:Tn.isMatch;return(0,Tn.isEqual)(e.pathname,r.pathname)&&E(b,a)}const Ea=r=>(0,Xe.A)(e=>{var n,s,a,l;return{root:{color:e.palette.navigation.color,display:"flex",flexFlow:"row nowrap",alignItems:"center",height:48,cursor:"pointer"},buttonItem:{background:"none",border:"none",width:"100%",margin:0,padding:0,textAlign:"inherit",font:"inherit",textTransform:"none"},closed:{width:r.drawerWidthClosed,justifyContent:"center"},open:{[e.breakpoints.up("sm")]:{width:r.drawerWidthOpen}},highlightable:{"&:hover":{background:(a=(n=e.palette.navigation.navItem)===null||n===void 0?void 0:n.hoverBackground)!==null&&a!==void 0?a:"#404040"}},highlighted:{background:(l=(s=e.palette.navigation.navItem)===null||s===void 0?void 0:s.hoverBackground)!==null&&l!==void 0?l:"#404040"},label:{fontWeight:"bold",whiteSpace:"nowrap",lineHeight:"auto",flex:"3 1 auto",width:"110px",overflow:"hidden","text-overflow":"ellipsis"},iconContainer:{boxSizing:"border-box",height:"100%",width:r.iconContainerWidth,marginRight:-e.spacing(2),display:"flex",alignItems:"center",justifyContent:"center",lineHeight:"0"},searchRoot:{marginBottom:12},searchField:{color:"#b5b5b5",fontWeight:e.typography.fontWeightBold,fontSize:e.typography.fontSize},searchFieldHTMLInput:{padding:e.spacing(2,0,2)},searchContainer:{width:r.drawerWidthOpen-r.iconContainerWidth},secondaryAction:{width:e.spacing(6),textAlign:"center",marginRight:e.spacing(1)},closedItemIcon:{width:"100%",justifyContent:"center"},submenuArrow:{display:"flex"},expandButton:{background:"none",border:"none",color:e.palette.navigation.color,width:"100%",cursor:"pointer",position:"relative",height:48},arrows:{position:"absolute",right:10},selected:{"&$root":{borderLeft:`solid ${r.selectedIndicatorWidth}px ${e.palette.navigation.indicator}`,color:e.palette.navigation.selectedColor},"&$closed":{width:r.drawerWidthClosed},"& $closedItemIcon":{paddingRight:r.selectedIndicatorWidth},"& $iconContainer":{marginLeft:-r.selectedIndicatorWidth}}}},{name:"BackstageSidebarItem"});function Ro(r){return(0,d.useMemo)(()=>Ea(r),[r])()}const Aa=(r,e)=>(0,bo.O)(r.props.children,n=>{let s=!1;return n.getElements().forEach(({props:{to:a,dropdownItems:l}})=>{if(!s){if(l!=null&&l.length){l.forEach(({to:b})=>s=s||hs(e,(0,Hn.o1)(b)));return}a&&(s=hs(e,(0,Hn.o1)(a)))}}),s},[e.pathname]);function gr(r){return r.to===void 0}const xa=d.createElement(ma).type,Ca=d.forwardRef(function({to:e,end:n,style:s,className:a,activeStyle:l,caseSensitive:b,activeClassName:E="active","aria-current":B="page",...k},Z){let{pathname:rt}=(0,m.zy)(),{pathname:et}=(0,m.x$)(e);b||(rt=rt.toLocaleLowerCase("en-US"),et=et.toLocaleLowerCase("en-US"));let ct=rt===et;!ct&&!n&&(ct=rt.startsWith(`${et}/`));const At=ct?B:void 0;return(0,i.jsx)(g.N_,{...k,to:e,ref:Z,"aria-current":At,style:{...s,...ct?l:void 0},className:vn()([typeof a!="function"?a:void 0,ct?E:void 0])})}),fs=(0,d.forwardRef)((r,e)=>{const{icon:n,text:s,hasNotifications:a=!1,hasSubmenu:l=!1,disableHighlight:b=!1,onClick:E,noTrack:B,children:k,className:Z,...rt}=r,{sidebarConfig:et}=(0,d.useContext)(we.yY),ct=Ro(et),{isOpen:At}=hr(),Ut=!At&&l?{display:"flex",marginLeft:"20px"}:{lineHeight:"0"},Kt=(0,i.jsxs)(sn.A,{style:Ut,children:[(0,i.jsx)(n,{fontSize:"small"}),!At&&l?(0,i.jsx)(ds.A,{fontSize:"small"}):(0,i.jsx)(i.Fragment,{})]}),me=(0,i.jsx)(fa.A,{color:"secondary",variant:"dot",overlap:"circular",invisible:!a,className:vn()({[ct.closedItemIcon]:!At}),children:Kt}),oe=(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(sn.A,{"data-testid":"login-button",className:ct.iconContainer,children:me}),s&&(0,i.jsx)(fr.A,{variant:"subtitle2",component:"span",className:ct.label,children:s}),(0,i.jsx)("div",{className:ct.secondaryAction,children:k})]}),Ie=At?oe:me,Zn={onClick:E,className:vn()(Z,ct.root,At?ct.open:ct.closed,gr(r)&&ct.buttonItem,{[ct.highlightable]:!b})},ms=(0,Mr.s)(),{pathname:vr}=(0,m.x$)(!gr(r)&&r.to?r.to:""),ys=(0,d.useCallback)(za=>{if(!B){const Ha="click",_a=s!=null?s:"Sidebar Item",Va=vr?{attributes:{to:vr}}:void 0;ms.captureEvent(Ha,_a,Va)}E==null||E(za)},[ms,s,vr,B,E]);return gr(r)?(0,i.jsx)(A.A,{role:"button","aria-label":s,...Zn,ref:e,onClick:ys,children:Ie}):(0,i.jsx)(Ca,{...Zn,activeClassName:ct.selected,to:r.to?r.to:"",ref:e,"aria-label":s||r.to,...rt,onClick:ys,children:Ie})}),ba=({children:r,...e})=>{const{sidebarConfig:n}=(0,d.useContext)(we.yY),s=Ro(n),[a,l]=(0,d.useState)(!1),b=(0,m.zy)(),E=Aa(r,b),B=(0,os.A)(et=>et.breakpoints.down("sm")),k=()=>{l(!0)},Z=()=>{l(!1)},rt=()=>B?a?(0,i.jsx)(ga.A,{fontSize:"small",className:s.submenuArrow}):(0,i.jsx)(pa.A,{fontSize:"small",className:s.submenuArrow}):!a&&(0,i.jsx)(ds.A,{fontSize:"small",className:s.submenuArrow});return(0,i.jsx)(we.U1.Provider,{value:{isHoveredOn:a,setIsHoveredOn:l},children:(0,i.jsxs)("div",{"data-testid":"item-with-submenu",onMouseLeave:Z,onTouchStart:a?Z:k,onMouseEnter:k,className:vn()(a&&s.highlighted),children:[(0,i.jsx)(fs,{hasSubmenu:!0,className:E?s.selected:"",...e,children:rt()}),a&&r]})})},ps=(0,d.forwardRef)((r,e)=>{const[n]=(0,bo.O)(r.children,s=>s.getElements().filter(a=>a.type===xa));return n?(0,i.jsx)(ba,{...r,children:n}):(0,i.jsx)(fs,{...r,ref:e})});function cl(r){const{sidebarConfig:e}=useContext(SidebarConfigContext),[n,s]=useState(""),a=Ro(e),l=r.icon?r.icon:SearchIcon,b=()=>{r.onSearch(n),s("")},E=rt=>{rt.key==="Enter"&&(rt.preventDefault(),b())},B=rt=>{s(rt.target.value)},k=rt=>{rt.preventDefault(),rt.stopPropagation()},Z=rt=>{b(),rt.preventDefault()};return _jsx(Box,{className:a.searchRoot,children:_jsx(ps,{icon:l,to:r.to,onClick:Z,disableHighlight:!0,children:_jsx(TextField,{placeholder:"Search",value:n,onClick:k,onChange:B,onKeyDown:E,className:a.searchContainer,InputProps:{disableUnderline:!0,className:a.searchField},inputProps:{className:a.searchFieldHTMLInput}})})})}const dl=(0,To.A)("div")({flex:1},{name:"BackstageSidebarSpace"}),ul=(0,To.A)("div")({height:8},{name:"BackstageSidebarSpacer"}),Sa=(0,To.A)("hr")(({theme:r})=>({height:1,width:"100%",background:"#383838",border:"none",margin:r.spacing(1.2,0)}),{name:"BackstageSidebarDivider"}),Oa=r=>({overflowY:"auto","&::-webkit-scrollbar":{backgroundColor:r.palette.background.default,width:"5px",borderRadius:"5px"},"&::-webkit-scrollbar-thumb":{backgroundColor:r.palette.text.secondary,borderRadius:"5px"}}),hl=(0,To.A)("div")(({theme:r})=>{const e=Oa(r);return{flex:"0 1 auto",overflowX:"hidden",width:"100%",minHeight:"48px",overflowY:"hidden","@media (hover: none)":e,"&:hover":e}}),fl=()=>{const{sidebarConfig:r}=useContext(SidebarConfigContext),e=Ro(r),{isOpen:n,setOpen:s}=useSidebarOpenState();if(useMediaQuery(b=>b.breakpoints.down("md"),{noSsr:!0}))return null;const l=()=>{s(!n)};return _jsx(Button,{role:"button",onClick:l,className:e.expandButton,"aria-label":"Expand Sidebar","data-testid":"sidebar-expand-button",children:_jsx(Box,{className:e.arrows,children:n?_jsx(DoubleArrowLeft,{}):_jsx(DoubleArrowRight,{})})})},wa=(0,Xe.A)({root:{width:we.hC.drawerWidthClosed,height:3*we.hC.logoHeight,display:"flex",flexFlow:"row nowrap",alignItems:"center",marginBottom:-14},link:{width:we.hC.drawerWidthClosed,marginLeft:24}}),Pa=()=>{const r=wa(),{isOpen:e}=hr();return(0,i.jsx)("div",{className:r.root,children:(0,i.jsx)(es.N_,{to:"/docs/default/component/local/",underline:"none",className:r.link,children:e?(0,i.jsx)(Gi,{}):(0,i.jsx)(Qi,{})})})},Ta=({children:r})=>(0,i.jsxs)(ns.G,{children:[(0,i.jsxs)(ua,{children:[(0,i.jsx)(Pa,{}),(0,i.jsx)(Sa,{}),(0,i.jsx)(ps,{icon:_i.A,to:"/docs/default/component/local",text:"Docs Preview"})]}),r]});var Ra=t(71677),Ia=t(62437),Da=t(55484),Ma=t(45061),La=t(16203);const Ba=(0,Xe.A)(r=>({headerIcon:{color:r.palette.common.white,width:"32px",height:"32px"},content:{backgroundColor:r.palette.background.default},contentToolbar:{display:"flex",justifyContent:"flex-end",padding:0}}));var gs;(function(r){r.LIGHT="light",r.DARK="dark"})(gs||(gs={}));const ja=()=>{const r=(0,zn.gf)(co),e=Ba(),[n,s]=(0,d.useState)(r.getActiveThemeId()==="dark"?"dark":"light"),a={light:{icon:Da.A,title:"Dark theme"},dark:{icon:Ia.A,title:"Light theme"}},{title:l,icon:b}=a[n],E=()=>{s(B=>{const k=B==="light"?"dark":"light";return r.setActiveThemeId(k),k})};return(0,i.jsx)(sn.A,{display:"flex",alignItems:"center",mr:2,children:(0,i.jsx)(Ra.Ay,{title:l,arrow:!0,children:(0,i.jsx)(rs.A,{size:"small",onClick:E,children:(0,i.jsx)(b,{className:e.headerIcon})})})})},Ua=()=>(0,i.jsxs)(v.Wj,{children:[(0,i.jsx)(Ma.T,{}),(0,i.jsx)(La.p,{withSearch:!1})]}),$a=(0,i.jsx)(Ua,{}),vs=gi({apis:Wi,configLoader:Hi,plugins:Object.values(o)}),Fa=vs.getProvider(),Na=vs.getRouter(),Wa=v.Ju.provide((0,c.Hr)({name:"ThemeToggleAddon",component:ja,location:C.e.Header})),ka=(0,i.jsxs)(kr,{children:[(0,i.jsx)(m.C5,{to:"/docs/default/component/local/"},"/"),(0,i.jsx)(m.qh,{path:"/catalog/:namespace/:kind/:name",element:(0,i.jsx)($i,{})}),(0,i.jsx)(m.qh,{path:"/docs",element:(0,i.jsx)(v.$j,{}),children:(0,i.jsx)(f.K,{})}),(0,i.jsxs)(m.qh,{path:"/docs/:namespace/:kind/:name/*",element:(0,i.jsx)(v.Wj,{}),children:[$a,(0,i.jsx)(c.po,{children:(0,i.jsx)(Wa,{})})]})]});var Ka=()=>(0,i.jsx)(Fa,{children:(0,i.jsx)(Na,{children:(0,i.jsx)(Ta,{children:ka})})});O.createRoot(document.getElementById("root")).render((0,i.jsx)(Ka,{}))},43836:function(Y,T,t){"use strict";t.d(T,{qO:function(){return O},tK:function(){return d}});var o=t(14041),i=t(63544);function d(v){return(0,i.Q)(v,()=>(0,o.createContext)(void 0))}function O(v){return(0,o.useContext)(d(v))}function m(v){return{set(f){globalThis[`__@backstage/${v}__`]=createContext(createVersionedValueMap(f))},reset(){delete globalThis[`__@backstage/${v}__`]}}}},10602:function(Y,T,t){"use strict";t.d(T,{B:function(){return o}});function o(i){Object.freeze(i);const d={atVersion(O){return i[O]}};return Object.defineProperty(d,"$map",{configurable:!0,enumerable:!0,get(){return i}}),d}},63544:function(Y,T,t){"use strict";t.d(T,{Q:function(){return O}});function o(){return typeof window!="undefined"&&window.Math===Math?window:typeof self!="undefined"&&self.Math===Math?self:Function("return this")()}const i=o(),d=m=>`__@backstage/${m}__`;function O(m,v){const f=d(m);let c=i[f];return c||(c=v(),i[f]=c,c)}},7341:function(Y,T,t){"use strict";t.d(T,{v:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"plugin.catalog.service"})},82292:function(Y,T,t){"use strict";t.d(T,{n:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"plugin.catalog.entity-presentation"})},88083:function(Y,T,t){"use strict";t.d(T,{T:function(){return m}});var o=t(6820),i=t(72348),d=t(46123),O=t.n(d);function m(c,C){const{kind:A,namespace:w,name:h,title:S,description:g,displayName:D,type:P}=v(c),y=(0,o.U2)({kind:A||"unknown",namespace:w||i.oQ,name:h||"unknown"}),j=f({kind:A,namespace:w,name:h,context:C}),R=[D,S,j].find(z=>z&&typeof z=="string"),x=[R!==y?y:void 0,P,g].filter(z=>z&&typeof z=="string").join(" | ");return{entityRef:y,primaryTitle:R,secondaryTitle:x||void 0,Icon:void 0}}function v(c){if(typeof c=="string"){let C=c.indexOf(":");const A=c.indexOf("/");A!==-1&&A<C&&(C=-1);const w=C===-1?void 0:c.slice(0,C),h=A===-1?void 0:c.slice(C+1,A),S=c.slice(Math.max(C+1,A+1));return{kind:w,namespace:h,name:S}}if(typeof c=="object"&&c!==null){const C=[O()(c,"kind")].find(P=>P&&typeof P=="string"),A=[O()(c,"metadata.namespace"),O()(c,"namespace")].find(P=>P&&typeof P=="string"),w=[O()(c,"metadata.name"),O()(c,"name")].find(P=>P&&typeof P=="string"),h=[O()(c,"metadata.title")].find(P=>P&&typeof P=="string"),S=[O()(c,"metadata.description")].find(P=>P&&typeof P=="string"),g=[O()(c,"spec.profile.displayName")].find(P=>P&&typeof P=="string"),D=[O()(c,"spec.type")].find(P=>P&&typeof P=="string");return{kind:C,namespace:A,name:w,title:h,description:S,displayName:g,type:D}}return{}}function f(c){var C,A,w,h,S;const g=((C=c.kind)===null||C===void 0?void 0:C.toLocaleLowerCase("en-US"))||"unknown",D=c.namespace||i.oQ,P=c.name||"unknown",y=(w=c.context)===null||w===void 0||(A=w.defaultKind)===null||A===void 0?void 0:A.toLocaleLowerCase("en-US"),j=(S=c.context)===null||S===void 0||(h=S.defaultNamespace)===null||h===void 0?void 0:h.toLocaleLowerCase("en-US");let R=P;return(j&&D.toLocaleLowerCase("en-US")!==j||D!==i.oQ)&&(R=`${D}/${R}`),y&&g.toLocaleLowerCase("en-US")!==y&&(R=`${g}:${R}`),R}},3169:function(Y,T,t){"use strict";t.d(T,{f:function(){return f}});var o=t(6820),i=t(72427),d=t(14041),O=t(82292),m=t(88083);function v(c,C,A){const[w,h]=(0,d.useState)(c);return(0,d.useEffect)(()=>{h(c);const S=C==null?void 0:C.subscribe({next:g=>{h(g)},complete:()=>{S==null||S.unsubscribe()}});return()=>{S==null||S.unsubscribe()}},A),w}function f(c,C){const w=(0,i.Q2)().get(O.n),h=[w,JSON.stringify(c),JSON.stringify(C||null)],S=(0,d.useMemo)(()=>{if(!w){const g=(0,m.T)(c,C);return{snapshot:g,promise:Promise.resolve(g)}}return w.forEntity(typeof c=="string"||"metadata"in c?c:(0,o.U2)(c),C)},h);return v(S.snapshot,S.update$,[S])}},18:function(Y,T,t){"use strict";t.d(T,{a:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"catalog-react.starred-entities"})},54203:function(Y,T,t){"use strict";t.d(T,{GI:function(){return S}});var o=t(31085),i=t(14041),d=t(10394),O=t(64947),m=t(73845),v=t(42899),f=t(72501),c=t(5893),C=t(54917),A=t(65859);const w=g=>{var D;const P=(0,c.A)(z=>{var _,tt;return z.breakpoints.down((tt=(_=g.options)===null||_===void 0?void 0:_.drawerBreakpoint)!==null&&tt!==void 0?tt:"md")}),y=(0,C.A)(),[j,R]=(0,i.useState)(!1);var x;return P?(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(O.A,{style:{marginTop:y.spacing(1),marginLeft:y.spacing(1)},onClick:()=>R(!0),startIcon:(0,o.jsx)(A.A,{}),children:"Filters"}),(0,o.jsx)(m.Ay,{open:j,onClose:()=>R(!1),anchor:(x=(D=g.options)===null||D===void 0?void 0:D.drawerAnchor)!==null&&x!==void 0?x:"left",disableAutoFocus:!0,keepMounted:!0,variant:"temporary",children:(0,o.jsxs)(d.A,{m:2,children:[(0,o.jsx)(f.A,{variant:"h6",component:"h2",style:{marginBottom:y.spacing(1)},children:"Filters"}),g.children]})})]}):(0,o.jsx)(v.A,{item:!0,lg:2,children:g.children})},h=g=>(0,o.jsx)(v.A,{item:!0,xs:12,lg:10,children:g.children}),S=g=>(0,o.jsx)(v.A,{container:!0,style:{position:"relative"},children:g.children});S.Filters=w,S.Content=h},50207:function(Y,T,t){"use strict";t.d(T,{y:function(){return H}});var o=t(31085),i=t(10394),d=t(72501),O=t(58837),m=t(6924),v=t(20577),f=t(14041),c=t(72427),C=t(73466),A=t(7341),w=t(69076),h=t(86901),S=t(44148),g=t(41260);const D=(0,o.jsx)(g.A,{fontSize:"small"}),P=(0,o.jsx)(S.A,{fontSize:"small"});function y({selected:J}){return(0,o.jsx)(w.A,{icon:D,checkedIcon:P,checked:J})}const j=(0,f.memo)(J=>{const{selected:q,value:yt,availableOptions:at,showCounts:Ot}=J,ht=Ot?`${yt} (${at==null?void 0:at[yt]})`:yt;return(0,o.jsx)(h.A,{control:(0,o.jsx)(y,{selected:q}),label:ht,onClick:vt=>vt.preventDefault()})});var R=t(16249),x=t(53373),z=t.n(x);const _=(0,O.A)({input:{}},{name:"CatalogReactEntityAutocompletePickerInput"});function tt(J){const q=_();return(0,o.jsx)(R.A,{variant:"outlined",...J,className:z()(q.input,J.className)})}var K=t(21405),W=t(26796);const G=(0,O.A)({root:{},label:{}},{name:"CatalogReactEntityAutocompletePicker"});function H(J){var q;const{label:yt,name:at,path:Ot,showCounts:ht,Filter:vt,InputProps:dt,initialSelectedOptions:st=[],filtersForAvailableValues:mt=["kind"]}=J,Et=G(),{updateFilters:Tt,filters:gt,queryParameters:{[at]:it}}=(0,K.nK)(),ft=(0,c.gf)(A.v),pt=mt.map(Mt=>gt[Mt]),{value:Rt}=(0,C.A)(async()=>{const Mt=Ot,{facets:Wt}=await ft.getEntityFacets({facets:[Mt],filter:(0,W.Rr)(pt.filter(Boolean))});return Object.fromEntries(Wt[Mt].map(({value:St,count:Nt})=>[St,Nt]))},[...pt]),Ct=(0,f.useMemo)(()=>[it].flat().filter(Boolean),[it]);var N;const[V,xt]=(0,f.useState)(Ct.length?Ct:(N=(q=gt[at])===null||q===void 0?void 0:q.values)!==null&&N!==void 0?N:st);(0,f.useEffect)(()=>{Ct.length&&xt(Ct)},[Ct]);const wt=Object.keys(Rt!=null?Rt:{}),Ft=V.length&&wt.length;(0,f.useEffect)(()=>{Tt({[at]:Ft?new vt(V):void 0})},[at,Ft,V,vt,Tt]);const It=gt[at];return It&&typeof It=="object"&&!("values"in It)||!wt.length?null:(0,o.jsx)(i.A,{className:Et.root,pb:1,pt:1,children:(0,o.jsxs)(d.A,{className:Et.label,variant:"button",component:"label",children:[yt,(0,o.jsx)(v.Ay,{multiple:!0,disableCloseOnSelect:!0,options:wt,value:V,onChange:(Mt,Wt)=>xt(Wt),renderOption:(Mt,{selected:Wt})=>(0,o.jsx)(j,{selected:Wt,value:Mt,availableOptions:Rt,showCounts:!!ht}),size:"small",popupIcon:(0,o.jsx)(m.A,{"data-testid":`${String(at)}-picker-expand`}),renderInput:Mt=>(0,o.jsx)(tt,{...Mt,...dt})})]})})}},72987:function(Y,T,t){"use strict";t.d(T,{t:function(){return gt}});var o=t(31085),i=t(6820),d=t(10394),O=t(69076),m=t(86901),v=t(16249),f=t(72501),c=t(71677),C=t(58837),A=t(44148),w=t(41260),h=t(6924),S=t(20577),g=t(14041),D=t(21405),P=t(92822),y=t(92367),j=t(48108),R=t(47966),x=t(90184),z=t(72427),_=t(87290),tt=t(7341);function K({enabled:it}){const ft=(0,z.gf)(tt.v),[pt]=(0,g.useState)(async()=>{if(!it)return[];const Rt="relations.ownedBy";return ft.getEntityFacets({facets:[Rt]}).then(Ct=>Ct.facets[Rt].map(N=>N.value).map(N=>{const{kind:V,name:xt,namespace:wt}=(0,i.KU)(N);return{apiVersion:"backstage.io/v1beta1",kind:V,metadata:{name:xt,namespace:wt}}}).sort((N,V)=>(N.metadata.namespace||"").localeCompare(V.metadata.namespace||"","en-US")||N.metadata.name.localeCompare(V.metadata.name,"en-US")||N.kind.localeCompare(V.kind,"en-US"))).catch(()=>[])});return(0,_.A)(async(Rt,Ct)=>{const N=await pt;if(!N)return{items:[]};var V;const xt=(V=Ct==null?void 0:Ct.limit)!==null&&V!==void 0?V:20,{text:wt,start:Ft}=W(Rt),It=N.filter(Wt=>J(wt,Wt)),Mt=Ft+xt;return{items:It.slice(0,Mt),...H({entities:It,limit:Mt,payload:{text:wt,start:Mt}})}},[pt],{loading:!0,value:{items:[]}})}function W(it){return G(it)&&it.cursor?JSON.parse(atob(it.cursor)):{text:it.text||"",start:0}}function G(it){return!!it.cursor}function H({entities:it,limit:ft,payload:pt}){return it.length>ft?{cursor:btoa(JSON.stringify(pt))}:{}}function J(it,ft){var pt;const Rt=it.trim();return ft.kind.includes(Rt)||((pt=ft.metadata.namespace)===null||pt===void 0?void 0:pt.includes(Rt))||ft.metadata.name.includes(Rt)}function q(){const it=(0,z.gf)(tt.v);return(0,_.A)(async(ft,pt)=>{const Rt=ft,Ct=ft;var N;const V=(N=pt==null?void 0:pt.limit)!==null&&N!==void 0?N:20;if(Ct.cursor){const wt=await it.queryEntities({cursor:Ct.cursor,limit:V});return{cursor:wt.pageInfo.nextCursor,items:[...Ct.items,...wt.items]}}const xt=await it.queryEntities({fullTextFilter:{term:Rt.text||"",fields:["metadata.name","kind","spec.profile.displayname","metadata.title"]},filter:{kind:["User","Group"]},orderFields:[{field:"metadata.name",order:"asc"}],limit:V});return{cursor:xt.pageInfo.nextCursor,items:xt.items}},[],{loading:!0})}var yt=t(76842);function at({mode:it,initialSelectedOwnersRefs:ft}){const pt=it==="owners-only",Rt=q(),Ct=K({enabled:pt}),[N,V]=pt?Ct:Rt;return[N,V,Ot({enabled:!pt,initialSelectedOwnersRefs:ft})]}function Ot({enabled:it,initialSelectedOwnersRefs:ft}){const pt=(0,g.useRef)({}),Rt=(0,z.gf)(tt.v),[,Ct]=(0,_.A)(async()=>{(await Rt.getEntitiesByRefs({entityRefs:ft})).items.forEach(V=>{V&&(pt.current[(0,i.U2)(V)]=V)})},[]);return(0,yt.u)(()=>{it&&ft.length>0&&Ct()}),{getEntity:N=>pt.current[N],setEntity:N=>{pt.current[(0,i.U2)(N)]=N}}}var ht=t(87051),vt=t(3169);const dt=(0,C.A)({root:{},label:{},input:{},fullWidth:{width:"100%"},boxLabel:{width:"100%",textOverflow:"ellipsis",overflow:"hidden"}},{name:"CatalogReactEntityOwnerPicker"}),st=(0,ht.A)(it=>({label:{width:"100%"},root:{width:"90%"}}),{name:"FixedWidthFormControlLabel"})(m.A),mt=(0,o.jsx)(w.A,{fontSize:"small"}),Et=(0,o.jsx)(A.A,{fontSize:"small"});function Tt(it){const ft=dt(),pt=it.entity.kind.toLocaleLowerCase("en-US")==="group",{primaryTitle:Rt}=(0,vt.f)(it.entity);return(0,o.jsx)(d.A,{className:ft.fullWidth,children:(0,o.jsx)(st,{className:ft.fullWidth,control:(0,o.jsx)(O.A,{icon:mt,checkedIcon:Et,checked:it.isSelected}),onClick:Ct=>Ct.preventDefault(),label:(0,o.jsx)(c.Ay,{title:Rt,children:(0,o.jsxs)(d.A,{display:"flex",alignItems:"center",children:[pt?(0,o.jsx)(R.A,{fontSize:"small"}):(0,o.jsx)(j.A,{fontSize:"small"}),"\xA0",(0,o.jsx)(d.A,{className:ft.boxLabel,children:(0,o.jsx)(f.A,{noWrap:!0,children:Rt})})]})})})})}const gt=it=>{var ft,pt;const Rt=dt(),{mode:Ct="owners-only"}=it||{},{updateFilters:N,filters:V,queryParameters:{owners:xt}}=(0,D.nK)(),[wt,Ft]=(0,g.useState)(""),It=(0,g.useMemo)(()=>[xt].flat().filter(Boolean),[xt]);var Mt;const[Wt,St]=(0,g.useState)(It.length?It:(Mt=(ft=V.owners)===null||ft===void 0?void 0:ft.values)!==null&&Mt!==void 0?Mt:[]),[{value:Nt,loading:Xt},pe,ce]=at({mode:Ct,initialSelectedOwnersRefs:Wt});(0,y.s)(()=>pe({text:wt}),[wt,pe],250);const de=(Nt==null?void 0:Nt.items)||[];return(0,g.useEffect)(()=>{if(It.length){const zt=new P.N9(It);St(zt.values)}},[It]),(0,g.useEffect)(()=>{N({owners:Wt.length?new P.N9(Wt):void 0})},[Wt,N]),["user","group"].includes(((pt=V.kind)===null||pt===void 0?void 0:pt.value.toLocaleLowerCase("en-US"))||"")?null:(0,o.jsx)(d.A,{className:Rt.root,pb:1,pt:1,children:(0,o.jsxs)(f.A,{className:Rt.label,variant:"button",component:"label",children:["Owner",(0,o.jsx)(S.Ay,{multiple:!0,disableCloseOnSelect:!0,loading:Xt,options:de,value:Wt,getOptionSelected:(zt,qt)=>typeof qt=="string"?(0,i.U2)(zt)===qt:zt===qt,getOptionLabel:zt=>{const qt=typeof zt=="string"?ce.getEntity(zt)||(0,i.KU)(zt,{defaultKind:"group",defaultNamespace:"default"}):zt;return(0,x.Z)(qt,(0,x.S)(qt))},onChange:(zt,qt)=>{Ft(""),St(qt.map(ye=>{const ke=typeof ye=="string"?ye:(0,i.U2)(ye);return typeof ye!="string"&&ce.setEntity(ye),ke}))},filterOptions:zt=>zt,renderOption:(zt,{selected:qt})=>(0,o.jsx)(Tt,{entity:zt,isSelected:qt}),size:"small",popupIcon:(0,o.jsx)(h.A,{"data-testid":"owner-picker-expand"}),renderInput:zt=>(0,o.jsx)(v.A,{...zt,className:Rt.input,onChange:qt=>{Ft(qt.currentTarget.value)},variant:"outlined"}),ListboxProps:{onScroll:zt=>{const qt=zt.currentTarget;Math.abs(qt.scrollHeight-qt.clientHeight-qt.scrollTop)<1&&(Nt!=null&&Nt.cursor)&&pe({items:Nt.items,cursor:Nt.cursor})},"data-testid":"owner-picker-listbox"}})]})})}},8859:function(Y,T,t){"use strict";t.d(T,{z:function(){return g}});var o=t(31085),i=t(6820),d=t(72348),O=t(72072),m=t(9222),v=t(14041),f=t(29207),c=t(10394),C=t(71677),A=t(58837),w=t(3169);const h=(0,A.A)(P=>({root:{display:"inline-flex",alignItems:"center"},icon:{marginRight:P.spacing(.5),color:P.palette.text.secondary,lineHeight:0}}),{name:"CatalogReactEntityDisplayName"}),S=P=>{const{entityRef:y,hideIcon:j,disableTooltip:R,defaultKind:x,defaultNamespace:z}=P,_=h(),{primaryTitle:tt,secondaryTitle:K,Icon:W}=(0,w.f)(y,{defaultKind:x,defaultNamespace:z});let G=(0,o.jsx)(o.Fragment,{children:tt});return G=(0,o.jsxs)(c.A,{component:"span",className:_.root,children:[W&&!j?(0,o.jsx)(c.A,{component:"span",className:_.icon,children:(0,o.jsx)(W,{fontSize:"inherit"})}):null,G]}),K&&!R&&(G=(0,o.jsx)(C.Ay,{enterDelay:1500,title:K,children:G})),G},g=(0,v.forwardRef)((P,y)=>{const{entityRef:j,defaultKind:R,defaultNamespace:x,title:z,children:_,hideIcon:tt,...K}=P,W=D(P.entityRef);var G;const H=(G=_!=null?_:z)!==null&&G!==void 0?G:(0,o.jsx)(S,{entityRef:j,defaultKind:R,defaultNamespace:x,hideIcon:tt});return(0,o.jsx)(O.N_,{...K,ref:y,to:W,children:H})});function D(P){const y=(0,m.S)(f.s);let j,R,x;if(typeof P=="string"){const tt=(0,i.KU)(P);j=tt.kind,R=tt.namespace,x=tt.name}else"metadata"in P?(j=P.kind,R=P.metadata.namespace,x=P.metadata.name):(j=P.kind,R=P.namespace,x=P.name);j=j.toLocaleLowerCase("en-US");var z;R=(z=R==null?void 0:R.toLocaleLowerCase("en-US"))!==null&&z!==void 0?z:d.oQ;const _={kind:encodeURIComponent(j),namespace:encodeURIComponent(R),name:encodeURIComponent(x)};return y(_)}},34428:function(Y,T,t){"use strict";t.d(T,{i:function(){return m}});var o=t(31085),i=t(6820),d=t(14041),O=t(8859);function m(v){const{entityRefs:f,hideIcons:c,...C}=v;return(0,o.jsx)(o.Fragment,{children:f.map((A,w)=>{const h=typeof A=="string"?A:(0,i.U2)(A);return(0,o.jsxs)(d.Fragment,{children:[w>0&&", ",(0,o.jsx)(O.z,{...C,entityRef:A,hideIcon:c})]},`${w}.${h}`)})})}},90184:function(Y,T,t){"use strict";t.d(T,{S:function(){return O},Z:function(){return m}});var o=t(72348),i=t(46123),d=t.n(i);function O(v,f){const c=f==null?void 0:f.defaultKind;let C,A,w;return"metadata"in v?(C=v.kind,A=v.metadata.namespace,w=v.metadata.name):(C=v.kind,A=v.namespace,w=v.name),(A===void 0||A==="")&&(A=o.oQ),(f==null?void 0:f.defaultNamespace)!==void 0?(f==null?void 0:f.defaultNamespace)===A&&(A=void 0):A===o.oQ&&(A=void 0),C=C.toLocaleLowerCase("en-US"),C=c&&c.toLocaleLowerCase("en-US")===C?void 0:C,`${C?`${C}:`:""}${A?`${A}/`:""}${w}`}function m(v,f){for(const c of["spec.profile.displayName","metadata.title"]){const C=d()(v,c);if(C&&typeof C=="string")return C}return f}},91035:function(Y,T,t){"use strict";t.d(T,{m:function(){return f}});var o=t(31085),i=t(58837),d=t(14041),O=t(92822),m=t(50207);const v=(0,i.A)({input:{}},{name:"CatalogReactEntityTagPicker"}),f=c=>{const C=v();return(0,o.jsx)(m.y,{label:"Tags",name:"tags",path:"metadata.tags",Filter:O.q_,showCounts:c.showCounts,InputProps:{className:C.input}})}},67626:function(Y,T,t){"use strict";t.d(T,{y:function(){return Ot}});var o=t(31085),i=t(72427),d=t(65461),O=t(40703),m=t(58007),v=t(46423),f=t(65569),c=t(5951),C=t(26343),A=t(72501),w=t(58837),h=t(9684),S=t(80109),g=t(14041),D=t(92822),P=t(21405),y=t(16009),j=t(45250),R=t(73466),x=t(7341),z=t(26796),_=t(87290),tt=t(48899);function K(){const ht=(0,i.gf)(y.K),vt=(0,i.gf)(x.v),{filters:dt}=(0,P.nK)(),{value:st,loading:mt}=(0,R.A)(async()=>(await ht.getBackstageIdentity()).ownershipEntityRefs,[]),{user:Et,owners:Tt,...gt}=dt,it=(0,z.$3)((0,j.compact)(Object.values(gt))),[{value:ft,loading:pt},Rt]=(0,_.A)(async N=>{const V=W(N.owners,N.ownershipEntityRefs);if(V===void 0)return 0;const{["metadata.name"]:xt,...wt}=N.filter.filter,{totalItems:Ft}=await vt.queryEntities({...N.filter,filter:{...wt,"relations.ownedBy":V},limit:0});return Ft},[],{loading:!0});return(0,tt.A)(()=>{Object.keys(it.filter).length!==0&&st!==void 0&&Rt({ownershipEntityRefs:st,owners:Tt,filter:it})},[st,Tt,it]),{count:ft,loading:mt||pt,filter:(0,g.useMemo)(()=>D.tN.owned(st!=null?st:[]),[st]),ownershipEntityRefs:st}}function W(ht,vt){if(vt===void 0)return;var dt;const st=(dt=ht==null?void 0:ht.values)!==null&&dt!==void 0?dt:[];if(st.length){const mt=(0,j.intersection)(st,vt);return mt.length===0?void 0:mt}return vt}function G(){const ht=(0,i.gf)(x.v),{filters:vt}=(0,P.nK)(),dt=(0,g.useRef)(),st=(0,g.useMemo)(()=>{const{user:Tt,...gt}=vt,it=(0,j.compact)(Object.values(gt)),ft=(0,z.$3)(it),pt={...ft,limit:0};return Object.keys(ft.filter).length===0?(dt.current=void 0,dt.current):(0,j.isEqual)(pt,dt.current)?dt.current:(dt.current=pt,pt)},[vt]),{value:mt,loading:Et}=(0,R.A)(async()=>{if(st===void 0)return 0;const{totalItems:Tt}=await ht.queryEntities(st);return Tt},[st]);return{count:mt,loading:Et}}var H=t(6820),J=t(56889);function q(){const ht=(0,i.gf)(x.v),{filters:vt}=(0,P.nK)(),{starredEntities:dt}=(0,J.I)(),st=(0,g.useRef)(),mt=(0,g.useMemo)(()=>{const{user:it,...ft}=vt,pt=(0,j.compact)(Object.values(ft)),Rt=(0,z.$3)(pt),N={...Rt,filter:{...Rt.filter,["metadata.name"]:Array.from(dt).map(V=>(0,H.KU)(V).name)},limit:1e3};return(0,j.isEqual)(N,st.current)?st.current:(st.current=N,N)},[vt,dt]),{value:Et,loading:Tt}=(0,R.A)(async()=>dt.size?(await ht.queryEntities(mt)).items.map(ft=>(0,H.U2)({kind:ft.kind,namespace:ft.metadata.namespace,name:ft.metadata.name})).filter(ft=>dt.has(ft)).length:0,[mt,dt]),gt=(0,g.useMemo)(()=>D.tN.starred(Array.from(dt)),[dt]);return{count:Et,loading:Tt,filter:gt}}const yt=(0,w.A)(ht=>({root:{backgroundColor:"rgba(0, 0, 0, .11)",boxShadow:"none",margin:ht.spacing(1,0,1,0)},title:{margin:ht.spacing(1,0,0,1),textTransform:"uppercase",fontSize:12,fontWeight:"bold"},listIcon:{minWidth:30,color:ht.palette.text.primary},menuItem:{minHeight:ht.spacing(6)},groupWrapper:{margin:ht.spacing(1,1,2,1)}}),{name:"CatalogReactUserListPicker"});function at(ht){return[{name:"Personal",items:[{id:"owned",label:"Owned",icon:h.A},{id:"starred",label:"Starred",icon:S.A}]},{name:ht!=null?ht:"Company",items:[{id:"all",label:"All"}]}]}const Ot=ht=>{const{initialFilter:vt,availableFilters:dt}=ht,st=yt(),mt=(0,i.gf)(d.U);var Et;const Tt=(Et=mt.getOptionalString("organization.name"))!==null&&Et!==void 0?Et:"Company",{filters:gt,updateFilters:it,queryParameters:{kind:ft,user:pt}}=(0,P.nK)(),Rt=["starred","all"],Ct=at(Tt).map(ce=>({...ce,items:ce.items.filter(({id:de})=>["group","user"].some(zt=>zt===ft)?Rt.includes(de):!dt||dt.includes(de))})).filter(({items:ce})=>!!ce.length),{count:N,loading:V,filter:xt}=K(),{count:wt}=G(),{count:Ft,filter:It,loading:Mt}=q(),Wt=(0,g.useMemo)(()=>[pt].flat()[0],[pt]),[St,Nt]=(0,g.useState)(Wt!=null?Wt:vt),Xt=(0,g.useMemo)(()=>({all:wt,starred:Ft,owned:N}),[Ft,N,wt]);(0,g.useEffect)(()=>{Wt&&Nt(Wt)},[Wt]);const pe=V||Mt;return(0,g.useEffect)(()=>{!pe&&St&&St!=="all"&&Xt[St]===0&&Nt("all")},[pe,Xt,St,Nt]),(0,g.useEffect)(()=>{if(!St||pe)return;it({user:St==="owned"?xt:St==="starred"?It:D.tN.all()})},[St,It,xt,it,pe]),(0,o.jsx)(O.A,{className:st.root,children:Ct.map(ce=>(0,o.jsxs)(g.Fragment,{children:[(0,o.jsx)(A.A,{variant:"subtitle2",component:"span",className:st.title,children:ce.name}),(0,o.jsx)(O.A,{className:st.groupWrapper,children:(0,o.jsx)(m.A,{disablePadding:!0,dense:!0,role:"menu","aria-label":ce.name,children:ce.items.map(de=>{var zt,qt;return(0,o.jsxs)(C.A,{role:"none presentation",divider:!0,onClick:()=>Nt(de.id),selected:de.id===((zt=gt.user)===null||zt===void 0?void 0:zt.value),className:st.menuItem,disabled:Xt[de.id]===0,"data-testid":`user-picker-${de.id}`,tabIndex:0,ContainerProps:{role:"menuitem"},children:[de.icon&&(0,o.jsx)(v.A,{className:st.listIcon,children:(0,o.jsx)(de.icon,{fontSize:"small"})}),(0,o.jsx)(c.A,{children:(0,o.jsxs)(A.A,{variant:"body1",children:[de.label," "]})}),(0,o.jsx)(f.A,{children:(qt=Xt[de.id])!==null&&qt!==void 0?qt:"-"})]},de.id)})})})]},ce.name))})}},92822:function(Y,T,t){"use strict";t.d(T,{I5:function(){return A},Kf:function(){return g},N9:function(){return C},V3:function(){return c},gM:function(){return m},gZ:function(){return S},mT:function(){return D},qA:function(){return v},q_:function(){return f},tN:function(){return h},z:function(){return w}});var o=t(18990),i=t(51372),d=t(6820),O=t(67871);class m{getCatalogFilters(){return{kind:this.value}}toQueryValue(){return this.value}constructor(y){(0,o._)(this,"value",void 0),this.value=y}}class v{getTypes(){return Array.isArray(this.value)?this.value:[this.value]}getCatalogFilters(){return{"spec.type":this.getTypes()}}toQueryValue(){return this.getTypes()}constructor(y){(0,o._)(this,"value",void 0),this.value=y}}class f{filterEntity(y){return this.values.every(j=>{var R;return((R=y.metadata.tags)!==null&&R!==void 0?R:[]).includes(j)})}getCatalogFilters(){return{"metadata.tags":this.values}}toQueryValue(){return this.values}constructor(y){(0,o._)(this,"values",void 0),this.values=y}}class c{filterEntity(y){const j=this.toUpperArray(this.value.split(/\s/)),R=this.toUpperArray([y.metadata.tags]),x=this.toUpperArray([y.metadata.name,y.metadata.title]);for(const z of j)if(R.every(_=>_!==z)&&x.every(_=>!_.includes(z)))return!1;return!0}getFullTextFilters(){return{term:this.value,fields:["metadata.name","metadata.title","spec.profile.displayName"]}}toQueryValue(){return this.value}toUpperArray(y){return y.flat().filter(j=>!!j).map(j=>j.toLocaleUpperCase("en-US"))}constructor(y){(0,o._)(this,"value",void 0),this.value=y}}class C{getCatalogFilters(){return{"relations.ownedBy":this.values}}filterEntity(y){return this.values.some(j=>(0,O.t)(y,i.vv).some(R=>(0,d.U2)(R)===j))}toQueryValue(){return this.values}constructor(y){(0,o._)(this,"values",void 0),this.values=y.reduce((j,R)=>{try{return j.push((0,d.U2)((0,d.KU)(R,{defaultKind:"Group"}))),j}catch{return j}},[])}}class A{getCatalogFilters(){return{"spec.lifecycle":this.values}}filterEntity(y){return this.values.some(j=>{var R;return((R=y.spec)===null||R===void 0?void 0:R.lifecycle)===j})}toQueryValue(){return this.values}constructor(y){(0,o._)(this,"values",void 0),this.values=y}}class w{getCatalogFilters(){return{"metadata.namespace":this.values}}filterEntity(y){return this.values.some(j=>y.metadata.namespace===j)}toQueryValue(){return this.values}constructor(y){(0,o._)(this,"values",void 0),this.values=y}}class h{static owned(y){return new h("owned",y)}static all(){return new h("all")}static starred(y){return new h("starred",y)}getCatalogFilters(){if(this.value==="owned"){var y;return{"relations.ownedBy":(y=this.refs)!==null&&y!==void 0?y:[]}}if(this.value==="starred"){var j,R;return{"metadata.name":(R=(j=this.refs)===null||j===void 0?void 0:j.map(x=>(0,d.KU)(x).name))!==null&&R!==void 0?R:[]}}return{}}filterEntity(y){if(this.value==="starred"){var j,R;return(R=(j=this.refs)===null||j===void 0?void 0:j.includes((0,d.U2)(y)))!==null&&R!==void 0?R:!0}if(this.value==="owned"){var x;const _=(0,O.t)(y,i.vv);var z;return(z=(x=this.refs)===null||x===void 0?void 0:x.some(tt=>_.some(K=>(0,d.U2)(K)===tt)))!==null&&z!==void 0?z:!1}return!0}toQueryValue(){return this.value}constructor(y,j){(0,o._)(this,"value",void 0),(0,o._)(this,"refs",void 0),this.value=y,this.refs=j}}class S{filterEntity(y){switch(this.value){case"owned":return this.isOwnedEntity(y);case"starred":return this.isStarredEntity(y);default:return!0}}toQueryValue(){return this.value}constructor(y,j,R){(0,o._)(this,"value",void 0),(0,o._)(this,"isOwnedEntity",void 0),(0,o._)(this,"isStarredEntity",void 0),this.value=y,this.isOwnedEntity=j,this.isStarredEntity=R}}class g{getCatalogFilters(){return this.value?{"metadata.annotations.backstage.io/orphan":String(this.value)}:{}}filterEntity(y){var j;const R=(j=y.metadata.annotations)===null||j===void 0?void 0:j["backstage.io/orphan"];return R!==void 0&&this.value.toString()===R}constructor(y){(0,o._)(this,"value",void 0),this.value=y}}class D{filterEntity(y){var j,R;const x=(y==null||(R=y.status)===null||R===void 0||(j=R.items)===null||j===void 0?void 0:j.length)>0;return x!==void 0&&this.value===x}constructor(y){(0,o._)(this,"value",void 0),this.value=y}}},21405:function(Y,T,t){"use strict";t.d(T,{B9:function(){return D},nK:function(){return P}});var o=t(31085),i=t(45250),d=t.n(i),O=t(45810),m=t.n(O),v=t(14041),f=t(18690),c=t(87290),C=t(22771),A=t(71581),w=t(7341),h=t(26796),S=t(72427);const g=(0,v.createContext)(void 0),D=y=>{const j=(0,A.A)(),R=(0,S.gf)(w.v),[x,z]=(0,v.useState)({}),_=(0,f.zy)(),tt=y.pagination===!0||typeof y.pagination=="object",K=y.pagination&&typeof y.pagination=="object"&&typeof y.pagination.limit=="number"?y.pagination.limit:20,{queryParameters:W,cursor:G}=(0,v.useMemo)(()=>{const mt=m().parse(_.search,{ignoreQueryPrefix:!0});var Et;return{queryParameters:(Et=mt.filters)!==null&&Et!==void 0?Et:{},cursor:typeof mt.cursor=="string"?mt.cursor:void 0}},[_]),[H,J]=(0,v.useState)(G),[q,yt]=(0,v.useState)(()=>({appliedFilters:{},entities:[],backendEntities:[],pageInfo:tt?{}:void 0})),[{loading:at,error:Ot},ht]=(0,c.A)(async()=>{const mt=(0,i.compact)(Object.values(x)),Et=Object.keys(x).reduce((gt,it)=>{const ft=x[it];return ft!=null&&ft.toQueryValue&&(gt[it]=ft.toQueryValue()),gt},{});if(tt)if(H){if(H!==q.appliedCursor){const gt=(0,h.be)(mt),it=await R.queryEntities({cursor:H,limit:K});yt({appliedFilters:x,appliedCursor:H,backendEntities:it.items,entities:it.items.filter(gt),pageInfo:it.pageInfo,totalItems:it.totalItems})}}else{const gt=(0,h.be)(mt),it=(0,h.$3)(mt),ft=(0,h.$3)((0,i.compact)(Object.values(q.appliedFilters)));if(!(0,i.isEqual)(ft,it)){const pt=await R.queryEntities({...it,limit:K,orderFields:[{field:"metadata.name",order:"asc"}]});yt({appliedFilters:x,backendEntities:pt.items,entities:pt.items.filter(gt),pageInfo:pt.pageInfo,totalItems:pt.totalItems})}}else{const gt=(0,h.be)(mt),it=(0,h.Rr)(mt),ft=(0,h.Rr)((0,i.compact)(Object.values(q.appliedFilters)));if((0,i.isEqual)(ft,it)){const pt=q.backendEntities.filter(gt);yt({appliedFilters:x,backendEntities:q.backendEntities,entities:pt,totalItems:pt.length})}else{const pt=await R.getEntities({filter:it}),Rt=pt.items.filter(gt);yt({appliedFilters:x,backendEntities:pt.items,entities:Rt,totalItems:Rt.length})}}if(j()){var Tt;const gt=m().parse(_.search,{ignoreQueryPrefix:!0}),it=m().stringify({...gt,filters:Et,cursor:H},{addQueryPrefix:!0,arrayFormat:"repeat"}),ft=`${window.location.pathname}${it}`;(Tt=window.history)===null||Tt===void 0||Tt.replaceState(null,document.title,ft)}},[R,W,x,q,H,tt],{loading:!0});(0,C.A)(ht,10,[x,H]);const vt=(0,v.useCallback)(mt=>{J(void 0),z(Et=>{const Tt=typeof mt=="function"?mt(Et):mt;return{...Et,...Tt}})},[]),dt=(0,v.useMemo)(()=>{var mt,Et;if(!tt)return;const Tt=(mt=q.pageInfo)===null||mt===void 0?void 0:mt.prevCursor,gt=(Et=q.pageInfo)===null||Et===void 0?void 0:Et.nextCursor;return{prev:Tt?()=>J(Tt):void 0,next:gt?()=>J(gt):void 0}},[tt,q.pageInfo]),st=(0,v.useMemo)(()=>({filters:q.appliedFilters,entities:q.entities,backendEntities:q.backendEntities,updateFilters:vt,queryParameters:W,loading:at,error:Ot,pageInfo:dt,totalItems:q.totalItems}),[q,vt,W,at,Ot,dt]);return(0,o.jsx)(g.Provider,{value:st,children:y.children})};function P(){const y=(0,v.useContext)(g);if(!y)throw new Error("useEntityList must be used within EntityListProvider");return y}},56889:function(Y,T,t){"use strict";t.d(T,{I:function(){return f}});var o=t(6820),i=t(72427),d=t(14041),O=t(1394),m=t(18);function v(c){return typeof c=="string"?c:(0,o.U2)(c)}function f(){const c=(0,i.gf)(m.a),C=(0,O.A)((0,d.useMemo)(()=>c.starredEntitie$(),[c]),new Set),A=(0,d.useCallback)(h=>C.has(v(h)),[C]),w=(0,d.useCallback)(h=>c.toggleStarred(v(h)).then(),[c]);return{starredEntities:C,toggleStarredEntity:w,isStarredEntity:A}}},29207:function(Y,T,t){"use strict";t.d(T,{s:function(){return d}});var o=t(34569),i=t(63544);const d=(0,i.Q)("catalog:entity-route-ref",()=>(0,o.H)({id:"catalog:entity",params:["namespace","kind","name"]}));function O(m){var v,f;return{kind:m.kind.toLocaleLowerCase("en-US"),namespace:(f=(v=m.metadata.namespace)===null||v===void 0?void 0:v.toLocaleLowerCase("en-US"))!==null&&f!==void 0?f:DEFAULT_NAMESPACE,name:m.metadata.name}}},26796:function(Y,T,t){"use strict";t.d(T,{$3:function(){return d},Rr:function(){return O},be:function(){return m}});var o=t(92822);function i(v){return!!v.getFullTextFilters}function d(v){var f;const c=v.reduce((A,w)=>({...A,...w.getCatalogFilters?w.getCatalogFilters():{}}),{}),C=(f=v.find(i))===null||f===void 0?void 0:f.getFullTextFilters();return{filter:c,fullTextFilter:C}}function O(v){const f={};return v.forEach(c=>{var C;c instanceof o.q_||c instanceof o.N9||c instanceof o.I5||c instanceof o.z||c instanceof o.tN||c instanceof o.Kf||c instanceof o.V3||c instanceof o.gZ||Object.assign(f,((C=c.getCatalogFilters)===null||C===void 0?void 0:C.call(c))||{})}),f}function m(v){return f=>v.every(c=>!c.filterEntity||c.filterEntity(f))}},67871:function(Y,T,t){"use strict";t.d(T,{t:function(){return i}});var o=t(6820);function i(d,O,m){var v;let f=(d==null||(v=d.relations)===null||v===void 0?void 0:v.filter(c=>c.type===O).map(c=>(0,o.KU)(c.targetRef)))||[];return m!=null&&m.kind&&(f=f.filter(c=>c.kind.toLocaleLowerCase("en-US")===m.kind.toLocaleLowerCase("en-US"))),f}},95203:function(Y,T,t){"use strict";t.d(T,{qP:function(){return c},Zg:function(){return A},rQ:function(){return h},pS:function(){return w},UJ:function(){return C}});var o=t(18990),i=t(59598);let d=i.b,O=d;class m{toString(){return`routeRef{type=external,id=${this.id}}`}constructor(g,D,P){(0,o._)(this,"id",void 0),(0,o._)(this,"params",void 0),(0,o._)(this,"optional",void 0),(0,o._)(this,O,void 0),this.id=g,this.params=D,this.optional=P,this[d]="external"}}function v(S){var g;return new m(S.id,(g=S.params)!==null&&g!==void 0?g:[],!!S.optional)}var f=t(34569);const c=v({id:"create-component",optional:!0}),C=v({id:"view-techdoc",optional:!0,params:["namespace","kind","name"]}),A=v({id:"create-from-template",optional:!0,params:["namespace","templateName"]}),w=v({id:"catalog:unregister-redirect",optional:!0}),h=(0,f.H)({id:"catalog"})},54241:function(Y,T,t){"use strict";t.d(T,{b:function(){return o}});var o;(function(i){i.DENY="DENY",i.ALLOW="ALLOW",i.CONDITIONAL="CONDITIONAL"})(o||(o={}))},96824:function(Y,T,t){"use strict";t.d(T,{x:function(){return i}});var o=t(55309);const i=(0,o.y)({id:"plugin.permission.api"})},70734:function(Y,T,t){"use strict";t.d(T,{e:function(){return m}});var o=t(31085),i=t(14041),d=t(58837);const O=(0,d.A)(()=>({highlight:{}}),{name:"BackstageHighlightedSearchResultText"}),m=v=>{const{text:f,preTag:c,postTag:C}=v,A=O(),w=(0,i.useMemo)(()=>f.split(new RegExp(`(${c}.+?${C})`)),[C,c,f]);return(0,o.jsx)(o.Fragment,{children:w.map((h,S)=>h.includes(c)?(0,o.jsx)("mark",{className:A.highlight,children:h.replace(new RegExp(`${c}|${C}`,"g"),"")},S):h)})}},54560:function(Y,T,t){"use strict";t.d(T,{ec:function(){return C}});var o=t(31085),i=t(14041),d=t(93368),O=t(88758),m=t(8109);const v="search.results.list.items.extensions.v1",f=(h,S)=>{for(const g of h){if(!isValidElement(g))continue;const D=getComponentData(g,v);if(D!=null&&D(S))return cloneElement(g,{rank:S.rank,highlight:S.highlight,result:S.document,...g.props})}return null},c=h=>{const{rank:S,result:g,noTrack:D,children:P,alignItems:y="flex-start",...j}=h,R=(0,d.s)(),x=(0,i.useCallback)(()=>{D||g&&R.captureEvent("discover",g.title,{attributes:{to:g.location},value:S})},[S,g,D,R]);return(0,o.jsx)(m.A,{divider:!0,alignItems:y,onClickCapture:x,...j,children:P})},C=h=>{const{name:S,component:g,predicate:D=()=>!0}=h;return(0,O.zZ)({name:S,component:{lazy:()=>g().then(P=>y=>(0,o.jsx)(c,{rank:y.rank,result:y.result,noTrack:y.noTrack,children:(0,i.createElement)(P,y)}))},data:{[v]:D}})},A=h=>{const S=useElementFilter(h,g=>g.selectByComponentData({key:v}).getElements(),[h]);return useCallback((g,D)=>{const P=f(S,g);return _jsx(Fragment,{children:P!=null?P:_jsx(c,{rank:g.rank,result:g.document,children:_jsx(DefaultResultListItem,{rank:g.rank,highlight:g.highlight,result:g.document})})},D)},[S])},w=h=>{const{results:S,children:g,...D}=h,P=A(g);return _jsx(List,{...D,children:S.map(P)})}},72020:function(Y,T,t){"use strict";t.d(T,{AF:function(){return c},Hr:function(){return w},Wm:function(){return f},YR:function(){return D},po:function(){return C}});var o=t(31085),i=t(14041),d=t(18690),O=t(19402),m=t(88758),v=t(82442);const f="techdocs.addons.addon.v1",c="techdocs.addons.wrapper.v1",C=()=>null;(0,O.h)(C,c,!0);const A=P=>`${f}.${P.toLocaleLowerCase("en-US")}`;function w(P){const{name:y,component:j}=P;return(0,m.zZ)({name:y,component:{sync:R=>(0,o.jsx)(j,{...R})},data:{[f]:P,[A(y)]:!0}})}const h=(P,y)=>P.selectByComponentData({key:y}).getElements()[0],S=P=>P.selectByComponentData({key:c}).selectByComponentData({key:f}),g=P=>P.selectByComponentData({key:c}).findComponentData({key:f}),D=()=>{const P=(0,d.P1)(),y=(0,v.O)(P,S),j=(0,v.O)(P,g),R=(0,i.useCallback)(_=>{if(!y||!_)return null;const tt=A(_.name);var K;return(K=h(y,tt))!==null&&K!==void 0?K:null},[y]),x=(0,i.useCallback)(_=>{const tt=j.find(K=>K.name===_);return tt?R(tt):null},[j,R]),z=(0,i.useCallback)(_=>{const tt=j.filter(K=>K.location===_);return tt.length?tt.map(R):null},[j,R]);return{renderComponentByName:x,renderComponentsByLocation:z}}},26679:function(Y,T,t){"use strict";t.d(T,{l:function(){return i},s:function(){return d}});var o=t(55309);const i=(0,o.y)({id:"plugin.techdocs.service"}),d=(0,o.y)({id:"plugin.techdocs.storageservice"})},86892:function(Y,T,t){"use strict";t.d(T,{R:function(){return P},V:function(){return y}});var o=t(31085),i=t(14041),d=t(73466),O=t(28966),m=t(6820),v=t(43836),f=t(10602),c=t(72427),C=t(65461),A=t(25862),w=t(26679);function h(j,R){return R.getOptionalBoolean("techdocs.legacyUseCaseSensitiveTripletPaths")||(j.kind=j.kind.toLocaleLowerCase(),j.name=j.name.toLocaleLowerCase(),j.namespace=j.namespace.toLocaleLowerCase()),j}const S=(j,R)=>(0,m.U2)(j)===(0,m.U2)(R),g={title:"",subtitle:"",setTitle:()=>{},setSubtitle:()=>{},setShadowRoot:()=>{},metadata:{loading:!0},entityMetadata:{loading:!0},entityRef:{kind:"",name:"",namespace:""}},D=(0,v.tK)("techdocs-reader-page-context"),P=(0,i.memo)(j=>{const{entityRef:R,children:x}=j,z=(0,c.gf)(w.l),_=(0,c.gf)(C.U),tt=(0,d.A)(async()=>z.getEntityMetadata(R),[R]),K=(0,O.A)(async()=>z.getTechDocsMetadata(R),[R]),[W,G]=(0,i.useState)(g.title),[H,J]=(0,i.useState)(g.subtitle),[q,yt]=(0,i.useState)(g.shadowRoot);(0,i.useEffect)(()=>{q&&!K.value&&!K.loading&&K.retry()},[K.value,K.loading,q,K.retry,K]);const at={metadata:K,entityRef:h(R,_),entityMetadata:tt,shadowRoot:q,setShadowRoot:yt,title:W,setTitle:G,subtitle:H,setSubtitle:J},Ot=(0,f.B)({1:at});return(0,o.jsx)(A.Ig,{attributes:{entityRef:(0,m.U2)(R)},children:(0,o.jsx)(D.Provider,{value:Ot,children:x instanceof Function?x(at):x})})},(j,R)=>S(j.entityRef,R.entityRef)),y=()=>{const j=(0,i.useContext)(D);if(j===void 0)return g;const R=j.atVersion(1);if(R===void 0)throw new Error("No context found for version 1.");return R}},99730:function(Y,T,t){"use strict";t.d(T,{e:function(){return o}});const o=Object.freeze({Header:"Header",Subheader:"Subheader",Settings:"Settings",PrimarySidebar:"PrimarySidebar",SecondarySidebar:"SecondarySidebar",Content:"Content"})},95768:function(Y,T,t){"use strict";t.d(T,{V:function(){return o}});function o(i,d){return d.getOptionalBoolean("techdocs.legacyUseCaseSensitiveTripletPaths")?i:i.toLocaleLowerCase("en-US")}},85920:function(Y,T,t){"use strict";t.d(T,{K:function(){return K}});var o=t(31085),i=t(14041),d=t(26280),O=t(59428),m=t(27586),v=t(21405),f=t(54203),c=t(67626),C=t(72987),A=t(91035),w=t(81859),h=t(86519);class S{getCatalogFilters(){return{"metadata.annotations.backstage.io/techdocs-ref":h.c}}}const g=()=>{const{updateFilters:W}=(0,v.nK)();return(0,i.useEffect)(()=>{W({techdocs:new S})},[W]),null};var D=t(36338),P=t(45250),y=t(88640),j=t(77310),R=t(56889),x=t(27125),z=t(84295),_=t(42717);const tt=W=>{var G;const{columns:H,actions:J,options:q}=W,{loading:yt,error:at,entities:Ot,filters:ht}=(0,v.nK)(),{isStarredEntity:vt,toggleStarredEntity:dt}=(0,R.I)(),[,st]=(0,D.A)();var mt;const Et=(0,P.capitalize)((mt=(G=ht.user)===null||G===void 0?void 0:G.value)!==null&&mt!==void 0?mt:"all"),Tt=[z.f.createCopyDocsUrlAction(st),z.f.createStarEntityAction(vt,dt)];return at?(0,o.jsx)(y.B,{severity:"error",title:"Could not load available documentation.",children:(0,o.jsx)(j.z,{language:"text",text:at.toString()})}):(0,o.jsx)(x.o,{title:Et,entities:Ot,loading:yt,actions:J||Tt,columns:H,options:q})};tt.columns=_.B,tt.actions=z.f;const K=W=>{const{initialFilter:G="owned",columns:H,actions:J}=W;return(0,o.jsx)(w.S,{children:(0,o.jsxs)(d.U,{children:[(0,o.jsx)(O.d,{title:"",children:(0,o.jsx)(m.Y,{children:"Discover documentation in your ecosystem."})}),(0,o.jsx)(v.B9,{children:(0,o.jsxs)(f.GI,{children:[(0,o.jsxs)(f.GI.Filters,{children:[(0,o.jsx)(g,{}),(0,o.jsx)(c.y,{initialFilter:G}),(0,o.jsx)(C.t,{}),(0,o.jsx)(A.m,{})]}),(0,o.jsx)(f.GI.Content,{children:(0,o.jsx)(tt,{actions:J,columns:H})})]})})]})})}},27125:function(Y,T,t){"use strict";t.d(T,{o:function(){return y}});var o=t(31085),i=t(14041),d=t(36338),O=t(9222),m=t(72427),v=t(65461),f=t(51372),c=t(67871),C=t(90184),A=t(82779),w=t(14209),h=t(44186),S=t(73896),g=t(84295),D=t(42717),P=t(95768);const y=j=>{const{entities:R,title:x,loading:z,columns:_,actions:tt,options:K}=j,[,W]=(0,d.A)(),G=(0,O.S)(A.Oc),H=(0,m.gf)(v.U);if(!R)return null;const J=R.map(ht=>{const vt=(0,c.t)(ht,f.vv);var dt;return{entity:ht,resolved:{docsUrl:G({namespace:(0,P.V)((dt=ht.metadata.namespace)!==null&&dt!==void 0?dt:"default",H),kind:(0,P.V)(ht.kind,H),name:(0,P.V)(ht.metadata.name,H)}),ownedByRelations:vt,ownedByRelationsTitle:vt.map(st=>(0,C.S)(st,{defaultKind:"group"})).join(", ")}}}),q=[D.B.createNameColumn(),D.B.createOwnerColumn(),D.B.createKindColumn(),D.B.createTypeColumn()],yt=[g.f.createCopyDocsUrlAction(W)],at=20,Ot=J&&J.length>at;return(0,o.jsx)(o.Fragment,{children:z||J&&J.length>0?(0,o.jsx)(w.X,{isLoading:z,options:{paging:Ot,pageSize:at,search:!0,actionsColumnIndex:-1,...K},data:J,columns:_||q,actions:tt||yt,title:x?`${x} (${J.length})`:`All (${J.length})`}):(0,o.jsx)(h.p,{missing:"data",title:"No documents to show",description:"Create your own document. Check out our Getting Started Information",action:(0,o.jsx)(S.z,{color:"primary",to:"https://backstage.io/docs/features/techdocs/getting-started",variant:"contained",children:"DOCS"})})})};y.columns=D.B,y.actions=g.f},84295:function(Y,T,t){"use strict";t.d(T,{f:function(){return c}});var o=t(31085),i=t(14041),d=t(55290),O=t(87051),m=t(80109),v=t(15303);const f=(0,O.A)({root:{color:"#f3ba37"}})(m.A),c={createCopyDocsUrlAction(C){return A=>({icon:()=>(0,o.jsx)(d.A,{fontSize:"small"}),tooltip:"Click to copy documentation link to clipboard",onClick:()=>C(`${window.location.origin}${A.resolved.docsUrl}`)})},createStarEntityAction(C,A){return w=>{const h=w.entity,S=C(h);return{cellStyle:{paddingLeft:"1em"},icon:()=>S?(0,o.jsx)(f,{}):(0,o.jsx)(v.A,{}),tooltip:S?"Remove from favorites":"Add to favorites",onClick:()=>A(h)}}}}},42717:function(Y,T,t){"use strict";t.d(T,{B:function(){return A}});var o=t(31085),i=t(14041),d=t(10394),O=t(58837);const m=(0,O.A)(w=>({value:{marginBottom:w.spacing(.75)},subvalue:{color:w.palette.textSubtle,fontWeight:"normal"}}),{name:"BackstageSubvalueCell"});function v(w){const{value:h,subvalue:S}=w,g=m();return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(d.A,{className:g.value,children:h}),(0,o.jsx)(d.A,{className:g.subvalue,children:S})]})}var f=t(72072),c=t(34428);function C(w){return w.metadata.title||w.metadata.name}const A={createNameColumn(){return{title:"Document",field:"entity.metadata.name",highlight:!0,render:w=>(0,o.jsx)(v,{value:(0,o.jsx)(f.N_,{to:w.resolved.docsUrl,children:C(w.entity)}),subvalue:w.entity.metadata.description})}},createOwnerColumn(){return{title:"Owner",field:"resolved.ownedByRelationsTitle",render:({resolved:w})=>(0,o.jsx)(c.i,{entityRefs:w.ownedByRelations,defaultKind:"group"})}},createKindColumn(){return{title:"Kind",field:"entity.kind"}},createTypeColumn(){return{title:"Type",field:"entity.spec.type"}}}},81859:function(Y,T,t){"use strict";t.d(T,{S:function(){return v}});var o=t(31085),i=t(14041),d=t(27155),O=t(72427),m=t(65461);const v=f=>{const{children:c}=f,C=(0,O.gf)(m.U);var A;const w=`Documentation available in ${(A=C.getOptionalString("organization.name"))!==null&&A!==void 0?A:"Backstage"}`;return(0,o.jsx)(d.d,{title:"Documentation",subtitle:w,themeId:"documentation",children:c})}},39278:function(Y,T,t){"use strict";t.d(T,{$j:function(){return z},Wj:function(){return _},Ju:function(){return y}});var o=t(26679),i=t(18990),d=t(70835),O=t(97142),m=t(50165);class v{async getCookie(){const G=`${await this.getApiOrigin()}/cookie`,H=await this.fetchApi.fetch(`${G}`,{credentials:"include"});if(!H.ok)throw await d.o.fromResponse(H);return await H.json()}async getApiOrigin(){return await this.discoveryApi.getBaseUrl("techdocs")}async getTechDocsMetadata(W){const{kind:G,namespace:H,name:J}=W,yt=`${await this.getApiOrigin()}/metadata/techdocs/${H}/${G}/${J}`,at=await this.fetchApi.fetch(`${yt}`);if(!at.ok)throw await d.o.fromResponse(at);return await at.json()}async getEntityMetadata(W){const{kind:G,namespace:H,name:J}=W,yt=`${await this.getApiOrigin()}/metadata/entity/${H}/${G}/${J}`,at=await this.fetchApi.fetch(`${yt}`);if(!at.ok)throw await d.o.fromResponse(at);return await at.json()}constructor(W){(0,i._)(this,"configApi",void 0),(0,i._)(this,"discoveryApi",void 0),(0,i._)(this,"fetchApi",void 0),this.configApi=W.configApi,this.discoveryApi=W.discoveryApi,this.fetchApi=W.fetchApi}}class f{async getApiOrigin(){return await this.discoveryApi.getBaseUrl("techdocs")}async getStorageUrl(){var W;return(W=this.configApi.getOptionalString("techdocs.storageUrl"))!==null&&W!==void 0?W:`${await this.discoveryApi.getBaseUrl("techdocs")}/static/docs`}async getBuilder(){return this.configApi.getOptionalString("techdocs.builder")||"local"}async getEntityDocs(W,G){const{kind:H,namespace:J,name:q}=W,at=`${await this.getStorageUrl()}/${J}/${H}/${q}/${G}`,Ot=await this.fetchApi.fetch(`${at.endsWith("/")?at:`${at}/`}index.html`);let ht="";switch(Ot.status){case 404:throw ht="Page not found. ",G||(ht+="This could be because there is no index.md file in the root of the docs directory of this repository."),new O.m_(ht);case 500:throw ht="Could not generate documentation or an error in the TechDocs backend. ",new Error(ht);default:break}return Ot.text()}async syncEntityDocs(W,G=()=>{}){const{kind:H,namespace:J,name:q}=W,at=`${await this.getApiOrigin()}/sync/${J}/${H}/${q}`,{token:Ot}=await this.identityApi.getCredentials();return new Promise((ht,vt)=>{const dt=new m.EventSourcePolyfill(at,{withCredentials:!0,headers:Ot?{Authorization:`Bearer ${Ot}`}:{}});dt.addEventListener("log",st=>{st.data&&G(JSON.parse(st.data))}),dt.addEventListener("finish",st=>{let mt=!1;st.data&&({updated:mt}=JSON.parse(st.data)),ht(mt?"updated":"cached")}),dt.onerror=st=>{switch(dt.close(),st.status){case 404:vt(new O.m_(st.message));return;default:vt(new Error(st.data));return}}})}async getBaseUrl(W,G,H){const{kind:J,namespace:q,name:yt}=G,Ot=`${await this.getApiOrigin()}/static/docs/${q}/${J}/${yt}/${H}`;return new URL(W,Ot.endsWith("/")?Ot:`${Ot}/`).toString()}constructor(W){(0,i._)(this,"configApi",void 0),(0,i._)(this,"discoveryApi",void 0),(0,i._)(this,"identityApi",void 0),(0,i._)(this,"fetchApi",void 0),this.configApi=W.configApi,this.discoveryApi=W.discoveryApi,this.identityApi=W.identityApi,this.fetchApi=W.fetchApi}}var c=t(82779),C=t(9803),A=t(12935),w=t(65461),h=t(57405),S=t(16009),g=t(70795),D=t(88758),P=t(54560);const y=(0,C.i)({id:"techdocs",apis:[(0,A.b)({api:o.s,deps:{configApi:w.U,discoveryApi:h.I,identityApi:S.K,fetchApi:g.a},factory:({configApi:K,discoveryApi:W,identityApi:G,fetchApi:H})=>new f({configApi:K,discoveryApi:W,identityApi:G,fetchApi:H})}),(0,A.b)({api:o.l,deps:{configApi:w.U,discoveryApi:h.I,fetchApi:g.a},factory:({configApi:K,discoveryApi:W,fetchApi:G})=>new v({configApi:K,discoveryApi:W,fetchApi:G})})],routes:{root:c.rQ,docRoot:c.Oc,entityContent:c.Ri}}),j=y.provide((0,D.QJ)({name:"TechdocsPage",component:()=>t.e(9605).then(t.bind(t,29605)).then(K=>K.Router),mountPoint:c.rQ})),R=y.provide((0,D.QJ)({name:"EntityTechdocsContent",component:()=>t.e(9605).then(t.bind(t,29605)).then(K=>K.EmbeddedDocsRouter),mountPoint:c.Ri})),x=y.provide((0,D.QJ)({name:"TechDocsCustomHome",component:()=>t.e(4487).then(t.bind(t,94487)).then(K=>K.TechDocsCustomHome),mountPoint:c.rQ})),z=y.provide((0,D.QJ)({name:"TechDocsIndexPage",component:()=>t.e(5788).then(t.bind(t,85788)).then(K=>K.TechDocsIndexPage),mountPoint:c.rQ})),_=y.provide((0,D.QJ)({name:"TechDocsReaderPage",component:()=>t.e(4036).then(t.bind(t,84036)).then(K=>K.TechDocsReaderPage),mountPoint:c.Oc})),tt=y.provide((0,P.ec)({name:"TechDocsSearchResultListItem",component:()=>Promise.resolve().then(t.bind(t,27698)).then(K=>K.TechDocsSearchResultListItem),predicate:K=>K.type==="techdocs"}))},16203:function(Y,T,t){"use strict";t.d(T,{p:function(){return Dt}});var o=t(31085),i=t(14041),d=t(42899),O=t(58837),m=t(86892),v=t(9394),f=t(91360),c=t(22856),C=t(68146);const A="TECH_DOCS_SHADOW_DOM_STYLE_LOAD",w=p=>{(0,i.useEffect)(()=>{if(!p)return()=>{};const I=p.querySelectorAll('head > link[rel="stylesheet"]');var $;let F=($=I==null?void 0:I.length)!==null&&$!==void 0?$:0;const Q=new CustomEvent(A);if(!F)return p.dispatchEvent(Q),()=>{};const X=()=>{--F===0&&p.dispatchEvent(Q)};return I==null||I.forEach(lt=>{lt.addEventListener("load",X)}),()=>{I==null||I.forEach(lt=>{lt.removeEventListener("load",X)})}},[p])},h=p=>{const[I,$]=(0,i.useState)(!1);return(0,i.useEffect)(()=>{if(!p)return()=>{};$(!0);const F=p.style;F.setProperty("opacity","0");const Q=()=>{$(!1),F.setProperty("opacity","1")};return p.addEventListener(A,Q),()=>{p.removeEventListener(A,Q)}},[p]),I},S=p=>{const{element:I,onAppend:$,children:F}=p,[Q,X]=(0,i.useState)((0,v.vt)({...(0,c.A)(),insertionPoint:void 0}));w(I);const lt=h(I),bt=(0,i.useCallback)(Bt=>{if(!I||!Bt)return;X((0,v.vt)({...(0,c.A)(),insertionPoint:I.querySelector("head")||void 0}));let kt=Bt.shadowRoot;kt||(kt=Bt.attachShadow({mode:"open"})),kt.replaceChildren(I),typeof $=="function"&&$(kt)},[I,$]);return(0,o.jsxs)(o.Fragment,{children:[lt&&(0,o.jsx)(C.k,{}),(0,o.jsxs)(f.Ay,{jss:Q,sheetsManager:new Map,children:[(0,o.jsx)("div",{ref:bt,"data-testid":"techdocs-native-shadowroot"}),F]})]})};var g=t(12784);const D=()=>{const{shadowRoot:p}=(0,m.V)();return p},P=p=>{const I=D();return I?p.map($=>I==null?void 0:I.querySelectorAll($)).filter($=>$.length).map($=>Array.from($)).flat():[]},y=p=>p.toString()&&p.rangeCount&&p.getRangeAt(0).getBoundingClientRect().top,j=(p=0)=>{const I=D(),[$,F]=useState(null),Q=useMemo(()=>debounce(()=>{const X=I,lt=X.getSelection?X.getSelection():document.getSelection();lt&&y(lt)?F(lt):F(null)},p),[I,F,p]);return useEffect(()=>(window.document.addEventListener("selectionchange",Q),()=>{Q.cancel(),window.document.removeEventListener("selectionchange",Q)}),[Q]),$};var R=t(12173),x=t(26280),z=t(45250),_=t(73466),tt=t(5877),K=t(43836),W=t(10602),G=t(72427),H=t(93368),J=t(25862),q=t(65461),yt=t(55309);const at=(0,yt.y)({id:"plugin.search.queryservice"});class Ot{query(){return Promise.resolve(this.mockedResults||{results:[]})}constructor(I){_define_property(this,"mockedResults",void 0),this.mockedResults=I}}const ht=(0,K.tK)("search-context"),vt=()=>{const p=(0,i.useContext)(ht);if(!p)throw new Error("useSearch must be used within a SearchContextProvider");const I=p.atVersion(1);if(!I)throw new Error("No SearchContext v1 found");return I},dt=()=>(0,i.useContext)(ht)!==void 0,st={term:"",types:[],filters:{},pageLimit:void 0,pageCursor:void 0},mt=(p=st)=>{var I,$,F,Q;const X=(0,G.gf)(at),lt=(0,H.s)(),[bt,Bt]=(0,i.useState)(p.term),[kt,Zt]=(0,i.useState)(p.types),[Ht,Pt]=(0,i.useState)(p.filters),[he,Ee]=(0,i.useState)(p.pageLimit),[Jt,_t]=(0,i.useState)(p.pageCursor),le=(0,tt.A)(bt),Ae=(0,tt.A)(Ht),Lt=(0,_.A)(async()=>{const ve=await X.query({term:bt,types:kt,filters:Ht,pageLimit:he,pageCursor:Jt});if(bt){var Be,ie;lt.captureEvent("search",bt,{value:(ie=(Be=Lt.value)===null||Be===void 0?void 0:Be.numberOfResults)!==null&&ie!==void 0?ie:void 0})}return ve},[bt,kt,Ht,he,Jt]),Vt=!Lt.loading&&!Lt.error&&((I=Lt.value)===null||I===void 0?void 0:I.nextPageCursor),te=!Lt.loading&&!Lt.error&&(($=Lt.value)===null||$===void 0?void 0:$.previousPageCursor),xe=(0,i.useCallback)(()=>{var ve;_t((ve=Lt.value)===null||ve===void 0?void 0:ve.nextPageCursor)},[(F=Lt.value)===null||F===void 0?void 0:F.nextPageCursor]),Le=(0,i.useCallback)(()=>{var ve;_t((ve=Lt.value)===null||ve===void 0?void 0:ve.previousPageCursor)},[(Q=Lt.value)===null||Q===void 0?void 0:Q.previousPageCursor]);return(0,i.useEffect)(()=>{le!==void 0&&bt!==le&&_t(void 0)},[bt,le,_t]),(0,i.useEffect)(()=>{Ae!==void 0&&!(0,z.isEqual)(Ht,Ae)&&_t(void 0)},[Ht,Ae,_t]),{result:Lt,term:bt,setTerm:Bt,types:kt,setTypes:Zt,filters:Ht,setFilters:Pt,pageLimit:he,setPageLimit:Ee,pageCursor:Jt,setPageCursor:_t,fetchNextPage:Vt?xe:void 0,fetchPreviousPage:te?Le:void 0}},Et=p=>{const{initialState:I,children:$}=p,F=mt(I);return(0,o.jsx)(J.Ig,{attributes:{searchTypes:F.types.sort().join(",")},children:(0,o.jsx)(ht.Provider,{value:(0,W.B)({1:F}),children:$})})},Tt=p=>{const{initialState:I,inheritParentContextIfAvailable:$,children:F}=p,Q=dt(),X=(0,G.gf)(q.U),lt=I!=null?I:{},bt=X.has("search.query.pageLimit")?{pageLimit:X.getNumber("search.query.pageLimit")}:{},Bt={...st,...lt,...bt};return Q&&$?(0,o.jsx)(o.Fragment,{children:F}):(0,o.jsx)(Et,{initialState:Bt,children:F})};var gt=t(78467),it=t(20577),ft=t(29365),pt=t(34839),Rt=t(16249),Ct=t(64947),N=t(45917),V=t(22771);function xt(p){return(0,i.forwardRef)((I,$)=>(0,o.jsx)(Tt,{inheritParentContextIfAvailable:!0,children:(0,o.jsx)(p,{...I,ref:$})}))}const wt=xt((0,i.forwardRef)((p,I)=>{const{onChange:$,onKeyDown:F=()=>{},onClear:Q=()=>{},onSubmit:X=()=>{},debounceTime:lt=200,clearButton:bt=!0,fullWidth:Bt=!0,value:kt,label:Zt,placeholder:Ht,inputProps:Pt={},InputProps:he={},endAdornment:Ee,...Jt}=p,_t=(0,G.gf)(q.U),[le,Ae]=(0,i.useState)(""),Lt=(0,i.useRef)("");(0,i.useEffect)(()=>{Ae(ie=>ie===Lt.current?String(kt):ie)},[kt,Lt]),(0,V.A)(()=>{Lt.current=le,$(le)},lt,[le]);const Vt=(0,i.useCallback)(ie=>{Ae(ie.target.value)},[Ae]),te=(0,i.useCallback)(ie=>{F&&F(ie),X&&ie.key==="Enter"&&X()},[F,X]),xe=(0,i.useCallback)(()=>{Lt.current="",$(""),Ae(""),Q&&Q()},[$,Q]),Le=Zt?void 0:"Search",Fe=Ht!=null?Ht:`Search in ${_t.getOptionalString("app.title")||"Backstage"}`,ve=(0,o.jsx)(pt.A,{position:"start",children:(0,o.jsx)(ft.A,{"aria-label":"Query",size:"small",disabled:!0,children:(0,o.jsx)(N.A,{})})}),Be=(0,o.jsx)(pt.A,{position:"end",children:(0,o.jsx)(Ct.A,{"aria-label":"Clear",size:"small",onClick:xe,onKeyDown:ie=>{ie.key==="Enter"&&ie.stopPropagation()},children:"Clear"})});return(0,o.jsx)(Rt.A,{id:"search-bar-text-field","data-testid":"search-bar-next",variant:"outlined",margin:"normal",inputRef:I,value:le,label:Zt,placeholder:Fe,InputProps:{startAdornment:ve,endAdornment:bt?Be:Ee,...he},inputProps:{"aria-label":Le,...Pt},fullWidth:Bt,onChange:Vt,onKeyDown:te,...Jt})})),Ft=xt((0,i.forwardRef)((p,I)=>{const{value:$="",onChange:F,...Q}=p,{term:X,setTerm:lt}=vt();(0,i.useEffect)(()=>{$&&lt(String($))},[$,lt]);const bt=(0,i.useCallback)(Bt=>{F?F(Bt):lt(Bt)},[F,lt]);return(0,o.jsx)(J.Ig,{attributes:{pluginId:"search",extension:"SearchBar"},children:(0,o.jsx)(wt,{...Q,ref:I,value:X,onChange:bt})})})),It=(0,O.A)(p=>({loading:{right:p.spacing(1),position:"absolute"}})),Mt=p=>I=>(0,o.jsx)(Tt,{inheritParentContextIfAvailable:!0,children:(0,o.jsx)(p,{...I})}),Wt=()=>{const p=It();return(0,o.jsx)(gt.A,{className:p.loading,"data-testid":"search-autocomplete-progressbar",color:"inherit",size:20})},St=Mt(function(I){const{loading:$,value:F,onChange:Q=()=>{},options:X=[],getOptionLabel:lt=Lt=>String(Lt),inputPlaceholder:bt,inputDebounceTime:Bt,freeSolo:kt=!0,fullWidth:Zt=!0,clearOnBlur:Ht=!1,"data-testid":Pt="search-autocomplete",...he}=I,{setTerm:Ee}=vt(),Jt=(0,i.useCallback)(Lt=>Lt?typeof Lt=="string"?Lt:lt(Lt):"",[lt]),_t=(0,i.useMemo)(()=>Jt(F),[F,Jt]),le=(0,i.useCallback)((Lt,Vt,te,xe)=>{Ee(Jt(Vt)),Q(Lt,Vt,te,xe)},[Jt,Ee,Q]),Ae=(0,i.useCallback)(({InputProps:{ref:Lt,className:Vt,endAdornment:te},InputLabelProps:xe,...Le})=>(0,o.jsx)(Ft,{...Le,ref:Lt,clearButton:!1,value:_t,placeholder:bt,debounceTime:Bt,endAdornment:$?(0,o.jsx)(Wt,{}):te,InputProps:{className:Vt}}),[$,_t,bt,Bt]);return(0,o.jsx)(it.Ay,{...he,"data-testid":Pt,value:F,onChange:le,options:X,getOptionLabel:lt,renderInput:Ae,freeSolo:kt,fullWidth:Zt,clearOnBlur:Ht})});var Nt=t(18690),Xt=t(27698);const pe=p=>p==null?void 0:p.document,ce=p=>{const{entityId:I,entityTitle:$,debounceTime:F=150}=p,[Q,X]=(0,i.useState)(!1),lt=(0,Nt.Zp)(),{setFilters:bt,result:{loading:Bt,value:kt}}=vt(),[Zt,Ht]=(0,i.useState)([]);(0,i.useEffect)(()=>{let _t=!0;if(_t&&kt){const le=kt.results.slice(0,10);Ht(le)}return()=>{_t=!1}},[Bt,kt]);const{kind:Pt,name:he,namespace:Ee}=I;(0,i.useEffect)(()=>{bt(_t=>({..._t,kind:Pt,namespace:Ee,name:he}))},[Pt,Ee,he,bt]);const Jt=(_t,le)=>{if(pe(le)){const{location:Ae}=le.document;lt(Ae)}};return(0,o.jsx)(St,{"data-testid":"techdocs-search-bar",size:"small",open:Q,getOptionLabel:()=>"",filterOptions:_t=>_t,onClose:()=>{X(!1)},onFocus:()=>{X(!0)},onChange:Jt,blurOnSelect:!0,noOptionsText:"No results found",value:null,options:Zt,renderOption:({document:_t,highlight:le})=>(0,o.jsx)(Xt.TechDocsSearchResultListItem,{result:_t,lineClamp:3,asListItem:!1,asLink:!1,title:_t.title,highlight:le}),loading:Bt,inputDebounceTime:F,inputPlaceholder:`Search ${$||I.name} docs`,freeSolo:!1})},de=p=>{const I={term:"",types:["techdocs"],pageCursor:"",filters:p.entityId};return(0,o.jsx)(Tt,{initialState:I,children:(0,o.jsx)(ce,{...p})})};var zt=t(74219),qt=t(82266);const ye=(0,i.lazy)(()=>Promise.all([t.e(3308),t.e(9234)]).then(t.bind(t,99234)).then(p=>({default:p.RealLogViewer})));function ke(p){const{Progress:I}=(0,qt.n)().getComponents();return(0,o.jsx)(i.Suspense,{fallback:(0,o.jsx)(I,{}),children:(0,o.jsx)(ye,{...p})})}var Ue=t(73845),Ge=t(72501),Te=t(12398),an=t(32881);const qe=(0,O.A)(p=>(0,Te.A)({paper:{width:"100%",[p.breakpoints.up("sm")]:{width:"75%"},[p.breakpoints.up("md")]:{width:"50%"},padding:p.spacing(2.5)},root:{height:"100%",overflow:"hidden"},logs:{background:p.palette.background.default}})),re=({buildLog:p,onClose:I})=>{const $=qe(),F=p.length===0?"Waiting for logs...":p.join(`
8
+ `);return(0,o.jsxs)(d.A,{container:!0,direction:"column",className:$.root,spacing:0,wrap:"nowrap",children:[(0,o.jsxs)(d.A,{item:!0,container:!0,justifyContent:"space-between",alignItems:"center",spacing:0,wrap:"nowrap",children:[(0,o.jsx)(Ge.A,{variant:"h5",children:"Build Details"}),(0,o.jsx)(ft.A,{title:"Close the drawer",onClick:I,color:"inherit",children:(0,o.jsx)(an.A,{})},"dismiss")]}),(0,o.jsx)(d.A,{item:!0,xs:!0,children:(0,o.jsx)(ke,{text:F,classes:{root:$.logs}})})]})},Ke=({buildLog:p})=>{const I=qe(),[$,F]=(0,i.useState)(!1);return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(Ct.A,{color:"inherit",onClick:()=>F(!0),children:"Show Build Logs"}),(0,o.jsx)(Ue.Ay,{classes:{paper:I.paper},anchor:"right",open:$,onClose:()=>F(!1),children:(0,o.jsx)(re,{buildLog:p,onClose:()=>F(!1)})})]})},ze=({errorMessage:p})=>{const I=(0,G.gf)(q.U).getOptionalString("techdocs.builder"),$=(0,H.s)(),{entityRef:F}=(0,m.V)(),Q=(0,Nt.zy)();(0,i.useEffect)(()=>{const{pathname:lt,search:bt,hash:Bt}=Q;$.captureEvent("not-found",`${lt}${bt}${Bt}`,{attributes:F})},[$,F,Q]);let X="";return[void 0,"local"].includes(I)||(X="Note that techdocs.builder is not set to 'local' in your config, which means this Backstage app will not generate docs if they are not found. Make sure the project's docs are generated and published by some external process (e.g. CI/CD pipeline). Or change techdocs.builder to 'local' to generate docs from this Backstage instance."),(0,o.jsx)(R.M,{status:"404",statusMessage:p||"Documentation not found",additionalInfo:X})};var tn=t(28966),Ye=t(26679);function Ce({contentLoading:p,content:I,activeSyncState:$}){return p||$==="BUILD_READY_RELOAD"||!I&&$==="CHECKING"?"CHECKING":!I&&$==="BUILDING"?"INITIAL_BUILD":I?$==="BUILDING"?"CONTENT_STALE_REFRESHING":$==="BUILD_READY"?"CONTENT_STALE_READY":$==="ERROR"?"CONTENT_STALE_ERROR":"CONTENT_FRESH":"CONTENT_NOT_FOUND"}function ln(p,I){const $={...p};switch(I.type){case"sync":I.state==="CHECKING"&&($.buildLog=[]),$.activeSyncState=I.state,$.syncError=I.syncError;break;case"contentLoading":$.contentLoading=!0,$.contentError=void 0;break;case"content":typeof I.path=="string"&&($.path=I.path),$.contentLoading=!1,$.content=I.content,$.contentError=I.contentError;break;case"buildLog":$.buildLog=$.buildLog.concat(I.log);break;default:throw new Error}return["BUILD_READY","BUILD_READY_RELOAD"].includes($.activeSyncState)&&["contentLoading","content"].includes(I.type)&&($.activeSyncState="UP_TO_DATE",$.buildLog=[]),$}function cn(p,I,$,F){var Q,X;const[lt,bt]=(0,i.useReducer)(ln,{activeSyncState:"CHECKING",path:F,contentLoading:!0,buildLog:[]}),Bt=(0,G.gf)(Ye.s),{retry:kt}=(0,tn.A)(async()=>{bt({type:"contentLoading"});try{const Pt=await Bt.getEntityDocs({kind:p,namespace:I,name:$},F);return bt({type:"content",content:Pt,path:F}),Pt}catch(Pt){bt({type:"content",contentError:Pt,path:F})}},[Bt,p,I,$,F]),Zt=(0,i.useRef)({content:void 0,reload:()=>{}});return Zt.current={content:lt.content,reload:kt},(0,_.A)(async()=>{bt({type:"sync",state:"CHECKING"});const Pt=setTimeout(()=>{bt({type:"sync",state:"BUILDING"})},1e3);try{switch(await Bt.syncEntityDocs({kind:p,namespace:I,name:$},Ee=>{bt({type:"buildLog",log:Ee})})){case"updated":Zt.current.content?bt({type:"sync",state:"BUILD_READY"}):(Zt.current.reload(),bt({type:"sync",state:"BUILD_READY_RELOAD"}));break;case"cached":bt({type:"sync",state:"UP_TO_DATE"});break;default:bt({type:"sync",state:"ERROR",syncError:new Error("Unexpected return state")});break}}catch(he){bt({type:"sync",state:"ERROR",syncError:he})}finally{clearTimeout(Pt)}},[p,$,I,Bt,bt,Zt]),{state:(0,i.useMemo)(()=>Ce({activeSyncState:lt.activeSyncState,contentLoading:lt.contentLoading,content:lt.content}),[lt.activeSyncState,lt.content,lt.contentLoading]),contentReload:kt,path:lt.path,content:lt.content,contentErrorMessage:(Q=lt.contentError)===null||Q===void 0?void 0:Q.toString(),syncErrorMessage:(X=lt.syncError)===null||X===void 0?void 0:X.toString(),buildLog:lt.buildLog}}const dn=(0,i.createContext)({}),ge=()=>(0,i.useContext)(dn),De=p=>{const{children:I}=p,{"*":$=""}=(0,Nt.g)(),{entityRef:F}=(0,m.V)(),{kind:Q,namespace:X,name:lt}=F,bt=cn(Q,X,lt,$);return(0,o.jsx)(dn.Provider,{value:bt,children:I instanceof Function?I(bt):I})},Qe=p=>I=>(0,o.jsx)(De,{children:(0,o.jsx)(p,{...I})}),Ze=(0,O.A)(p=>({root:{marginBottom:p.spacing(2)},message:{wordBreak:"break-word",overflowWrap:"anywhere"}})),$e=()=>{let p=null;const I=Ze(),{state:$,contentReload:F,contentErrorMessage:Q,syncErrorMessage:X,buildLog:lt}=ge();return $==="INITIAL_BUILD"&&(p=(0,o.jsx)(zt.A,{classes:{root:I.root},variant:"outlined",severity:"info",icon:(0,o.jsx)(gt.A,{size:"24px"}),action:(0,o.jsx)(Ke,{buildLog:lt}),children:"Documentation is accessed for the first time and is being prepared. The subsequent loads are much faster."})),$==="CONTENT_STALE_REFRESHING"&&(p=(0,o.jsx)(zt.A,{variant:"outlined",severity:"info",icon:(0,o.jsx)(gt.A,{size:"24px"}),action:(0,o.jsx)(Ke,{buildLog:lt}),classes:{root:I.root},children:"A newer version of this documentation is being prepared and will be available shortly."})),$==="CONTENT_STALE_READY"&&(p=(0,o.jsx)(zt.A,{variant:"outlined",severity:"success",action:(0,o.jsx)(Ct.A,{color:"inherit",onClick:()=>F(),children:"Refresh"}),classes:{root:I.root},children:"A newer version of this documentation is now available, please refresh to view."})),$==="CONTENT_STALE_ERROR"&&(p=(0,o.jsxs)(zt.A,{variant:"outlined",severity:"error",action:(0,o.jsx)(Ke,{buildLog:lt}),classes:{root:I.root,message:I.message},children:["Building a newer version of this documentation failed."," ",X]})),$==="CONTENT_NOT_FOUND"&&(p=(0,o.jsxs)(o.Fragment,{children:[X&&(0,o.jsxs)(zt.A,{variant:"outlined",severity:"error",action:(0,o.jsx)(Ke,{buildLog:lt}),classes:{root:I.root,message:I.message},children:["Building a newer version of this documentation failed."," ",X]}),(0,o.jsx)(ze,{errorMessage:Q})]})),p};var He=t(5893),_e=t(54917),en=t(3347),Rn=t(71651),un=t.n(Rn);const In=/main\.[A-Fa-f0-9]{8}\.min\.css$/,M=/^https:\/\/fonts\.googleapis\.com/,u=/^https:\/\/fonts\.gstatic\.com/,L=p=>p.nodeName==="LINK",U=p=>{const I=(p==null?void 0:p.getAttribute("href"))||"",$=I.match(In),F=I.match(M),Q=I.match(u);return $||F||Q},ot=p=>(L(p)&&!U(p)&&p.remove(),p),nt=p=>p.nodeName==="IFRAME",ut=(p,I)=>{const $=p.getAttribute("src")||"";try{const{host:F}=new URL($);return I.includes(F)}catch{return!1}},jt=p=>I=>(nt(I)&&!ut(I,p)&&I.remove(),I),$t=()=>{const p=(0,G.gf)(q.U);return(0,i.useMemo)(()=>p.getOptionalConfig("techdocs.sanitizer"),[p])},ue=()=>{const p=$t();return(0,i.useCallback)(async I=>{const $=p==null?void 0:p.getOptionalStringArray("allowedIframeHosts");un().addHook("beforeSanitizeElements",ot);const F=["link"];return $&&(F.push("iframe"),un().addHook("beforeSanitizeElements",jt($))),un().sanitize(I.outerHTML,{ADD_TAGS:F,FORBID_TAGS:["style"],WHOLE_DOCUMENT:!0,RETURN_DOM:!0})},[p])};var ae=t(34435),Gt=t(268),ee=({theme:p})=>`
9
+ /*================== Variables ==================*/
10
+ /*
11
+ As the MkDocs output is rendered in shadow DOM, the CSS variable definitions on the root selector are not applied. Instead, they have to be applied on :host.
12
+ As there is no way to transform the served main*.css yet (for example in the backend), we have to copy from main*.css and modify them.
13
+ */
14
+
15
+ :host {
16
+ /* FONT */
17
+ --md-default-fg-color: ${p.palette.text.primary};
18
+ --md-default-fg-color--light: ${p.palette.text.secondary};
19
+ --md-default-fg-color--lighter: ${(0,Gt.a)(p.palette.text.secondary,.7)};
20
+ --md-default-fg-color--lightest: ${(0,Gt.a)(p.palette.text.secondary,.3)};
21
+
22
+ /* BACKGROUND */
23
+ --md-default-bg-color:${p.palette.background.default};
24
+ --md-default-bg-color--light: ${p.palette.background.paper};
25
+ --md-default-bg-color--lighter: ${(0,Gt.a)(p.palette.background.paper,.7)};
26
+ --md-default-bg-color--lightest: ${(0,Gt.a)(p.palette.background.paper,.3)};
27
+
28
+ /* PRIMARY */
29
+ --md-primary-fg-color: ${p.palette.primary.main};
30
+ --md-primary-fg-color--light: ${p.palette.primary.light};
31
+ --md-primary-fg-color--dark: ${p.palette.primary.dark};
32
+ --md-primary-bg-color: ${p.palette.primary.contrastText};
33
+ --md-primary-bg-color--light: ${(0,Gt.a)(p.palette.primary.contrastText,.7)};
34
+
35
+ /* ACCENT */
36
+ --md-accent-fg-color: var(--md-primary-fg-color);
37
+
38
+ /* SHADOW */
39
+ --md-shadow-z1: ${p.shadows[1]};
40
+ --md-shadow-z2: ${p.shadows[2]};
41
+ --md-shadow-z3: ${p.shadows[3]};
42
+
43
+ /* EXTENSIONS */
44
+ --md-admonition-fg-color: var(--md-default-fg-color);
45
+ --md-admonition-bg-color: var(--md-default-bg-color);
46
+ /* Admonitions and others are using SVG masks to define icons. These masks are defined as CSS variables. */
47
+ --md-admonition-icon--note: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20.71 7.04c.39-.39.39-1.04 0-1.41l-2.34-2.34c-.37-.39-1.02-.39-1.41 0l-1.84 1.83 3.75 3.75M3 17.25V21h3.75L17.81 9.93l-3.75-3.75L3 17.25z"/></svg>');
48
+ --md-admonition-icon--abstract: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M4 5h16v2H4V5m0 4h16v2H4V9m0 4h16v2H4v-2m0 4h10v2H4v-2z"/></svg>');
49
+ --md-admonition-icon--info: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M13 9h-2V7h2m0 10h-2v-6h2m-1-9A10 10 0 002 12a10 10 0 0010 10 10 10 0 0010-10A10 10 0 0012 2z"/></svg>');
50
+ --md-admonition-icon--tip: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M17.55 11.2c-.23-.3-.5-.56-.76-.82-.65-.6-1.4-1.03-2.03-1.66C13.3 7.26 13 4.85 13.91 3c-.91.23-1.75.75-2.45 1.32-2.54 2.08-3.54 5.75-2.34 8.9.04.1.08.2.08.33 0 .22-.15.42-.35.5-.22.1-.46.04-.64-.12a.83.83 0 01-.15-.17c-1.1-1.43-1.28-3.48-.53-5.12C5.89 10 5 12.3 5.14 14.47c.04.5.1 1 .27 1.5.14.6.4 1.2.72 1.73 1.04 1.73 2.87 2.97 4.84 3.22 2.1.27 4.35-.12 5.96-1.6 1.8-1.66 2.45-4.32 1.5-6.6l-.13-.26c-.2-.46-.47-.87-.8-1.25l.05-.01m-3.1 6.3c-.28.24-.73.5-1.08.6-1.1.4-2.2-.16-2.87-.82 1.19-.28 1.89-1.16 2.09-2.05.17-.8-.14-1.46-.27-2.23-.12-.74-.1-1.37.18-2.06.17.38.37.76.6 1.06.76 1 1.95 1.44 2.2 2.8.04.14.06.28.06.43.03.82-.32 1.72-.92 2.27h.01z"/></svg>');
51
+ --md-admonition-icon--success: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2m-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></svg>');
52
+ --md-admonition-icon--question: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M15.07 11.25l-.9.92C13.45 12.89 13 13.5 13 15h-2v-.5c0-1.11.45-2.11 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41a2 2 0 00-2-2 2 2 0 00-2 2H8a4 4 0 014-4 4 4 0 014 4 3.2 3.2 0 01-.93 2.25M13 19h-2v-2h2M12 2A10 10 0 002 12a10 10 0 0010 10 10 10 0 0010-10c0-5.53-4.5-10-10-10z"/></svg>');
53
+ --md-admonition-icon--warning: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M13 14h-2v-4h2m0 8h-2v-2h2M1 21h22L12 2 1 21z"/></svg>');
54
+ --md-admonition-icon--failure: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 2c5.53 0 10 4.47 10 10s-4.47 10-10 10S2 17.53 2 12 6.47 2 12 2m3.59 5L12 10.59 8.41 7 7 8.41 10.59 12 7 15.59 8.41 17 12 13.41 15.59 17 17 15.59 13.41 12 17 8.41 15.59 7z"/></svg>');
55
+ --md-admonition-icon--danger: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M11.5 20l4.86-9.73H13V4l-5 9.73h3.5V20M12 2c2.75 0 5.1 1 7.05 2.95C21 6.9 22 9.25 22 12s-1 5.1-2.95 7.05C17.1 21 14.75 22 12 22s-5.1-1-7.05-2.95C3 17.1 2 14.75 2 12s1-5.1 2.95-7.05C6.9 3 9.25 2 12 2z"/></svg>');
56
+ --md-admonition-icon--bug: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M14 12h-4v-2h4m0 6h-4v-2h4m6-6h-2.81a5.985 5.985 0 00-1.82-1.96L17 4.41 15.59 3l-2.17 2.17a6.002 6.002 0 00-2.83 0L8.41 3 7 4.41l1.62 1.63C7.88 6.55 7.26 7.22 6.81 8H4v2h2.09c-.05.33-.09.66-.09 1v1H4v2h2v1c0 .34.04.67.09 1H4v2h2.81c1.04 1.79 2.97 3 5.19 3s4.15-1.21 5.19-3H20v-2h-2.09c.05-.33.09-.66.09-1v-1h2v-2h-2v-1c0-.34-.04-.67-.09-1H20V8z"/></svg>');
57
+ --md-admonition-icon--example: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M7 13v-2h14v2H7m0 6v-2h14v2H7M7 7V5h14v2H7M3 8V5H2V4h2v4H3m-1 9v-1h3v4H2v-1h2v-.5H3v-1h1V17H2m2.25-7a.75.75 0 01.75.75c0 .2-.08.39-.21.52L3.12 13H5v1H2v-.92L4 11H2v-1h2.25z"/></svg>');
58
+ --md-admonition-icon--quote: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M14 17h3l2-4V7h-6v6h3M6 17h3l2-4V7H5v6h3l-2 4z"/></svg>');
59
+ --md-footnotes-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M19 7v4H5.83l3.58-3.59L8 6l-6 6 6 6 1.41-1.42L5.83 13H21V7h-2z"/></svg>');
60
+ --md-details-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M8.59 16.58 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.42z"/></svg>');
61
+ --md-tasklist-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 0h24v24H0z" fill="none"/><path d="M19 5v14H5V5h14m0-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/></svg>');
62
+ --md-tasklist-icon--checked: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M0 0h24v24H0z" fill="none"/><path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"/></svg>');
63
+ --md-nav-icon--prev: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11h12z"/></svg>');
64
+ --md-nav-icon--next: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M8.59 16.58 13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.42z"/></svg>');
65
+ --md-toc-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M3 9h14V7H3v2m0 4h14v-2H3v2m0 4h14v-2H3v2m16 0h2v-2h-2v2m0-10v2h2V7h-2m0 6h2v-2h-2v2z"/></svg>');
66
+ --md-clipboard-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M19 21H8V7h11m0-2H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3-4H4a2 2 0 0 0-2 2v14h2V3h12V1z"/></svg>');
67
+ --md-search-result-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h7c-.41-.25-.8-.56-1.14-.9-.33-.33-.61-.7-.86-1.1H6V4h7v5h5v1.18c.71.16 1.39.43 2 .82V8l-6-6m6.31 16.9c1.33-2.11.69-4.9-1.4-6.22-2.11-1.33-4.91-.68-6.22 1.4-1.34 2.11-.69 4.89 1.4 6.22 1.46.93 3.32.93 4.79.02L22 23.39 23.39 22l-3.08-3.1m-3.81.1a2.5 2.5 0 0 1-2.5-2.5 2.5 2.5 0 0 1 2.5-2.5 2.5 2.5 0 0 1 2.5 2.5 2.5 2.5 0 0 1-2.5 2.5z"/></svg>');
68
+ --md-source-forks-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M5 3.25a.75.75 0 1 1-1.5 0 .75.75 0 0 1 1.5 0zm0 2.122a2.25 2.25 0 1 0-1.5 0v.878A2.25 2.25 0 0 0 5.75 8.5h1.5v2.128a2.251 2.251 0 1 0 1.5 0V8.5h1.5a2.25 2.25 0 0 0 2.25-2.25v-.878a2.25 2.25 0 1 0-1.5 0v.878a.75.75 0 0 1-.75.75h-4.5A.75.75 0 0 1 5 6.25v-.878zm3.75 7.378a.75.75 0 1 1-1.5 0 .75.75 0 0 1 1.5 0zm3-8.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5z"/></svg>');
69
+ --md-source-repositories-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M2 2.5A2.5 2.5 0 0 1 4.5 0h8.75a.75.75 0 0 1 .75.75v12.5a.75.75 0 0 1-.75.75h-2.5a.75.75 0 1 1 0-1.5h1.75v-2h-8a1 1 0 0 0-.714 1.7.75.75 0 0 1-1.072 1.05A2.495 2.495 0 0 1 2 11.5v-9zm10.5-1V9h-8c-.356 0-.694.074-1 .208V2.5a1 1 0 0 1 1-1h8zM5 12.25v3.25a.25.25 0 0 0 .4.2l1.45-1.087a.25.25 0 0 1 .3 0L8.6 15.7a.25.25 0 0 0 .4-.2v-3.25a.25.25 0 0 0-.25-.25h-3.5a.25.25 0 0 0-.25.25z"/></svg>');
70
+ --md-source-stars-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M8 .25a.75.75 0 0 1 .673.418l1.882 3.815 4.21.612a.75.75 0 0 1 .416 1.279l-3.046 2.97.719 4.192a.75.75 0 0 1-1.088.791L8 12.347l-3.766 1.98a.75.75 0 0 1-1.088-.79l.72-4.194L.818 6.374a.75.75 0 0 1 .416-1.28l4.21-.611L7.327.668A.75.75 0 0 1 8 .25zm0 2.445L6.615 5.5a.75.75 0 0 1-.564.41l-3.097.45 2.24 2.184a.75.75 0 0 1 .216.664l-.528 3.084 2.769-1.456a.75.75 0 0 1 .698 0l2.77 1.456-.53-3.084a.75.75 0 0 1 .216-.664l2.24-2.183-3.096-.45a.75.75 0 0 1-.564-.41L8 2.694v.001z"/></svg>');
71
+ --md-source-version-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M2.5 7.775V2.75a.25.25 0 0 1 .25-.25h5.025a.25.25 0 0 1 .177.073l6.25 6.25a.25.25 0 0 1 0 .354l-5.025 5.025a.25.25 0 0 1-.354 0l-6.25-6.25a.25.25 0 0 1-.073-.177zm-1.5 0V2.75C1 1.784 1.784 1 2.75 1h5.025c.464 0 .91.184 1.238.513l6.25 6.25a1.75 1.75 0 0 1 0 2.474l-5.026 5.026a1.75 1.75 0 0 1-2.474 0l-6.25-6.25A1.75 1.75 0 0 1 1 7.775zM6 5a1 1 0 1 0 0 2 1 1 0 0 0 0-2z"/></svg>');
72
+ --md-version-icon: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 512"><!--! Font Awesome Free 6.0.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) Copyright 2022 Fonticons, Inc.--><path d="m310.6 246.6-127.1 128c-7.1 6.3-15.3 9.4-23.5 9.4s-16.38-3.125-22.63-9.375l-127.1-128C.224 237.5-2.516 223.7 2.438 211.8S19.07 192 32 192h255.1c12.94 0 24.62 7.781 29.58 19.75s3.12 25.75-6.08 34.85z"/></svg>');
73
+ }
74
+
75
+ :host > * {
76
+ /* CODE */
77
+ --md-code-fg-color: ${p.palette.text.primary};
78
+ --md-code-bg-color: ${p.palette.background.paper};
79
+ --md-code-hl-color: ${(0,Gt.X4)(p.palette.warning.main,.5)};
80
+ --md-code-hl-keyword-color: ${p.palette.type==="dark"?p.palette.primary.light:p.palette.primary.dark};
81
+ --md-code-hl-function-color: ${p.palette.type==="dark"?p.palette.secondary.light:p.palette.secondary.dark};
82
+ --md-code-hl-string-color: ${p.palette.type==="dark"?p.palette.success.light:p.palette.success.dark};
83
+ --md-code-hl-number-color: ${p.palette.type==="dark"?p.palette.error.light:p.palette.error.dark};
84
+ --md-code-hl-constant-color: var(--md-code-hl-function-color);
85
+ --md-code-hl-special-color: var(--md-code-hl-function-color);
86
+ --md-code-hl-name-color: var(--md-code-fg-color);
87
+ --md-code-hl-comment-color: var(--md-default-fg-color--light);
88
+ --md-code-hl-generic-color: var(--md-default-fg-color--light);
89
+ --md-code-hl-variable-color: var(--md-default-fg-color--light);
90
+ --md-code-hl-operator-color: var(--md-default-fg-color--light);
91
+ --md-code-hl-punctuation-color: var(--md-default-fg-color--light);
92
+
93
+ /* TYPESET */
94
+ --md-typeset-font-size: 1rem;
95
+ --md-typeset-color: var(--md-default-fg-color);
96
+ --md-typeset-a-color: ${p.palette.link};
97
+ --md-typeset-table-color: ${p.palette.text.primary};
98
+ --md-typeset-del-color: ${p.palette.type==="dark"?(0,Gt.X4)(p.palette.error.dark,.5):(0,Gt.X4)(p.palette.error.light,.5)};
99
+ --md-typeset-ins-color: ${p.palette.type==="dark"?(0,Gt.X4)(p.palette.success.dark,.5):(0,Gt.X4)(p.palette.success.light,.5)};
100
+ --md-typeset-mark-color: ${p.palette.type==="dark"?(0,Gt.X4)(p.palette.warning.dark,.5):(0,Gt.X4)(p.palette.warning.light,.5)};
101
+ }
102
+
103
+ @media screen and (max-width: 76.1875em) {
104
+ :host > * {
105
+ /* TYPESET */
106
+ --md-typeset-font-size: .9rem;
107
+ }
108
+ }
109
+
110
+ @media screen and (max-width: 600px) {
111
+ :host > * {
112
+ /* TYPESET */
113
+ --md-typeset-font-size: .7rem;
114
+ }
115
+ }
116
+ `,Yt=({theme:p})=>`
117
+ /*================== Reset ==================*/
118
+
119
+ body {
120
+ --md-text-color: var(--md-default-fg-color);
121
+ --md-text-link-color: var(--md-accent-fg-color);
122
+ --md-text-font-family: ${p.typography.fontFamily};
123
+ font-family: var(--md-text-font-family);
124
+ background-color: unset;
125
+ }
126
+ `;const se="224px";var ne=({theme:p,sidebar:I})=>`
127
+ /*================== Layout ==================*/
128
+
129
+ /* mkdocs material v9 compat */
130
+ .md-nav__title {
131
+ color: var(--md-default-fg-color);
132
+ }
133
+
134
+ .md-grid {
135
+ max-width: 100%;
136
+ margin: 0;
137
+ }
138
+
139
+ .md-nav {
140
+ font-size: calc(var(--md-typeset-font-size) * 0.9);
141
+ }
142
+ .md-nav__link {
143
+ display: flex;
144
+ align-items: center;
145
+ justify-content: space-between;
146
+ }
147
+ .md-nav__icon {
148
+ height: 20px !important;
149
+ width: 20px !important;
150
+ margin-left:${p.spacing(1)}px;
151
+ }
152
+ .md-nav__icon svg {
153
+ margin: 0;
154
+ width: 20px !important;
155
+ height: 20px !important;
156
+ }
157
+ .md-nav__icon:after {
158
+ width: 20px !important;
159
+ height: 20px !important;
160
+ }
161
+
162
+ .md-nav__item--active > .md-nav__link, a.md-nav__link--active {
163
+ text-decoration: underline;
164
+ color: var(--md-typeset-a-color);
165
+ }
166
+
167
+ .md-main__inner {
168
+ margin-top: 0;
169
+ }
170
+
171
+ .md-sidebar {
172
+ bottom: 75px;
173
+ position: fixed;
174
+ width: 16rem;
175
+ overflow-y: auto;
176
+ overflow-x: hidden;
177
+ scrollbar-color: rgb(193, 193, 193) #eee;
178
+ scrollbar-width: thin;
179
+ }
180
+ .md-sidebar .md-sidebar__scrollwrap {
181
+ width: calc(12.1rem);
182
+ }
183
+ .md-sidebar--secondary {
184
+ right: ${p.spacing(3)}px;
185
+ }
186
+ .md-sidebar::-webkit-scrollbar {
187
+ width: 5px;
188
+ }
189
+ .md-sidebar::-webkit-scrollbar-button {
190
+ width: 5px;
191
+ height: 5px;
192
+ }
193
+ .md-sidebar::-webkit-scrollbar-track {
194
+ background: #eee;
195
+ border: 1 px solid rgb(250, 250, 250);
196
+ box-shadow: 0px 0px 3px #dfdfdf inset;
197
+ border-radius: 3px;
198
+ }
199
+ .md-sidebar::-webkit-scrollbar-thumb {
200
+ width: 5px;
201
+ background: rgb(193, 193, 193);
202
+ border: transparent;
203
+ border-radius: 3px;
204
+ }
205
+ .md-sidebar::-webkit-scrollbar-thumb:hover {
206
+ background: rgb(125, 125, 125);
207
+ }
208
+
209
+ .md-content {
210
+ max-width: calc(100% - 16rem * 2);
211
+ margin-left: 16rem;
212
+ margin-bottom: 50px;
213
+ }
214
+
215
+ .md-footer {
216
+ position: fixed;
217
+ bottom: 0px;
218
+ pointer-events: none;
219
+ }
220
+
221
+ .md-footer-nav__link, .md-footer__link {
222
+ pointer-events: all;
223
+ }
224
+
225
+ .md-footer__title {
226
+ background-color: unset;
227
+ }
228
+ .md-footer-nav__link, .md-footer__link {
229
+ width: 16rem;
230
+ }
231
+
232
+ .md-dialog {
233
+ background-color: unset;
234
+ }
235
+
236
+ @media screen and (min-width: 76.25em) {
237
+ .md-sidebar {
238
+ height: auto;
239
+ }
240
+ }
241
+
242
+ @media screen and (max-width: 76.1875em) {
243
+ .md-nav {
244
+ transition: none !important;
245
+ background-color: var(--md-default-bg-color)
246
+ }
247
+ .md-nav--primary .md-nav__title {
248
+ cursor: auto;
249
+ color: var(--md-default-fg-color);
250
+ font-weight: 700;
251
+ white-space: normal;
252
+ line-height: 1rem;
253
+ height: auto;
254
+ display: flex;
255
+ flex-flow: column;
256
+ row-gap: 1.6rem;
257
+ padding: 1.2rem .8rem .8rem;
258
+ background-color: var(--md-default-bg-color);
259
+ }
260
+ .md-nav--primary .md-nav__title~.md-nav__list {
261
+ box-shadow: none;
262
+ }
263
+ .md-nav--primary .md-nav__title ~ .md-nav__list > :first-child {
264
+ border-top: none;
265
+ }
266
+ .md-nav--primary .md-nav__title .md-nav__button {
267
+ display: none;
268
+ }
269
+ .md-nav--primary .md-nav__title .md-nav__icon {
270
+ color: var(--md-default-fg-color);
271
+ position: static;
272
+ height: auto;
273
+ margin: 0 0 0 -0.2rem;
274
+ }
275
+ .md-nav--primary > .md-nav__title [for="none"] {
276
+ padding-top: 0;
277
+ }
278
+ .md-nav--primary .md-nav__item {
279
+ border-top: none;
280
+ }
281
+ .md-nav--primary :is(.md-nav__title,.md-nav__item) {
282
+ font-size : var(--md-typeset-font-size);
283
+ }
284
+ .md-nav .md-source {
285
+ display: none;
286
+ }
287
+
288
+ .md-sidebar {
289
+ height: 100%;
290
+ }
291
+ .md-sidebar--primary {
292
+ width: 12.1rem !important;
293
+ z-index: 200;
294
+ left: ${I.isPinned?`calc(-12.1rem + ${se})`:"calc(-12.1rem + 72px)"} !important;
295
+ }
296
+ .md-sidebar--secondary:not([hidden]) {
297
+ display: none;
298
+ }
299
+
300
+ .md-content {
301
+ max-width: 100%;
302
+ margin-left: 0;
303
+ }
304
+
305
+ .md-header__button {
306
+ margin: 0.4rem 0;
307
+ margin-left: 0.4rem;
308
+ padding: 0;
309
+ }
310
+
311
+ .md-overlay {
312
+ left: 0;
313
+ }
314
+
315
+ .md-footer {
316
+ position: static;
317
+ padding-left: 0;
318
+ }
319
+ .md-footer-nav__link {
320
+ /* footer links begin to overlap at small sizes without setting width */
321
+ width: 50%;
322
+ }
323
+ }
324
+
325
+ @media screen and (max-width: 600px) {
326
+ .md-sidebar--primary {
327
+ left: -12.1rem !important;
328
+ width: 12.1rem;
329
+ }
330
+ }
331
+
332
+
333
+ @media print {
334
+ .md-sidebar,
335
+ #toggle-sidebar {
336
+ display: none;
337
+ }
338
+
339
+ .md-content {
340
+ margin: 0;
341
+ width: 100%;
342
+ max-width: 100%;
343
+ }
344
+ }
345
+ `;const Me=["h1","h2","h3","h4","h5","h6"];var be=({theme:p})=>`
346
+ /*================== Typeset ==================*/
347
+
348
+ .md-typeset {
349
+ font-size: var(--md-typeset-font-size);
350
+ }
351
+
352
+ ${Me.reduce((I,$)=>{var F;const Q=(F=p.typography.htmlFontSize)!==null&&F!==void 0?F:16,X=p.typography[$],{lineHeight:lt,fontFamily:bt,fontWeight:Bt,fontSize:kt}=X,Zt=Ht=>{let Pt=1;return typeof Ht=="number"&&(Pt=Ht/Q*.6),typeof Ht=="string"&&(Pt=Ht.replace("rem","")),`calc(${Pt} * var(--md-typeset-font-size))`};return I.concat(`
353
+ .md-typeset ${$} {
354
+ color: var(--md-default-fg-color);
355
+ line-height: ${lt};
356
+ font-family: ${bt};
357
+ font-weight: ${Bt};
358
+ font-size: ${Zt(kt)};
359
+ }
360
+ `)},"")}
361
+
362
+ .md-typeset .md-content__button {
363
+ color: var(--md-default-fg-color);
364
+ }
365
+
366
+ .md-typeset hr {
367
+ border-bottom: 0.05rem dotted ${p.palette.divider};
368
+ }
369
+
370
+ .md-typeset details {
371
+ font-size: var(--md-typeset-font-size) !important;
372
+ }
373
+ .md-typeset details summary {
374
+ padding-left: 2.5rem !important;
375
+ }
376
+ .md-typeset details summary:before,
377
+ .md-typeset details summary:after {
378
+ top: 50% !important;
379
+ width: 20px !important;
380
+ height: 20px !important;
381
+ transform: rotate(0deg) translateY(-50%) !important;
382
+ }
383
+ .md-typeset details[open] > summary:after {
384
+ transform: rotate(90deg) translateX(-50%) !important;
385
+ }
386
+
387
+ .md-typeset blockquote {
388
+ color: var(--md-default-fg-color--light);
389
+ border-left: 0.2rem solid var(--md-default-fg-color--light);
390
+ }
391
+
392
+ .md-typeset table:not([class]) {
393
+ font-size: var(--md-typeset-font-size);
394
+ border: 1px solid var(--md-default-fg-color);
395
+ border-bottom: none;
396
+ border-collapse: collapse;
397
+ }
398
+ .md-typeset table:not([class]) th {
399
+ font-weight: bold;
400
+ }
401
+ .md-typeset table:not([class]) td, .md-typeset table:not([class]) th {
402
+ border-bottom: 1px solid var(--md-default-fg-color);
403
+ }
404
+
405
+ .md-typeset pre > code::-webkit-scrollbar-thumb {
406
+ background-color: hsla(0, 0%, 0%, 0.32);
407
+ }
408
+ .md-typeset pre > code::-webkit-scrollbar-thumb:hover {
409
+ background-color: hsla(0, 0%, 0%, 0.87);
410
+ }
411
+
412
+ .md-typeset code {
413
+ word-break: keep-all;
414
+ }
415
+ `,hn=()=>`
416
+ /*================== Animations ==================*/
417
+ /*
418
+ Disable CSS animations on link colors as they lead to issues in dark mode.
419
+ The dark mode color theme is applied later and theirfore there is always an animation from light to dark mode when navigation between pages.
420
+ */
421
+ .md-dialog, .md-nav__link, .md-footer__link, .md-typeset a, .md-typeset a::before, .md-typeset .headerlink {
422
+ transition: none;
423
+ }
424
+ `,fn=({theme:p})=>`
425
+ /*================== Extensions ==================*/
426
+
427
+ /* HIGHLIGHT */
428
+ .highlight .md-clipboard:after {
429
+ content: unset;
430
+ }
431
+
432
+ .highlight .nx {
433
+ color: ${p.palette.type==="dark"?"#ff53a3":"#ec407a"};
434
+ }
435
+
436
+ /* CODE HILITE */
437
+ .codehilite .gd {
438
+ background-color: ${p.palette.type==="dark"?"rgba(248,81,73,0.65)":"#fdd"};
439
+ }
440
+
441
+ .codehilite .gi {
442
+ background-color: ${p.palette.type==="dark"?"rgba(46,160,67,0.65)":"#dfd"};
443
+ }
444
+
445
+ /* TABBED */
446
+ .tabbed-set>input:nth-child(1):checked~.tabbed-labels>:nth-child(1),
447
+ .tabbed-set>input:nth-child(2):checked~.tabbed-labels>:nth-child(2),
448
+ .tabbed-set>input:nth-child(3):checked~.tabbed-labels>:nth-child(3),
449
+ .tabbed-set>input:nth-child(4):checked~.tabbed-labels>:nth-child(4),
450
+ .tabbed-set>input:nth-child(5):checked~.tabbed-labels>:nth-child(5),
451
+ .tabbed-set>input:nth-child(6):checked~.tabbed-labels>:nth-child(6),
452
+ .tabbed-set>input:nth-child(7):checked~.tabbed-labels>:nth-child(7),
453
+ .tabbed-set>input:nth-child(8):checked~.tabbed-labels>:nth-child(8),
454
+ .tabbed-set>input:nth-child(9):checked~.tabbed-labels>:nth-child(9),
455
+ .tabbed-set>input:nth-child(10):checked~.tabbed-labels>:nth-child(10),
456
+ .tabbed-set>input:nth-child(11):checked~.tabbed-labels>:nth-child(11),
457
+ .tabbed-set>input:nth-child(12):checked~.tabbed-labels>:nth-child(12),
458
+ .tabbed-set>input:nth-child(13):checked~.tabbed-labels>:nth-child(13),
459
+ .tabbed-set>input:nth-child(14):checked~.tabbed-labels>:nth-child(14),
460
+ .tabbed-set>input:nth-child(15):checked~.tabbed-labels>:nth-child(15),
461
+ .tabbed-set>input:nth-child(16):checked~.tabbed-labels>:nth-child(16),
462
+ .tabbed-set>input:nth-child(17):checked~.tabbed-labels>:nth-child(17),
463
+ .tabbed-set>input:nth-child(18):checked~.tabbed-labels>:nth-child(18),
464
+ .tabbed-set>input:nth-child(19):checked~.tabbed-labels>:nth-child(19),
465
+ .tabbed-set>input:nth-child(20):checked~.tabbed-labels>:nth-child(20) {
466
+ color: var(--md-accent-fg-color);
467
+ border-color: var(--md-accent-fg-color);
468
+ }
469
+
470
+ /* TASK-LIST */
471
+ .task-list-control .task-list-indicator::before {
472
+ background-color: ${p.palette.action.disabledBackground};
473
+ }
474
+ .task-list-control [type="checkbox"]:checked + .task-list-indicator:before {
475
+ background-color: ${p.palette.success.main};
476
+ }
477
+
478
+ /* ADMONITION */
479
+ .admonition {
480
+ font-size: var(--md-typeset-font-size) !important;
481
+ }
482
+ .admonition .admonition-title {
483
+ padding-left: 2.5rem !important;
484
+ }
485
+
486
+ .admonition .admonition-title:before {
487
+ top: 50% !important;
488
+ width: 20px !important;
489
+ height: 20px !important;
490
+ transform: translateY(-50%) !important;
491
+ }
492
+ `;const mn=[ee,Yt,ne,be,hn,fn],Qt=()=>(0,ae.Ut)(),Ve=()=>{const p=Qt(),I=(0,_e.A)();return(0,i.useMemo)(()=>{const $={theme:I,sidebar:p};return mn.reduce((F,Q)=>F+Q($),"")},[I,p])},nn=()=>{const p=Ve();return(0,i.useCallback)(I=>(I.getElementsByTagName("head")[0].insertAdjacentHTML("beforeend",`<style>${p}</style>`),I),[p])},yn=async(p,I)=>{let $;if(typeof p=="string")$=new DOMParser().parseFromString(p,"text/html").documentElement;else if(p instanceof Element)$=p;else throw new Error("dom is not a recognized type");for(const F of I)$=await F($);return $},Io=(p,I,$)=>{const F=p==="src"&&I.endsWith(".svg"),Q=!I.match(/^([a-z]*:)?\/\//i),X=I.startsWith($);return F&&(Q||X)},Do=({techdocsStorageApi:p,entityId:I,path:$})=>async F=>{const Q=await p.getApiOrigin(),X=async(lt,bt)=>{for(const Bt of lt)if(Bt.hasAttribute(bt)){const kt=Bt.getAttribute(bt);if(!kt)return;const Zt=await p.getBaseUrl(kt,I,$);if(Io(bt,kt,Q))try{const Pt=await(await fetch(Zt,{credentials:"include"})).text();Bt.setAttribute(bt,`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(Pt)))}`)}catch{Bt.setAttribute("alt",`Error: ${kt}`)}else Bt.setAttribute(bt,Zt)}};return await Promise.all([X(F.querySelectorAll("img"),"src"),X(F.querySelectorAll("script"),"src"),X(F.querySelectorAll("source"),"src"),X(F.querySelectorAll("link"),"href"),X(F.querySelectorAll("a[download]"),"href")]),F},Mo=()=>p=>((($,F)=>{Array.from($).filter(Q=>Q.hasAttribute(F)).forEach(Q=>{const X=Q.getAttribute(F);if(X){X.match(/^https?:\/\//i)&&Q.setAttribute("target","_blank");try{const lt=Dn(window.location.href);Q.setAttribute(F,new URL(X,lt).toString())}catch{Q.replaceWith(Q.textContent||X)}}})})(Array.from(p.getElementsByTagName("a")),"href"),p);function Dn(p){const I=new URL(p);return!I.pathname.endsWith("/")&&!I.pathname.endsWith(".html")&&(I.pathname+="/"),I.toString()}var Lo=t(27326);let Mn;Mn=Promise.resolve().then(t.t.bind(t,25873,19));function Ln(p,I){Mn.then($=>{"createRoot"in $?$.createRoot(I).render(p):$.render(p,I)})}const Jn=()=>p=>{const I=p.querySelector('.md-header label[for="__drawer"]'),$=p.querySelector("article");if(!I||!$)return p;const F=I.cloneNode();return Ln(i.createElement(Lo.A),F),F.id="toggle-sidebar",F.title="Toggle Sidebar",F.classList.add("md-content__button"),F.style.setProperty("padding","0 0 0 5px"),F.style.setProperty("margin","0.4rem 0 0.4rem 0.4rem"),$==null||$.prepend(F),p},Bo=()=>p=>{var I;return(I=p.querySelector(".md-header"))===null||I===void 0||I.remove(),p},jo=()=>p=>{var I,$;return(I=p.querySelector(".md-footer .md-copyright"))===null||I===void 0||I.remove(),($=p.querySelector(".md-footer-copyright"))===null||$===void 0||$.remove(),p};var Uo=t(36021),$o=t(90292),Fo=t(52536),No=t.n(Fo);const Wo=p=>I=>{var $;const F=I.querySelector('[title="Edit this page"]');if(!F||!F.href)return I;const Q=new URL(F.href),X=p.byUrl(Q);if((X==null?void 0:X.type)!=="github"&&(X==null?void 0:X.type)!=="gitlab")return I;const lt=(($=I.querySelector("article>h1"))===null||$===void 0?void 0:$.childNodes[0].textContent)||"",bt=encodeURIComponent(`Documentation Feedback: ${lt}`),Bt=encodeURIComponent(`Page source:
493
+ ${F.href}
494
+
495
+ Feedback:`),kt=(X==null?void 0:X.type)==="github"?(0,Uo.F)(Q.href,"blob"):Q.href,Zt=No()(kt),Ht=`/${Zt.organization}/${Zt.name}`,Pt=F.cloneNode();switch(X==null?void 0:X.type){case"gitlab":Pt.href=`${Q.origin}${Ht}/issues/new?issue[title]=${bt}&issue[description]=${Bt}`;break;case"github":Pt.href=`${Q.origin}${Ht}/issues/new?title=${bt}&body=${Bt}`;break;default:return I}return Ln(i.createElement($o.A),Pt),Pt.style.paddingLeft="5px",Pt.title="Leave feedback for this page",Pt.id="git-feedback-link",F==null||F.insertAdjacentElement("beforebegin",Pt),I},Xn=()=>p=>(setTimeout(()=>{const I=p==null?void 0:p.querySelectorAll("li.md-nav__item--active");I.length!==0&&(I.forEach(F=>{const Q=F==null?void 0:F.querySelector("input");Q!=null&&Q.checked||Q==null||Q.click()}),I[I.length-1].scrollIntoView())},200),p);var ko=t(50868),Ko=t(10437),qn=t(71677),to=t(87051),zo=t(36338);const Bn=(0,to.A)(p=>({tooltip:{fontSize:"inherit",color:p.palette.text.primary,margin:0,padding:p.spacing(.5),backgroundColor:"transparent",boxShadow:"none"}}))(qn.Ay),jn=()=>(0,o.jsx)(Ko.A,{children:(0,o.jsx)("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"})}),Ho=({text:p})=>{const[I,$]=(0,i.useState)(!1),[,F]=(0,zo.A)(),Q=(0,i.useCallback)(()=>{F(p),$(!0)},[p,F]),X=(0,i.useCallback)(()=>{$(!1)},[$]);return(0,o.jsx)(Bn,{title:"Copied to clipboard",placement:"left",open:I,onClose:X,leaveDelay:1e3,children:(0,o.jsx)(ft.A,{style:{color:"inherit"},className:"md-clipboard md-icon",onClick:Q,children:(0,o.jsx)(jn,{})})})},eo=p=>I=>{const $=I.querySelectorAll("pre > code");for(const Q of $){var F;const X=Q.textContent||"",lt=document.createElement("div");Q==null||(F=Q.parentElement)===null||F===void 0||F.prepend(lt),Ln((0,o.jsx)(ko.A,{theme:p,children:(0,o.jsx)(Ho,{text:X})}),lt)}return I},no=({baseUrl:p,onClick:I})=>$=>(Array.from($.getElementsByTagName("a")).forEach(F=>{F.addEventListener("click",Q=>{const lt=F.getAttribute("href");lt&&lt.startsWith(p)&&!F.hasAttribute("download")&&(Q.preventDefault(),I(Q,lt))})}),$),oo=({onLoading:p,onLoaded:I})=>$=>(p(),$.addEventListener(A,function F(){I(),$.removeEventListener(A,F)}),$);function _o(p,I){const $=new URL(I),F=`${$.origin}${$.pathname.replace(/\/$/,"")}`,Q=p.replace(F,"").replace(/^\/+/,""),X=new URL(`http://localhost/${Q}`);return`${X.pathname}${X.search}${X.hash}`}function Vo(){const p=(0,Nt.Zp)(),$=(0,G.gf)(q.U).getOptionalString("app.baseUrl");return(0,i.useCallback)(Q=>{let X=Q;if($)try{X=_o(Q,$)}catch{}p(X)},[p,$])}const Go="screen and (max-width: 76.1875em)",Yo=p=>{const I=Vo(),$=(0,_e.A)(),F=(0,He.A)(Go),Q=ue(),X=nn(),lt=(0,H.s)(),bt=(0,G.gf)(Ye.s),Bt=(0,G.gf)(en.Y),{state:kt,path:Zt,content:Ht}=ge(),[Pt,he]=(0,i.useState)(null),Ee=h(Pt),Jt=(0,i.useCallback)(()=>{if(!Pt)return;Pt.querySelectorAll(".md-sidebar").forEach(Vt=>{if(F)Vt.style.top="0px";else{var te;const Be=(te=document)===null||te===void 0?void 0:te.querySelector(".techdocs-reader-page");var xe;const ie=(xe=Be==null?void 0:Be.getBoundingClientRect().top)!==null&&xe!==void 0?xe:0;var Le;let Fn=(Le=Pt.getBoundingClientRect().top)!==null&&Le!==void 0?Le:0;const Nn=Pt.querySelector(".md-container > .md-tabs");var Fe;const Wn=(Fe=Nn==null?void 0:Nn.getBoundingClientRect().height)!==null&&Fe!==void 0?Fe:0;Fn<ie&&(Fn=ie);const io=Math.max(Fn,0)+Wn;Vt.style.top=`${io}px`;const on=Pt.querySelector(".md-container > .md-footer");var ve;const En=(ve=on==null?void 0:on.getBoundingClientRect().top)!==null&&ve!==void 0?ve:window.innerHeight;Vt.style.height=`${En-io}px`}Vt.style.setProperty("opacity","1")})},[Pt,F]);(0,i.useEffect)(()=>(window.addEventListener("resize",Jt),window.addEventListener("scroll",Jt,!0),()=>{window.removeEventListener("resize",Jt),window.removeEventListener("scroll",Jt,!0)}),[Pt,Jt]);const _t=(0,i.useCallback)(()=>{if(!Pt)return;const Lt=Pt.querySelector(".md-footer");Lt&&(Lt.style.width=`${Pt.getBoundingClientRect().width}px`)},[Pt]);(0,i.useEffect)(()=>(window.addEventListener("resize",_t),()=>{window.removeEventListener("resize",_t)}),[Pt,_t]),(0,i.useEffect)(()=>{Ee||(_t(),Jt())},[kt,Ee,_t,Jt]);const le=(0,i.useCallback)((Lt,Vt)=>yn(Lt,[Q,Do({techdocsStorageApi:bt,entityId:p,path:Vt}),Mo(),Jn(),Bo(),jo(),Wo(Bt),X]),[p,Bt,bt,Q,X]),Ae=(0,i.useCallback)(async Lt=>yn(Lt,[Xn(),eo($),no({baseUrl:window.location.origin,onClick:(Vt,te)=>{var xe;const Le=Vt.ctrlKey||Vt.metaKey,Fe=new URL(te),ve=((xe=Vt.target)===null||xe===void 0?void 0:xe.innerText)||te,Be=te.replace(window.location.origin,"");if(lt.captureEvent("click",ve,{attributes:{to:Be}}),Fe.hash)if(Le)window.open(te,"_blank");else{var ie;I(te),Lt==null||(ie=Lt.querySelector(`[id="${Fe.hash.slice(1)}"]`))===null||ie===void 0||ie.scrollIntoView()}else Le?window.open(te,"_blank"):I(te)}}),oo({onLoading:()=>{},onLoaded:()=>{var Vt;(Vt=Lt.querySelector(".md-nav__title"))===null||Vt===void 0||Vt.removeAttribute("for")}}),oo({onLoading:()=>{Array.from(Lt.querySelectorAll(".md-sidebar")).forEach(te=>{te.style.setProperty("opacity","0")})},onLoaded:()=>{}})]),[$,I,lt]);return(0,i.useEffect)(()=>{if(!Ht)return()=>{};let Lt=!0;return le(Ht,Zt).then(async Vt=>{if(!(Vt!=null&&Vt.innerHTML)||!Lt)return;window.scroll({top:0});const te=await Ae(Vt);he(te)}),()=>{Lt=!1}},[Ht,Zt,le,Ae]),Pt};var Un=t(41883),Qo=t(72020),$n=t(99730);const ro=()=>{const p=(0,Qo.YR)(),{shadowRoot:I}=(0,m.V)(),$=I==null?void 0:I.querySelector('[data-md-component="content"]'),F=I==null?void 0:I.querySelector('div[data-md-component="sidebar"][data-md-type="navigation"], div[data-md-component="navigation"]');let Q=F==null?void 0:F.querySelector('[data-techdocs-addons-location="primary sidebar"]');Q||(Q=document.createElement("div"),Q.setAttribute("data-techdocs-addons-location","primary sidebar"),F==null||F.prepend(Q));const X=I==null?void 0:I.querySelector('div[data-md-component="sidebar"][data-md-type="toc"], div[data-md-component="toc"]');let lt=X==null?void 0:X.querySelector('[data-techdocs-addons-location="secondary sidebar"]');return lt||(lt=document.createElement("div"),lt.setAttribute("data-techdocs-addons-location","secondary sidebar"),X==null||X.prepend(lt)),(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(Un.A,{container:Q,children:p.renderComponentsByLocation($n.e.PrimarySidebar)}),(0,o.jsx)(Un.A,{container:$,children:p.renderComponentsByLocation($n.e.Content)}),(0,o.jsx)(Un.A,{container:lt,children:p.renderComponentsByLocation($n.e.SecondarySidebar)})]})},so=(0,O.A)({search:{width:"100%","@media (min-width: 76.1875em)":{width:"calc(100% - 34.4rem)",margin:"0 auto"},"@media print":{display:"none"}}}),Dt=Qe(p=>{var I;const{withSearch:$=!0,onReady:F}=p,Q=so(),{entityMetadata:{value:X,loading:lt},entityRef:bt,setShadowRoot:Bt}=(0,m.V)(),kt=Yo(bt),Zt=window.location.pathname,Ht=window.location.hash,Pt=h(kt),[he]=P([`[id="${Ht.slice(1)}"]`]);(0,i.useEffect)(()=>{if(!Pt)if(Ht)he&&he.scrollIntoView();else{var Jt,_t;(_t=document)===null||_t===void 0||(Jt=_t.querySelector("header"))===null||Jt===void 0||Jt.scrollIntoView()}},[Zt,Ht,he,Pt]);const Ee=(0,i.useCallback)(Jt=>{Bt(Jt),F instanceof Function&&F()},[Bt,F]);return lt===!1&&!X?(0,o.jsx)(R.M,{status:"404",statusMessage:"PAGE NOT FOUND"}):kt?(0,o.jsx)(x.U,{children:(0,o.jsxs)(d.A,{container:!0,children:[(0,o.jsx)(d.A,{xs:12,item:!0,children:(0,o.jsx)($e,{})}),$&&(0,o.jsx)(d.A,{className:Q.search,xs:"auto",item:!0,children:(0,o.jsx)(de,{entityId:bt,entityTitle:X==null||(I=X.metadata)===null||I===void 0?void 0:I.title})}),(0,o.jsx)(d.A,{xs:12,item:!0,children:(0,o.jsx)(S,{element:kt,onAppend:Ee,children:(0,o.jsx)(ro,{})})})]})}):(0,o.jsx)(x.U,{children:(0,o.jsx)(d.A,{container:!0,children:(0,o.jsx)(d.A,{xs:12,item:!0,children:(0,o.jsx)($e,{})})})})}),fe=null},45061:function(Y,T,t){"use strict";t.d(T,{T:function(){return J}});var o=t(31085),i=t(14041),d=t(93285),O=t(42899),m=t(4387),v=t(13660),f=t(72020),c=t(86892),C=t(99730),A=t(67871),w=t(8859),h=t(34428),S=t(51372),g=t(58837),D=t(268),P=t(72501),y=t(72072);const j=(0,g.A)(q=>({root:{textAlign:"left"},label:{color:q.page.fontColor,fontWeight:q.typography.fontWeightBold,letterSpacing:0,fontSize:q.typography.fontSize,marginBottom:q.spacing(1)/2,lineHeight:1},value:{color:(0,D.X4)(q.page.fontColor,.8),fontSize:q.typography.fontSize,lineHeight:1}}),{name:"BackstageHeaderLabel"}),R=({value:q,className:yt,typographyRootComponent:at})=>(0,o.jsx)(P.A,{component:at!=null?at:typeof q=="string"?"p":"span",className:yt,children:q});function x(q){const{label:yt,value:at,url:Ot,contentTypograpyRootComponent:ht}=q,vt=j(),dt=(0,o.jsx)(R,{className:vt.value,value:at||"<Unknown>",typographyRootComponent:ht});return(0,o.jsx)(O.A,{item:!0,children:(0,o.jsxs)(P.A,{component:"span",className:vt.root,children:[(0,o.jsx)(P.A,{className:vt.label,children:yt}),Ot?(0,o.jsx)(y.N_,{to:Ot,children:dt}):dt]})})}var z=t(69814),_=t(72427),tt=t(65461),K=t(9222),W=t(45250),G=t(82779);const H=(0,o.jsx)(m.A,{animation:"wave",variant:"text",height:40}),J=q=>{const{children:yt}=q,at=(0,f.YR)(),Ot=(0,_.gf)(tt.U),{title:ht,setTitle:vt,subtitle:dt,setSubtitle:st,entityRef:mt,metadata:{value:Et,loading:Tt},entityMetadata:{value:gt,loading:it}}=(0,c.V)();(0,i.useEffect)(()=>{Et&&(vt(Et.site_name),st(()=>{let{site_description:Mt}=Et;return(!Mt||Mt==="None")&&(Mt=""),Mt}))},[Et,vt,st]);const ft=Ot.getOptional("app.title")||"Backstage",pt=[ht,dt,ft].filter(Boolean).join(" | "),{locationMetadata:Rt,spec:Ct}=gt||{},N=Ct==null?void 0:Ct.lifecycle,V=gt?(0,A.t)(gt,S.vv):[],xt=(0,K.S)(G.rQ)(),wt=(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(x,{label:(0,W.capitalize)((gt==null?void 0:gt.kind)||"entity"),value:(0,o.jsx)(w.z,{color:"inherit",entityRef:mt,title:gt==null?void 0:gt.metadata.title,defaultKind:"Component"})}),V.length>0&&(0,o.jsx)(x,{label:"Owner",value:(0,o.jsx)(h.i,{color:"inherit",entityRefs:V,defaultKind:"group"})}),N?(0,o.jsx)(x,{label:"Lifecycle",value:String(N)}):null,Rt&&Rt.type!=="dir"&&Rt.type!=="file"?(0,o.jsx)(x,{label:"",value:(0,o.jsxs)(O.A,{container:!0,direction:"column",alignItems:"center",children:[(0,o.jsx)(O.A,{style:{padding:0},item:!0,children:(0,o.jsx)(v.A,{style:{marginTop:"-25px"}})}),(0,o.jsx)(O.A,{style:{padding:0},item:!0,children:"Source"})]}),url:Rt.target}):null]});return!it&&gt===void 0||!Tt&&Et===void 0?null:(0,o.jsxs)(z.Y,{type:"Documentation",typeLink:xt,title:ht||H,subtitle:dt===""?void 0:dt||H,children:[(0,o.jsx)(d.A,{titleTemplate:"%s",children:(0,o.jsx)("title",{children:pt})}),wt,yt,at.renderComponentsByLocation(C.e.Header)]})}},82779:function(Y,T,t){"use strict";t.d(T,{Oc:function(){return d},Ri:function(){return O},rQ:function(){return i}});var o=t(34569);const i=(0,o.H)({id:"techdocs:index-page"}),d=(0,o.H)({id:"techdocs:reader-page",params:["namespace","kind","name"]}),O=(0,o.H)({id:"techdocs:catalog-reader-view"})},27698:function(Y,T,t){"use strict";t.r(T),t.d(T,{TechDocsSearchResultListItem:function(){return A}});var o=t(31085),i=t(14041),d=t(46423),O=t(5951),m=t(58837),v=t(72501),f=t(72072),c=t(70734);const C=(0,m.A)({flexContainer:{flexWrap:"wrap"},itemText:{width:"100%",marginBottom:"1rem"}}),A=w=>{const{result:h,highlight:S,lineClamp:g=5,asListItem:D=!0,asLink:P=!0,title:y,icon:j}=w,R=C(),x=({children:tt})=>P?(0,o.jsx)(f.N_,{noTrack:!0,to:h.location,children:tt}):(0,o.jsx)(o.Fragment,{children:tt}),z=()=>{const tt=S!=null&&S.fields.title?(0,o.jsx)(c.e,{text:S.fields.title,preTag:S.preTag,postTag:S.postTag}):h.title,K=S!=null&&S.fields.entityTitle?(0,o.jsx)(c.e,{text:S.fields.entityTitle,preTag:S.preTag,postTag:S.postTag}):h.entityTitle,W=S!=null&&S.fields.name?(0,o.jsx)(c.e,{text:S.fields.name,preTag:S.preTag,postTag:S.postTag}):h.name;return h?(0,o.jsx)(O.A,{className:R.itemText,primaryTypographyProps:{variant:"h6"},primary:(0,o.jsx)(x,{children:y||(0,o.jsxs)(o.Fragment,{children:[tt," | ",K!=null?K:W," docs"]})}),secondary:(0,o.jsx)(v.A,{component:"span",style:{display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:g,overflow:"hidden"},color:"textSecondary",variant:"body2",children:S!=null&&S.fields.text?(0,o.jsx)(c.e,{text:S.fields.text,preTag:S.preTag,postTag:S.postTag}):h.text})}):null},_=({children:tt})=>D?(0,o.jsxs)(o.Fragment,{children:[j&&(0,o.jsx)(d.A,{children:typeof j=="function"?j(h):j}),(0,o.jsx)("div",{className:R.flexContainer,children:tt})]}):(0,o.jsx)(o.Fragment,{children:tt});return(0,o.jsx)(_,{children:(0,o.jsx)(z,{})})}},86973:function(){}},function(Y){var T=function(o){return Y(Y.s=o)};Y.O(0,[1751,1888,5067,1678,235,6587,2754,9669,1975,5042,7400,4121],function(){return T(85318)});var t=Y.O()}]);})();
496
+
497
+ //# sourceMappingURL=main.e5571a2f.js.map