PageSourceSearch

https://tcgcrew.com/assets/CardSheet-aHHfYtLK.js

js tcgcrew.com collected 2026-10-02 16:05:13 UTC 15,620 bytes, 1 lines download raw bytes

1import{u as ce,ah as K,w as X,j as e,v as T}from"./index-PXpjhCaY.js";import{d as de}from"./firstEdition-Bavnei6j.js";import{j as me,d as ue,u as xe,r as x,L as j}from"./vendor-react-SfNqDmFq.js";import{S as pe}from"./SEO-DRrzrYV4.js";import{L as fe}from"./index-K5F0f3ue.js";import{b as be,a as ge,d as he}from"./marketLinks-BrWK0B3r.js";import{C as je}from"./CardPriceCharts-Dnn87CuH.js";import{I as ye,P as ve}from"./PcGradedPanel-BhFAGgqM.js";import{t as Ne}from"./EbayMarteauPanel-BSLJ48i_.js";import{N as Ce}from"./NmPriceChart-FSb04S0I.js";import{P as we}from"./PcLoosePriceChart-QjmraUw9.js";import{CardmarketPriceChart as Y}from"./CardmarketPriceChart-jVwtZfZl.js";import{G as $e}from"./GCCComparablesPanel-C3TCwe4N.js";import{n as ke,aa as Pe,T as Se,ar as Ae}from"./vendor-icons-Dq2TnJO2.js";import"./vendor-state-GakPUnLx.js";import"./vendor-http-C0Zqfgkc.js";import"./mastersetApi-CGclctiP.js";import"./cardmarketHistory-KWIFJz8M.js";import"./vendor-charts-CR7lJZ_9.js";import"./EbayLogo-CoMes3fP.js";import"./sealedCollectionApi-BCChMxV2.js";function Le(s,t){for(const a of[s,t])if(a!=null&&a.trim())try{const n=new URL(a.trim());if(!["https:","http:"].includes(n.protocol))continue;return n.hostname==="images.tcgcrew.com"&&/^\/cards\/(fr|jp|chn)\/[^/]+\/[^/.]+\/?$/.test(n.pathname)&&(n.pathname=`${n.pathname.replace(/\/$/,"")}/high.webp`),n.href}catch{}return null}const Ee={background:"linear-gradient(160deg, rgba(232,182,76,0.13), rgba(232,182,76,0.04))",borderColor:"rgba(232,182,76,0.34)"},Ge="#b91c1c",Ue=Object.fromEntries(fe.map(s=>[s.code,s.label]));function A(s){const t=(s||"").trim().toUpperCase();return t==="JP"||t==="JA"||t.startsWith("JAPON")||t==="EN"||t==="ANGLAIS"||t==="US"||t==="GB"||t==="UK"}function Fe(s){const t=(s||"").trim();if(!t)return{company:null,grade:null};const a=t.lastIndexOf("-");if(a<=0)return{company:null,grade:null};const n=t.slice(0,a).trim().toUpperCase(),g=t.slice(a+1).trim().replace(",",".");return!n||!/^\d+(\.\d+)?$/.test(g)?{company:null,grade:null}:{company:n,grade:g}}function L(s){const t=(s||"").trim();return t?t.length>120?t.slice(0,120):t:null}function Ie(s){return s==null?"—":s>=100?`${Math.round(s).toLocaleString("fr-FR")} €`:`${s.toLocaleString("fr-FR",{minimumFractionDigits:0,maximumFractionDigits:2})} €`}function Me(s){if(!s)return null;const t=Date.parse(s);if(!Number.isFinite(t))return null;const a=Math.floor((Date.now()-t)/864e5);if(a<=0)return"aujourd'hui";if(a===1)return"hier";if(a<7)return`il y a ${a} jours`;if(a<60){const g=Math.max(1,Math.round(a/7));return`il y a ${g} semaine${g>1?"s":""}`}if(a<365)return`il y a ${Math.round(a/30)} mois`;const n=Math.floor(a/365);return`il y a ${n} an${n>1?"s":""}`}function Te({children:s}){return e.jsx("span",{className:"inline-flex items-center h-[22px] px-2 rounded-md text-[11px] font-semibold uppercase tracking-[0.04em] text-lab-text-secondary bg-lab-subtle/70 border border-lab-border-subtle whitespace-nowrap",children:s})}function D({href:s,children:t}){return e.jsxs("a",{href:s,target:"_blank",rel:"noopener noreferrer nofollow",className:"inline-flex items-center justify-center gap-1.5 h-10 px-3.5 rounded-xl border border-lab-border-default bg-lab-elevated/60 text-[13px] font-semibold text-lab-text-secondary hover:text-lab-text-primary hover:border-lab-border-hover motion-safe:transition-colors whitespace-nowrap",children:[t,e.jsx(Ae,{size:13,"aria-hidden":!0})]})}function nt(){var J,H;const{cardmarketId:s}=me(),[t]=ue(),a=t.get("edition")||void 0,n=t.get("foil")||void 0,g=xe(),{isAuthenticated:p,isLoading:G,checkAuth:B}=ce();x.useEffect(()=>{G&&B()},[G,B]);const o=x.useMemo(()=>{const r=parseInt(s||"",10);return Number.isInteger(r)&&r>0?r:null},[s]),w=(t.get("name")||"").trim(),d=(t.get("set")||"").trim(),y=(t.get("setCode")||"").trim(),c=(t.get("num")||"").trim(),i=(t.get("lang")||"").trim().toUpperCase(),W=(t.get("img")||"").trim(),{company:l,grade:m}=x.useMemo(()=>Fe(t.get("grade")),[t]),b=!!l&&!!m,[v,O]=x.useState(null),[R,U]=x.useState(!1);x.useEffect(()=>{if(O(null),U(!1),!p||!c||!i){U(!0);return}const r=new AbortController;return K.collectionCard({cardmarketId:o,language:i,setName:d,setCode:y||void 0,number:c},r.signal).then(u=>{if(r.signal.aborted)return;const f=u.data.data;O(f),!l&&(f!=null&&f.collectionPath)&&/^\/masterset\/set\/(INT|JP|CHN)\/[^/?#]+\?card=/.test(f.collectionPath)&&g(f.collectionPath,{replace:!0})}).catch(()=>{}).finally(()=>{r.signal.aborted||U(!0)}),()=>r.abort()},[p,o,c,i,d,y,l,g]);const Q=Ue[i]||i||null,h=w||"Carte",$=Le((J=v==null?void 0:v.card)==null?void 0:J.imageUrl,W),[Z,ee]=x.useState(null),[k,P]=x.use
1State({loading:!0,data:null});x.useEffect(()=>{if(!p||!w){P({loading:!1,data:null});return}if(!R||v&&!l){P({loading:!0,data:null});return}const r=new AbortController;let u=!1;return P({loading:!0,data:null}),K.coteForCard({cardmarketId:o,edition:a||null,variantFoil:n||null,language:L(i),gradingCompany:L(l),grade:L(m),setName:L(d),number:L(c)},r.signal).then(f=>{var C;u||P({loading:!1,data:((C=f.data)==null?void 0:C.data)??null})}).catch(()=>{u||P({loading:!1,data:null})}),()=>{u=!0,r.abort()}},[p,o,i,l,m,d,c,w,R,v,a,n]);const[N,F]=x.useState(null);x.useEffect(()=>{if(!p||!o||!A(i)){F(null);return}const r=new AbortController;let u=!1;return X.pcGradedAll(o,{company:l||void 0,grade:m||void 0,edition:a||void 0,foil:n,...de(a)?{firstEdition:1}:{}},r.signal).then(f=>{var C;u||F(((C=f.data)==null?void 0:C.data)??null)}).catch(()=>{u||F(null)}),()=>{u=!0,r.abort()}},[p,o,l,m,i,a,n]);const[I,S]=x.useState(null);x.useEffect(()=>{if(!p||!b||A(i)){S(null);return}if(!l||!m){S(null);return}const r=new AbortController;let u=!1;return S(null),X.gccComparables({gradingCompany:l,edition:a,variantFoil:n,grade:m,language:i||void 0,reference:c||void 0,setName:d||void 0},r.signal).then(f=>{var C;u||S(((C=f.data)==null?void 0:C.data)??null)}).catch(()=>{u||S(null)}),()=>{u=!0,r.abort()}},[p,b,i,l,m,c,d,a,n]);const te=b?"Carte gradée":"Carte",ae=(v==null?void 0:v.cardmarketUrl)||be(h,d||void 0,c||void 0,i||void 0),re=ge(h,{setName:d||void 0,setNumber:c||void 0,setCode:y||void 0,edition:a,language:i||void 0,itemType:te,gradingCompany:l||void 0,grade:m||void 0}),se=he(h,d||void 0,c||void 0),ne=!!l&&l.includes("PSA"),E=encodeURIComponent(`${window.location.pathname}${window.location.search}`),q=T?`/login?next=${E}`:`/landing?auth=login&next=${E}`,M=T?`/login?register=true&next=${E}`:`/landing?auth=register&next=${E}`,z=[d,c?`n° ${c}`:"",Q].filter(Boolean).join(" · "),ie=[h,c].filter(Boolean).join(" "),_=((H=k.data)==null?void 0:H.coteSource)==="ventes"?Me(k.data.coteDate):null,le=x.useMemo(()=>{const r=new URLSearchParams;w&&r.set("name",w),d&&r.set("set",d),y&&r.set("setCode",y),c&&r.set("num",c),i&&r.set("lang",i),a&&r.set("edition",a),n&&r.set("foil",n),b&&r.set("grade",`${l}-${m}`);const u=r.toString();return`/carte/${o??0}${u?`?${u}`:""}`},[w,d,y,c,i,b,l,m,o,a,n]),oe=!b&&o?A(i)?e.jsx(we,{cardmarketId:o,fallback:e.jsx(Y,{cardmarketId:o})}):e.jsx(Ce,{cardmarketId:o,fallback:e.jsx(Y,{cardmarketId:o})}):null,V=x.useMemo(()=>{if(!N)return!1;if(N.gradedEur!=null||N.bracket)return!0;const r=N.prices;return r?["grade9","grade95","psa10","bgs10","cgc10"].some(u=>(r[u]??0)>0):!1},[N]);return e.jsxs("div",{className:"min-h-screen bg-lab-void",children:[e.jsx(pe,{title:`${h} — cote et évolution`,description:`Cote et évolution de la carte ${h}${d?` (${d}${c?` n° ${c}`:""})`:""}${b?` gradée ${l} ${m}`:""} — ventes équivalentes, courbe de prix et liens marché sur TCG Crew.`,canonical:le,ogImage:$||void 0,ogType:"article"}),e.jsx("header",{className:"border-b border-lab-border-subtle bg-lab-base/80 backdrop-blur-sm sticky top-0 z-40",children:e.jsxs("div",{className:"max-w-5xl mx-auto px-4 sm:px-6 h-16 flex items-center justify-between gap-3",children:[e.jsxs(j,{to:p?"/":"/landing",className:"flex items-center gap-2 text-lab-text-primary font-display font-bold text-lg hover:opacity-80 motion-safe:transition",children:[e.jsx("img",{src:"/android-chrome-192x192.png",alt:"","aria-hidden":!0,className:"w-8 h-8 rounded-lg"}),"TCG Crew"]}),p?e.jsx(j,{to:"/inventory",className:"text-sm text-lab-text-secondary hover:text-lab-text-primary motion-safe:transition",children:"Mon inventaire"}):e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx(j,{to:q,className:"text-sm text-lab-text-secondary hover:text-lab-text-primary motion-safe:transition",children:"Se connecter"}),e.jsx(j,{to:M,className:"text-sm px-4 py-2 rounded-lg bg-gradient-to-r from-type-electric to-type-fire text-lab-void font-semibold hover:opacity-90 motion-safe:transition",children:"Créer un compte"})]})]})}),e.jsxs("main",{className:"max-w-5xl mx-auto px-4 sm:px-6 py-6 sm:py-8 space-y-6",children:[e.jsx("nav",{"aria-label":"Fil d'Ariane",className:"text-[11px] sm:text-xs text-lab-text-tertiary",children:e.jsxs("ol",{className:"flex flex-wrap items-center gap-1.5",children:[e.jsx("li",{children:"Cartes"}
1),d&&e.jsxs(e.Fragment,{children:[e.jsx("li",{"aria-hidden":!0,className:"opacity-50",children:"›"}),e.jsx("li",{className:"truncate max-w-[40vw] sm:max-w-none",children:d})]}),e.jsx("li",{"aria-hidden":!0,className:"opacity-50",children:"›"}),e.jsx("li",{"aria-current":"page",className:"text-lab-text-secondary truncate max-w-[50vw] sm:max-w-none",children:ie})]})}),e.jsxs("section",{className:"grid grid-cols-[minmax(96px,132px)_1fr] sm:grid-cols-[180px_1fr] gap-4 sm:gap-6 items-start",children:[e.jsx("div",{className:"w-full rounded-2xl overflow-hidden bg-lab-subtle/50 border border-lab-border-subtle",style:{aspectRatio:"3 / 4.2",boxShadow:"0 18px 40px -22px rgba(0,0,0,0.85)"},children:$&&Z!==$?e.jsx("img",{src:$,alt:h,loading:"lazy",decoding:"async",onError:()=>ee($),className:"w-full h-full object-cover"},$):e.jsx("div",{className:"w-full h-full flex items-center justify-center text-[11px] text-lab-text-tertiary text-center px-2",children:"Visuel indisponible"})}),e.jsxs("div",{className:"min-w-0",children:[e.jsx("h1",{className:"text-2xl sm:text-3xl font-extrabold text-lab-text-primary leading-tight break-words",children:h}),z&&e.jsx("p",{className:"mt-1.5 text-sm text-lab-text-secondary",children:z}),e.jsxs("div",{className:"mt-3 flex flex-wrap items-center gap-2",children:[b&&e.jsxs("span",{className:"inline-flex items-center h-[22px] px-2 rounded-md text-[11px] font-bold uppercase tracking-[0.05em] text-white whitespace-nowrap",style:{backgroundColor:Ge},children:[l," ",m]}),y&&e.jsx(Te,{children:y})]})]})]}),G?e.jsx("div",{className:"h-28 rounded-2xl border border-lab-border-subtle bg-lab-subtle/30 motion-safe:animate-pulse"}):p?e.jsxs("section",{className:"rounded-2xl border p-4 sm:p-5",style:Ee,children:[e.jsx("div",{className:"text-[10px] font-bold uppercase tracking-[0.12em]",style:{color:"rgb(232,182,76)"},children:"★ Cote retenue"}),k.loading?e.jsx("div",{className:"mt-2.5 h-10 w-40 rounded-lg bg-white/[0.06] motion-safe:animate-pulse"}):k.data?e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"mt-1.5 text-4xl font-extrabold tabular-nums text-lab-text-primary",children:Ie(k.data.coteEur)}),e.jsxs("p",{className:"mt-1.5 text-[12px] text-lab-text-secondary",children:[k.data.coteLabel,_&&e.jsxs(e.Fragment,{children:[" · dernière vente ",_]})]})]}):e.jsx("p",{className:"mt-2 text-[13px] text-lab-text-secondary leading-snug",children:"Pas de cote fiable pour cette carte aujourd'hui — une fausse cote serait pire que pas de cote. Les liens marché ci-dessous restent disponibles."})]}):e.jsxs("section",{className:"rounded-2xl border-2 border-dashed p-5 text-center",style:{borderColor:"rgba(232,182,76,0.34)",background:"linear-gradient(160deg, rgba(232,182,76,0.13), rgba(232,182,76,0.04))"},children:[e.jsx(ke,{size:18,className:"mx-auto mb-2",style:{color:"rgb(232,182,76)"},"aria-hidden":!0}),e.jsx("h2",{className:"text-base font-bold text-lab-text-primary",children:"Cote et courbes réservées aux membres"}),e.jsx("p",{className:"mt-1.5 text-[13px] text-lab-text-secondary max-w-md mx-auto leading-snug",children:"Crée ton compte gratuit pour voir la cote retenue de cette carte, sa courbe d'évolution et le barème des autres notes."}),e.jsxs("div",{className:"mt-4 flex flex-col sm:flex-row items-center justify-center gap-2.5",children:[e.jsx(j,{to:M,className:"w-full sm:w-auto inline-flex items-center justify-center h-11 px-5 rounded-xl font-bold text-[14px] text-lab-void motion-safe:transition hover:opacity-90",style:{background:"linear-gradient(135deg, #f0c979, #e8b64c)"},children:"Créer un compte gratuit"}),e.jsx(j,{to:q,className:"w-full sm:w-auto inline-flex items-center justify-center h-11 px-5 rounded-xl border border-lab-border-default text-[14px] font-semibold text-lab-text-secondary hover:text-lab-text-primary motion-safe:transition",children:"Se connecter"})]})]}),e.jsxs("section",{className:"flex flex-wrap gap-2.5",children:[e.jsxs("button",{type:"button",onClick:()=>g(p?"/inventory":M),className:"inline-flex items-center justify-center gap-1.5 h-10 px-4 rounded-xl font-bold text-[13px] text-lab-void motion-safe:transition hover:opacity-90",style:{background:"linear-gradient(135deg, #f0c979, #e8b64c)"},children:[e.jsx(Pe,{size:15,"aria-hidden":!0}),"Ajouter à mon inventaire"]}),ne&&e.jsx(D,{href:se,children:"Voir la fiche PSA"}),e.jsx(D,{href:ae,children:"Cardmarket"}),e.jsx(D,{href:re,children:"Ventes eBay"})]}),p&&e.jsxs("section",{className:"grid grid-cols-1 lg:grid-cols-2 gap-4 items-start",children:[e.jsxs("div",{className:`rounded-2xl border border-lab-border-default bg-lab-elevated/40 p-4 ${V?"":"lg:col-span-2"}`,children:[e.jsxs("h2",{className:"flex items-center gap-1.5 text-[10px] font-semibold uppercase tracking-[0.12em] text-lab-text-tertiary",children:[e.jsx(Se,{size:11,"aria-hidden":!0}),"Évolution · ",b?`${l} ${m}
1`:"ventes équivalentes"]}),o&&b?e.jsx("div",{className:"mt-3",children:e.jsx(ye,{cardmarketId:o,edition:a,variantFoil:n,language:i,gradingCompany:l,grade:m,itemName:h,setName:d,setNumber:c,hideGain:!0,hideGccOverlay:A(i),hideEbayOverlay:A(i)},`${o}:${i}:${l}:${m}:${a||""}:${n||""}`)}):o?e.jsx(je,{cardmarketId:o,preferredBucket:Ne(l,m),language:i||null,fallback:oe}):e.jsx("p",{className:"mt-3 text-[12px] text-lab-text-tertiary leading-snug",children:"Cette carte n'est pas encore reliée à une référence marché — pas de courbe pour l'instant."})]}),V&&e.jsxs("div",{children:[e.jsx("h2",{className:"mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-lab-text-tertiary",children:"Autres notes · à titre indicatif"}),e.jsx(ve,{company:l,grade:m,gradedEur:N.gradedEur,bracket:N.bracket,prices:N.prices,heldAsCote:!1})]}),I&&I.count>0&&e.jsxs("div",{children:[e.jsx("h2",{className:"mb-2 text-[10px] font-semibold uppercase tracking-[0.12em] text-lab-text-tertiary",children:"Ventes équivalentes"}),e.jsx($e,{data:I})]})]})]}),e.jsxs("footer",{className:"border-t border-lab-border-subtle py-8 px-4 text-center",children:[e.jsxs("div",{className:"flex flex-wrap justify-center gap-x-6 gap-y-2 text-sm text-lab-text-tertiary",children:[e.jsx(j,{to:T?"/login":"/landing",className:"hover:text-lab-text-secondary motion-safe:transition",children:"Accueil"}),e.jsx(j,{to:"/pricing",className:"hover:text-lab-text-secondary motion-safe:transition",children:"Tarifs"}),e.jsx(j,{to:"/legal",className:"hover:text-lab-text-secondary motion-safe:transition",children:"Mentions légales"})]}),e.jsxs("p",{className:"mt-4 text-xs text-lab-text-tertiary/60",children:["© ",new Date().getFullYear()," TCG Crew — NUMYXTCG SASU. Cotes indicatives, sans valeur contractuelle."]})]})]})}export{nt as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.