1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,33717,e=>{"use strict";var t=e.i(43476),s=e.i(71645);let r=[{value:"1h",label:"1 heure"},{value:"1j",label:"1 jour"},{value:"1m",label:"1 mois"},{value:"1a",label:"1 an"},{value:"infini",label:"Infini"}];e.s(["default",0,function(){var e;let[a,l]=(0,s.useState)(null),[n,i]=(0,s.useState)("1j"),[o,c]=(0,s.useState)({status:"idle"}),[u,d]=(0,s.useState)(!1),[x,g]=(0,s.useState)(!1),p=(0,s.useRef)(null);function h(e){l(e),c({status:"idle"})}let m="uploading"===o.status;return(0,t.jsx)("main",{className:"min-h-screen flex flex-col items-center justify-center p-8 bg-gray-950 text-white",children:(0,t.jsxs)("div",{className:"w-full max-w-2xl space-y-6",children:[(0,t.jsxs)("div",{className:"text-center space-y-2",children:[(0,t.jsx)("h1",{className:"text-4xl font-bold tracking-tight",children:"t8ls"}),(0,t.jsx)("p",{className:"text-gray-400",children:"Dépose un fichier. Récupère un lien."})]}),"done"===o.status?(0,t.jsxs)("div",{className:"p-5 rounded-xl bg-gray-800 border border-gray-700 space-y-4",children:[(0,t.jsx)("h2",{className:"text-xs font-semibold text-gray-400 uppercase tracking-wider",children:"Lien du fichier"}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("span",{className:"flex-1 font-mono text-sm text-gray-200 truncate",children:o.url}),(0,t.jsx)("button",{onClick:function(){"done"===o.status&&navigator.clipboard.writeText(o.url).then(()=>{g(!0),setTimeout(()=>g(!1),2e3)})},className:`shrink-0 px-3 py-1.5 rounded-lg text-xs transition-colors ${x?"bg-green-900 text-green-400":"bg-gray-700 hover:bg-gray-600 text-gray-200"}`,children:x?"Copié !":"Copier"})]}),(0,t.jsx)("button",{onClick:function(){l(null),c({status:"idle"}),p.current&&(p.current.value="")},className:"text-xs text-gray-500 hover:text-gray-300 transition-colors",children:"Envoyer un autre fichier"})]}):(0,t.jsxs)("div",{className:"p-5 rounded-xl bg-gray-800 border border-gray-700 space-y-4",children:[(0,t.jsxs)("div",{onDragOver:e=>{e.preventDefault(),d(!0)},onDragLeave:()=>d(!1),onDrop:e=>{e.preventDefault(),d(!1);let t=e.dataTransfer.files[0];t&&h(t)},onClick:()=>p.current?.click(),className:`flex flex-col items-center justify-center gap-2 py-12 rounded-lg border-2 border-dashed cursor-pointer transition-colors ${u?"border-blue-500 bg-blue-950/20":"border-gray-700 hover:border-gray-500"}`,children:[(0,t.jsx)("input",{ref:p,type:"file",className:"hidden",onChange:e=>{let t=e.target.files?.[0];t&&h(t)}}),a?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("p",{className:"text-sm text-gray-200 font-mono truncate max-w-full px-4",children:a.name}),(0,t.jsx)("p",{className:"text-xs text-gray-500",children:(e=a.size)<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(1)} KB`:`${(e/1048576).toFixed(2)} MB`})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("p",{className:"text-sm text-gray-400",children:"Clique ou dépose un fichier ici"}),(0,t.jsx)("p",{className:"text-xs text-gray-600",children:"200 MB max"})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("p",{className:"text-xs text-gray-500 mb-1.5",children:"Durée de vie"}),(0,t.jsx)("div",{className:"flex gap-1.5 flex-wrap",children:r.map(e=>(0,t.jsx)("button",{onClick:()=>i(e.value),className:`px-3 py-1.5 rounded-lg text-xs transition-colors ${n===e.value?"bg-blue-600 text-white":"bg-gray-700 text-gray-300 hover:bg-gray-600"}`,children:e.label},e.value))})]}),"error"===o.status&&(0,t.jsx)("p",{className:"text-xs text-red-400",children:o.message}),(0,t.jsx)("button",{onClick:function(){if(!a)return;c({status:"uploading",progress:0});let e=new FormData;e.set("file",a),e.set("duration",n);let t=new XMLHttpRequest;t.open("POST","/u/upload"),t.upload.onprogress=e=>{e.lengthComputable&&c({status:"uploading",progress:Math.round(e.loaded/e.total*100)})},t.onload=()=>{if(t.status>=200&&t.status<300){let e=JSON.parse(t.responseText);c({status:"done",url:`${window.location.origin}${e.url}`})}else c({status:"error",message:JSON.parse(t.responseText||"{}").error??"Ãchec de l'upload"})},t.onerror=()=>c({status:"error",message:"Ãchec de l'upload"}),t.send(e)},disabled:!a||m,className:"w-full px-4 py-2.5 bg-blue-600 hover:bg-blue-500 rounded-lg text-sm transition-colors disabled:opacity-40",children:m?`Envoi⦠${o.progress}%`:"Envoyer"})]})]})})}])}]);
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.