import{e as s}from"../chunks/DTHo7gyJ.mjs";import"../chunks/E-vkuI0X.mjs";import{i as l}from"../chunks/DueIe5zz.mjs";import{p as c,d as p,i as f,u as d}from"../chunks/Dpn8_Hnn.mjs";import{p as m}from"../chunks/CUWjGq9Z.mjs";import{p as i}from"../chunks/BDSEKKhr.mjs";import{C as u}from"../chunks/BDhjH3TH.mjs";import{i as g,g as h}from"../chunks/BMOqNL4y.mjs";function w(a){try{return BigInt(a)}catch{return null}}const _=(async({params:a,depends:t})=>{t("anki:card-info");const o=w(a.cardId);return{info:o!==null?await s({cid:o}):null}}),j=Object.freeze(Object.defineProperty({__proto__:null,load:_},Symbol.toStringTag,{value:"Module"}));function B(a,t){c(t,!1);let o=m(t,"data",8);const r=i.url.searchParams.get("revlog")!=="0";globalThis.anki||(globalThis.anki={}),globalThis.anki.updateCard=async n=>{const e=`/card-info/${n}`;i.params.cardId===n?await g("anki:card-info"):await h(e).catch(()=>{window.location.href=e})},l(),u(a,{get stats(){return f(o()),d(()=>o().info)},get showRevlog(){return r}}),p()}export{B as component,j as universal};
