!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e.SENTRY_RELEASE={id:"6f8fd777495ec30113c7d19e3c90e6767827ed67"};var r=(new e.Error).stack;r&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[r]="38bcc8a6-6fd8-4f30-852b-8597514305ec",e._sentryDebugIdIdentifier="sentry-dbid-38bcc8a6-6fd8-4f30-852b-8597514305ec")}catch(e){}}(),(globalThis.webpackChunkcloud_frontend=globalThis.webpackChunkcloud_frontend||[]).push([[6026],{96026(e,r,t){t.d(r,{l:()=>b,q:()=>u});t(25509),t(65223),t(60321),t(41927),t(11632),t(64377),t(66771),t(12516),t(68931),t(52514),t(35694),t(52774),t(49536),t(21926),t(94483),t(16215);var a=t(96540),n=t(5981),d=t(42790),o=t(61841),s=t(24609),l=t(24013),c=t(19075),f=t(91421),i=t(15750);const u=e=>{let{alertId:r,alertName:t,nodeIds:d=[]}=e;const s=(0,n.Zp)(),{setState:i}=(0,f.$h)(),[u]=(0,o.Ay)(),{name:b}=(0,c.JL)(r),h=t||b,{isParent:p}=(0,l.xY)(d[0]),{loaded:g,value:y,hasError:w,error:I}=(0,f.wd)({node:{value:d[0],isParent:p},path:"/health"}),E=!!y?.tree?.["/health/alerts/prototypes"]?.[`health:alert:prototype:${h}`],[,k]=(0,f.PJ)();return{canEdit:g&&!w&&E,goToEdit:(0,a.useCallback)(e=>{d=e?Array.from(new Set([e,...d])):d,i({alertName:h,isAlert:!0}),k(!0,{nodeId:d[0]})},[h,d,u,i,s]),error:I?.errorMessage||I}},b=()=>{const e=(0,n.Zp)(),{slug:r}=(0,s.ap)(),t=(0,d.rI)(),o=(0,i.A)();return(0,a.useCallback)(a=>{a&&(t(e=>({...e,dyncfgSearchTerm:a})),e(o(`/spaces/${r}/settings/configurations`),{replace:!0}))},[e,t,r,o])}}}]);