import{_ as $,a as V}from"./DR96n_VU.js";import{_ as q}from"./gQe2oyAA.js";import{_ as K}from"./BYHNlRPy.js";import{_ as L}from"./CS_MeOS_.js";import{_ as P}from"./C9KnTrrC.js";import{_ as j}from"./DWMTOSv8.js";import{_ as O}from"./DvpWg0hF.js";import{d as U,M as W,a2 as z,k as G,N as J,a3 as Q,I as X,f as o,b as t,q as i,a as n,c as u,w as p,u as e,F as _,g as k,s as Y,e as Z,t as b}from"./B2UyoCas.js";import"./8cAMPTBV.js";import"./BGYJXalu.js";import"./CsNNGtvO.js";import"./DeNTsafF.js";import"./BhXuhlb7.js";import"./Bw4qhTdR.js";import"./88opOQSr.js";import"./CVosDfjh.js";import"./DmViyvlQ.js";import"./ABctaOB9.js";import"./CB3BcoM2.js";import"./DaLgO_IH.js";import"./Cy--ZdFw.js";import"./NkNhW2e0.js";const ee={key:0,class:"flex items-center o_gap-2 flex-wrap o_mb-4"},te={key:1,class:"flex flex-col o_gap-6 @container/simpleresult"},oe={key:0,class:"text-uiText-muted font-normal"},re={class:"list-disc o_ml-4 text-sm text-uiText-toned text-pretty max-w-[70ch]"},y="sitemapmobile",Ee=U({__name:"sitemapMobile-[pid]-[sid]",setup(se){const{kapi:S}=W(),{setCachedData:M,addTimeToProcessedData:v}=z(),d=G(),{sid:c,pid:w}=d.params;if(!c)throw new Error("sid is required");const{trackFirstSeen:C}=J(),{data:a,error:f,status:ne,refresh:h}=Q(`metrics-sitemap-${c||0}`,async()=>await S("CheckSitemap").then(r=>r.getResults(Number(c))),{transform:r=>{C(Number(w),Number(c),d.name);const l={results:Object.values(r.results)};return v(l)},getCachedData:(r,l,m)=>{if(!(m.cause==="refresh:manual"||m.cause==="refresh:hook"))return M(r)}}),{t:g}=X();return(r,l)=>{var x;const m=$,D=q,E=V,N=K,R=L,T=P,A=j,H=O;return t(),o("div",null,[i(D,{"page-key":"pMonitoringSeoSitemapMobile"},{title:p(()=>[i(m,{title:"pMonitoringSeoSitemapMobile","info-type":y})]),_:1}),(x=e(a))!=null&&x.results?(t(),o(_,{key:0},[i(E,{"data-count":e(a).results.length,class:"o_mb-6"},null,8,["data-count"]),e(a).results.length?(t(),o("div",ee,[i(N,{"metric-key":y,onSaveSettings:e(h)},null,8,["onSaveSettings"])])):n("",!0),e(a).results.length?(t(),o("div",te,[(t(!0),o(_,null,k(e(a).results,(s,B)=>(t(),u(A,{key:B,"component-info":s.component},{header:p(()=>[s.component.name?(t(),o("span",oe,b(`(${s.component.name})`),1)):n("",!0)]),default:p(()=>[i(R,{status:s.errors.length?"danger":"success",title:e(g)("sitemapMobileResults.sitemapErrorHeadline",{n:s.errors.length}),description:e(g)("sitemapMobileResults.sitemapErrorSubline"),class:"o_mb-2"},null,8,["status","title","description"]),s.errors.length?(t(),u(T,{key:0,title:r.$t("sitemapMobileResults.sitemapErrorList"),color:"error",variant:"subtle",icon:e(Y).icoError,class:"o_mt-6 max-w-max"},{description:p(()=>[Z("ul",re,[(t(!0),o(_,null,k(s.errors,(F,I)=>(t(),o("li",{key:I},b(F),1))),128))])]),_:2},1032,["title","icon"])):n("",!0)]),_:2},1032,["component-info"]))),128))])):n("",!0)],64)):n("",!0),e(f)?(t(),u(H,{key:1,error:e(f),refresh:e(h)},null,8,["error","refresh"])):n("",!0)])}}});export{Ee as default};
