`)}:!a.ok&&"detail"in h?{error:h.detail}:h})}function Zs(n){return In(this,null,function*(){return yield Ru(n,"GET")})}function*Ci(...n){for(let t of n)for(let e of document.querySelectorAll(t))e!==null&&(yield e)}function Js(n){n.startsWith("data-")||(n=`data-${n}`);for(let t of Ci("body > div#netbox-data > *")){let e=t.getAttribute(n);if(Nu(e))return e}return null}function ju(n,t){n!==null&&(typeof t=="undefined"?window.getComputedStyle(n).display==="none"?n.style.display="":n.style.display="none":t==="show"?n.style.display="":n.style.display="none")}function Ln(n){for(let t of Ci("div.card-overlay"))ju(t,n)}function W(n,t,e=null,i=[]){let r=document.createElement(n);if(t!==null)for(let o of Object.keys(t)){let s=o,a=t[s];s in r&&(r[s]=a)}e!==null&&e.length>0&&r.classList.add(...e);for(let o of i)r.appendChild(o);return r}function to(n){return n*(9/5)+32}window.Collapse=_t;window.Modal=re;window.Popover=ye;window.Toast=ae;window.Tooltip=Nt;function Mn(n,t,e,i){let r="mdi-alert";switch(n){case"warning":r="mdi-alert";break;case"success":r="mdi-check-circle";break;case"info":r="mdi-information";break;case"danger":r="mdi-alert";break}let o=document.createElement("div");o.setAttribute("class","toast-container position-fixed bottom-0 end-0 m-3");let s=document.createElement("div");s.setAttribute("class",`toastbg-${n}`),s.setAttribute("role","alert"),s.setAttribute("aria-live","assertive"),s.setAttribute("aria-atomic","true");let a=document.createElement("div");a.setAttribute("class",`toast-headerbg-${n}text-body`);let u=document.createElement("i");u.setAttribute("class",`mdi${r}`);let h=document.createElement("strong");h.setAttribute("class","me-auto ms-1"),h.innerText=t;let f=document.createElement("button");f.setAttribute("type","button"),f.setAttribute("class","btn-close"),f.setAttribute("data-bs-dismiss","toast"),f.setAttribute("aria-label","Close");let v=document.createElement("div");if(v.setAttribute("class","toast-body"),a.appendChild(u),a.appendChild(h),typeof i!="undefined"){let m=document.createElement("small");m.setAttribute("class","text-muted"),a.appendChild(m)}return a.appendChild(f),v.innerText=e.trim(),s.appendChild(a),s.appendChild(v),o.appendChild(s),document.body.appendChild(o),new ae(s)}le.default.extend(eo.default);le.default.extend(no.default);le.default.extend(ro.default);le.default.extend(io.default);var Hu=["hostname","fqdn","vendor","model","serial_number","os_version"],Wu=["years","months","days","hours","minutes","seconds"];function Bu(n){let t=new Date,e=t.getTimezoneOffset(),r=(0,le.default)(t).subtract(n,"seconds"),o=r.tz("Etc/UTC").format("YYYY-MM-DD HH:MM:ss z"),s=null;e!==0&&(s=r.format("YYYY-MM-DD HH:MM:ss z"));let a=le.default.duration(n,"seconds"),u=[];for(let f of Wu){let v=a[f]();if(v===1){let d=f.replace(/s$/,"");u=[...u,`${v}${d}`]}else v>1&&(u=[...u,`${v}${f}`])}let h="None";return u.length>0&&(h=u.join(", ")),{utc:o,zoned:s,duration:h}}function Vu(n){for(let a of Hu)if(a in n){let u=document.getElementById(a);u!==null&&(u.innerHTML=String(n[a]))}let{uptime:t}=n,{utc:e,zoned:i,duration:r}=Bu(t),o=document.getElementById("uptime-duration");o!==null&&(o.innerHTML=r);let s=document.getElementById("uptime");s!==null&&(i===null?s.innerHTML=e:s.innerHTML=[i,`<spanclass="fst-italic d-block">${e}</span>`].join(""))}functionUe(n,t,e){leti=W("th",{innerText:t},["border-end","text-end"]),r=W("th",{innerText:e},["border-start","text-start"]),o=W("tr",{},[],[i,r]);n.insertAdjacentElement("beforebegin",o)}functionKe(n){lett=W("td",{colSpan:"2",innerText:"NoData"},["text-muted","text-center"]),e=W("tr",{},[],[t]);n!==null&&n.insertAdjacentElement("beforebegin",e)}functionqe(n){lett=document.getElementById(n);returnt!==null?t.nextElementSibling:null}functionzu(n){lett=qe("status-cpu");if(typeofn!="undefined"){if(t!==null){Ue(t,"Name","Usage");for(let[e,i]ofObject.entries(n)){letr=i["%usage"],o=W("td",{innerText:e},["border-end","text-end"]),s=W("td",{innerText:`${r}%`},["border-start","text-start"]),a=W("tr",{},[],[o,s]);t.insertAdjacentElement("beforebegin",a)}}}elseKe(t)}fun