PageSourceSearch

https://aorbita.com/assets/NewsletterLatest-CinSK6XA.js

js aorbita.com collected 2026-10-03 18:20:46 UTC 17,856 bytes, 9 lines download raw bytes

1import{a5 as P,a as V,r as d,j as e,ak as I,b as i,ai as y,R as N,M as w,B as M,L as J,p as O,T as H,q as G,P as K,v as W,w as q,K as Z,al as Q,am as X,t as U,F as ee,H as se,an as ae,W as te}from"./index-COPAlxdx.js";import{I as re}from"./info-swTzP3be.js";/**
2 * @license lucide-react v0.294.0 - ISC
3 *
4 * This source code is licensed under the ISC license.
5 * See the LICENSE file in the root directory of this source tree.
6 */const ne=P("BarChart4",[["path",{d:"M3 3v18h18",key:"1s2lah"}],["path",{d:"M13 17V9",key:"1fwyjl"}],["path",{d:"M18 17V5",key:"sfb6ij"}],["path",{d:"M8 17v-3",key:"17ska0"}]]),le=a=>{const x="bg-space-accent";return ee.divIcon({className:"custom-map-marker",html:`<div class="relative w-6 h-6 flex items-center justify-center -ml-1 -mt-1">
7                 <span class="absolute inline-flex h-full w-full rounded-full ${x} opacity-75 animate-ping"></span>
8                 <span class="relative inline-flex rounded-full h-3 w-3 ${x} border border-white shadow-[0_0_10px_rgba(59,130,246,0.5)]"></span>
9               </div>`,iconSize:[20,20],iconAnchor:[10,10],popupAnchor:[0,-10]})},ce=()=>{const a=se();return d.useEffect(()=>{const x=setTimeout(()=>{a.invalidateSize()},100);return()=>clearTimeout(x)},[a]),null},xe=()=>{var j;const{isEnglish:a}=V(),[x,u]=d.useState([]),[r,C]=d.useState(null),[b,_]=d.useState(null),[z,k]=d.useState(!0),[S,$]=d.useState(!1),[g,h]=d.useState(!1),m=(s,t)=>{const n=s.name||s.full_name;return a?n:s.name_es?s.name_es:t==="base"?U(n):t==="cohete"?ae[n]||n:t==="empresa"&&te[n]||n};d.useEffect(()=>{(async()=>{try{const t=await X();u(t.launches||[]),C(t.stats),_(t.cycleDate)}catch(t){console.error("Failed to load newsletter data",t),$(!0)}finally{k(!1)}})()},[]);const L=(b?new Date(b):new Date).toLocaleDateString(a?"en-US":"es-ES",{day:"numeric",month:"long",year:"numeric"}),Y=a?"Launches of the week":"Lanzamientos de la semana",E=a?"No missions planned for the next 7 days in this newsletter.":"No hay misiones planeadas para los próximos 7 dıas en esta newsletter.",T=()=>{const s=`${window.location.protocol}//${window.location.host}${a?"/en/share":"/compartir"}`,t=a?"Next Spacex Launch | aorbita":"Próximo Lanzamiento Espacial | aorbita",n=a?"Check out the next space launch and missions on aorbita.":"Consulta el próximo lanzamiento espacial y las misiones en aorbita.";navigator.share?navigator.share({title:t,text:n,url:s}).catch(l=>{console.log("Error sharing",l)}):(async c=>{try{await navigator.clipboard.writeText(c),h(!0),setTimeout(()=>h(!1),2e3)}catch{const o=document.createElement("textarea");o.value=c,document.body.appendChild(o),o.select(),document.execCommand("copy"),h(!0),setTimeout(()=>h(!1),2e3),document.body.removeChild(o)}})(s)},f=(s,t,n)=>{if(!s||s.length===0)return e.jsx("p",{className:"text-gray-500 text-sm",children:"Sin datos"});const l=Math.max(...s.map(c=>c.total_count||c.count||1),1);return e.jsx("div",{className:"space-y-4",children:s.map((c,p)=>{const o=c.total_count||c.count||0,D=o/l*100,R=t==="cohete"?"rocket":t==="empresa"?"agency":t,v=a?c.slug||c.id:c.slug_es||c.slug||c.id,F=a?`/en/${R}/${v}`:`/${t}/${v}`;return e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsx("div",{className:"w-1/3 md:w-1/4 flex-shrink-0 truncate text-sm",children:e.jsxs(i,{to:F,className:"text-gray-300 hover:text-white flex items-center gap-2 transition-colors",children:[n,e.jsx("span",{className:"truncate",children:m(c,t)})]})}),e.jsx("div",{className:"flex-grow",children:e.jsx("div",{className:"h-4 w-full bg-space-800 rounded-full overflow-hidden",children:e.jsx("div",{className:"h-full bg-space-accent rounded-full transition-all duration-1000",style:{width:`${D}%`}})})}),e.jsx("div",{className:"w-10 text-right text-white font-bold text-sm",children:o})]},p)})})},A=((j=r==null?void 0:r.bases)==null?void 0:j.reduce((s,t)=>{const n=m(t,"base").split(",")[0];return Math.max(s,n.length)},0))||0,B=Math.max(50,Math.min(180,A*4.8));return e.jsx("div",{className:"flex-grow bg-space-950 py-12 min-h-screen",children:e.jsx("div",{className:"max-w-6xl mx-auto px-4 sm:px-6 lg:px-8",children:S?e.jsx("div",{className:"text-center py-20 bg-space-900 border border-space-800 rounded-2xl",children:e.jsx("p",{className:"text-gray-400 text-lg",children:a?"The latest newsletter is not available yet.":"Aún no hay ninguna newsletter disponible."})}):z?e.jsx("div",{className:"flex justify-center py-20",children:e.jsx("div",{className:"animate-spin rounded-full h-12 w-12 border-t-2 border-b-2 border-space-accent"})}):e.jsxs("div",{className:"bg-space-900/50 backdrop-blur-xl border border-space-800 rounded-3xl p-6 md:p-10 shadow-2xl",children:[e.jsxs("div",{className:"text-center mb-12 border-b border-space-800 pb-8",children:[e.jsx("div",{className:"inline-flex items-center justify-center w-16 h-16 rounded-full bg-space-800 border border-space-700 text-space-accent mb-6",children:e.jsx(I,{size:32})}),e.jsx("h1",{className:"text-3xl md:text-5xl font-black text-white tracking-tight mb-2",children:a?"Space Summary":"Resumen Esp
9acial"}),e.jsx("div",{className:"text-lg md:text-xl text-gray-400 font-semibold mb-6 capitalize",children:L}),e.jsxs("div",{className:"flex flex-wrap justify-center gap-3 text-sm font-medium mb-8",children:[e.jsxs(i,{to:a?"/en/launches":"/lanzamientos",className:"inline-flex items-center gap-2 text-space-accent hover:text-white transition-colors bg-space-800/50 px-4 py-2 rounded-full border border-space-700",children:[e.jsx(y,{size:14}),a?"Launches":"Lanzamientos"]}),e.jsxs(i,{to:a?"/en/rockets":"/cohetes",className:"inline-flex items-center gap-2 text-space-accent hover:text-white transition-colors bg-space-800/50 px-4 py-2 rounded-full border border-space-700",children:[e.jsx(N,{size:14}),a?"Rockets":"Cohetes"]}),e.jsxs(i,{to:a?"/en/bases":"/bases",className:"inline-flex items-center gap-2 text-space-accent hover:text-white transition-colors bg-space-800/50 px-4 py-2 rounded-full border border-space-700",children:[e.jsx(w,{size:14}),"Bases"]}),e.jsxs(i,{to:a?"/en/agencies":"/empresas",className:"inline-flex items-center gap-2 text-space-accent hover:text-white transition-colors bg-space-800/50 px-4 py-2 rounded-full border border-space-700",children:[e.jsx(M,{size:14}),a?"Agencies":"Empresas"]})]}),e.jsx("div",{className:"text-gray-400 text-[10px] tracking-wider uppercase opacity-60",children:a?"Explore this week's launches and data up to today":"Explora los lanzamientos de esta semana y los datos hasta hoy"})]}),e.jsxs("div",{className:"mb-16",children:[e.jsxs("h2",{className:"text-2xl font-bold text-white mb-2 flex items-center gap-3",children:[e.jsx(y,{className:"text-space-accent",size:24}),Y]}),e.jsx("p",{className:"text-gray-400 text-sm mb-8 italic",children:a?"This section will be updated live as the missions complete their flight.":"Este apartado se irá actualizando en tiempo real según las misiones completen su vuelo."}),x.length===0?e.jsx("p",{className:"text-gray-400",children:E}):e.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-6",children:x.map(s=>e.jsx(J,{launch:s},s.id))})]}),r&&e.jsxs("div",{className:"mb-16",children:[e.jsxs("h2",{className:"text-2xl font-bold text-white mb-10 flex items-center gap-3",children:[e.jsx(ne,{className:"text-space-accent",size:24}),a?`Launches comparison ${r.lastYear} & ${r.currentYear}`:`Comparación lanzamientos ${r.lastYear} y ${r.currentYear}`]}),e.jsxs("div",{className:"bg-space-800/30 border border-space-800 rounded-2xl p-6 md:p-10 shadow-inner",children:[e.jsxs("div",{className:"relative flex gap-4 h-64 mb-1",children:[e.jsx("div",{className:"flex flex-col-reverse justify-between h-full py-0 text-[10px] text-gray-500 font-mono w-6 pointer-events-none select-none",children:(()=>{const s=Math.max(...r.launchesPerMonth.map(l=>Math.max(l.currentYearCount,l.lastYearCount)),1),t=Math.ceil(s/10)*10,n=[];for(let l=0;l<=t;l+=10)n.push(l);return n.map(l=>e.jsx("span",{className:"text-right h-0 flex items-center justify-end pr-2",children:l},l))})()}),e.jsxs("div",{className:"relative flex-grow h-full border-b border-space-700",children:[e.jsx("div",{className:"absolute inset-0 flex flex-col-reverse justify-between pointer-events-none opacity-10",children:(()=>{const s=Math.max(...r.launchesPerMonth.map(n=>Math.max(n.currentYearCount,n.lastYearCount)),1),t=Math.ceil(s/10)*10;return Array.from({length:t/10+1}).map((n,l)=>e.jsx("div",{className:"w-full border-t border-gray-400 border-dashed",style:{height:"0"}},l))})()}),e.jsx("div",{className:"absolute inset-0 flex items-end justify-between gap-1 sm:gap-2 px-2",children:r.launchesPerMonth.map((s,t)=>{const n=Math.max(...r.launchesPerMonth.map(o=>Math.max(o.currentYearCount,o.lastYearCount)),1),l=Math.ceil(n/10)*10,c=s.lastYearCount/l*100,p=s.currentYearCount/l*100;return e.jsxs("div",{className:"flex-1 flex items-end justify-center gap-0.5 sm:gap-1.5 h-full group relative",children:[e.jsx("div",{className:"w-1.5 sm:w-3 bg-gray-500 rounded-t-sm transition-all duration-1000 origin-bottom",style:{height:`${c}%`},children:e.jsxs("div",{className:"absolute -top-12 left-1/2 -translate-x-1/2 bg-space-900 border border-space-700 px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity whitespace-nowrap z-20 pointer-events-none shadow-xl",children:[e.jsxs("div",{className:"text-[10px] text-gray-400 font-bold",children:[r.lastYear,": ",s.lastYearCount]}),e.jsxs("div",{className:"text-[10px] text-space-accent font-bold",children:[r.currentYear,": ",s.currentYearCount]})]})}
9),e.jsx("div",{className:"w-1.5 sm:w-3 bg-space-accent rounded-t-sm transition-all duration-1000 origin-bottom shadow-[0_0_15px_rgba(0,229,255,0.2)]",style:{height:`${p}%`}})]},t)})})]})]}),e.jsxs("div",{className:"flex gap-4 px-0",children:[e.jsx("div",{className:"w-6"}),e.jsx("div",{className:"flex-grow flex justify-between px-2",children:r.launchesPerMonth.map((s,t)=>{const c=a?["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"][t]:["Ene","Feb","Mar","Abr","May","Jun","Jul","Ago","Sep","Oct","Nov","Dic"][t];return e.jsx("span",{className:"flex-1 text-center text-[10px] sm:text-xs text-gray-500 font-bold uppercase tracking-tighter",children:c},t)})})]}),e.jsxs("div",{className:"flex justify-center gap-10 mt-2 pt-4 border-t border-space-800/50 text-xs font-bold uppercase tracking-widest bg-space-900/40 rounded-b-xl py-3 -mx-10 -mb-10",children:[e.jsxs("div",{className:"flex items-center gap-2 text-gray-400",children:[e.jsx("div",{className:"w-5 h-2 bg-gray-500 rounded-sm"}),e.jsx("span",{children:r.lastYear})]}),e.jsxs("div",{className:"flex items-center gap-2 text-space-accent",children:[e.jsx("div",{className:"w-5 h-2 bg-space-accent rounded-sm shadow-[0_0_10px_rgba(0,229,255,0.3)]"}),e.jsx("span",{children:r.currentYear})]})]})]})]}),e.jsxs("div",{className:"space-y-16",children:[e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-12 pt-8",children:[r&&e.jsxs("div",{children:[e.jsxs("h2",{className:"text-2xl font-bold text-white mb-8 flex items-center gap-3",children:[e.jsx(N,{className:"text-space-accent",size:24}),a?`Rockets launched in ${r.currentYear}`:`Cohetes lanzados en ${r.currentYear}`]}),f(r.rockets,"cohete",null)]}),r&&e.jsxs("div",{children:[e.jsxs("h2",{className:"text-2xl font-bold text-white mb-8 flex items-center gap-3",children:[e.jsx(M,{className:"text-space-accent",size:24}),a?`Agencies ${r.currentYear}`:`Empresas ${r.currentYear}`]}),f(r.agencies,"empresa",null)]})]}),r&&r.bases&&e.jsxs("div",{className:"pt-8 border-t border-space-800",children:[e.jsxs("h2",{className:"text-2xl font-bold text-white mb-8 flex items-center gap-3",children:[e.jsx(w,{className:"text-space-accent",size:24}),a?`Bases utilized in ${r.currentYear}`:`Bases utilizadas en ${r.currentYear}`]}),e.jsx("div",{className:"relative w-full aspect-[21/11] min-h-[300px] bg-space-900 rounded-2xl border border-space-700 overflow-hidden shadow-2xl mb-12",children:e.jsxs(O,{center:[20,0],zoom:1,scrollWheelZoom:!1,attributionControl:!1,dragging:!0,maxBounds:[[-90,-200],[90,200]],style:{width:"100%",height:"100%",backgroundColor:"#151725"},className:"z-0",children:[e.jsx(H,{url:"https://{s}.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}{r}.png"}),r.bases.map(s=>!s.latitude||!s.longitude?null:e.jsx(G,{position:[s.latitude,s.longitude],icon:le(),children:e.jsx(K,{className:"custom-popup",children:e.jsxs("div",{className:"text-gray-900 font-semibold p-1 min-w-[150px]",children:[e.jsx("div",{className:"text-sm border-b border-gray-200 pb-1 mb-1 font-bold",children:m(s,"base").split(",")[0]}),e.jsx("div",{className:"text-xs text-gray-600 mb-1",children:W(s.country_name,a)}),e.jsxs("div",{className:"flex justify-between items-end text-[10px] uppercase font-mono mt-1 leading-none",children:[e.jsxs("span",{className:"text-space-accent-dark font-bold pb-0.5",children:[s.total_count||s.count," ",a?"Launches":"Lanzamientos"]}),e.jsx(i,{to:a?`/en/base/${s.slug||s.id}`:`/base/${s.slug_es||s.slug||s.id}`,className:"p-1 text-gray-400 hover:text-blue-600 transition-colors bg-gray-100 rounded-full hover:bg-gray-200 flex items-center justify-center leading-none",title:a?"More info":"Más información",children:e.jsx(re,{size:14})})]})]})})},s.id)),e.jsx(ce,{}),e.jsx(q,{})]})}),e.jsxs("div",{className:"bg-space-800/30 border border-space-800 rounded-2xl p-6 md:p-10 shadow-inner",children:[e.jsxs("div",{className:"relative flex gap-4 h-64 mb-1",children:[e.jsx("div",{className:"flex flex-col-reverse justify-between h-full py-0 text-[10px] text-gray-500 font-mono w-6 pointer-events-none select-none",children:(()=>{const s=Math.max(...r.bases.map(l=>l.total_count||l.count||1),1),t=Math.ceil(s/10)*10,n=[];for(let l=0;l<=t;l+=10)n.push(l);return n.map(l=>e.jsx("span",{className:"text-right h-0 flex items-center justify-end pr-2",children:l},l))})()}),e.jsxs("div",{className:"relative flex-grow h-full border-b border-space-700",children:[e.jsx("div",{className:"absolute inset-0 flex flex-col-reverse justify-between pointer-events-none opacity-10",children:(()=>{const s=Math.max(...r.bases.map(n=>n.total_count||n.count||1),1),t=Math.ceil(s/10)*10;return Array.from({length:t/10+1}).map((n,l)=>e.jsx("div",{className:"w-full border-t border-gray-400 border-dashed",style:{height:"0"}},l))})()}),e.jsx("div",{className:"absolute inset-0 flex items-end justify-around px-4",children:r.bases.map((s,t)=>{const n=Math.max(...r.bases.map(p=>p.total_count||p.count||1),1),l=Math.ceil(n/10)*10,c=(s.total_count||s.count||0)/l*100;return e.jsx("div",{className:"flex-1 flex items-end justify-center h-full group relative max-w-[24px]",children:e.jsx("div",{className:"w-full bg-space-accent/80 hover:bg-space-accent rounded-t-sm transition-all duration-1000 origin-bottom shadow-[0_0_10px_rgba(0,229,255,0.05)]",style:{height:`${c}%`},children:e.jsx("div",{className:"absolute -top-10 left-1/2 -translate-x-1/2 bg-space-900 border border-space-700 px-2 py-1 rounded opacity-0 group-hover:opacity-100 transition-opacity whitespace-nowrap z-20 pointer-events-none shadow-xl",children:e.jsxs("div",{className:"text-[10px] text-space-accent font-bold",children:[m(s,"base"),": ",s.total_count||s.count]})})})},t)})})]})]}),e.jsxs("div",{className:"flex gap-4 px-0 mt-2 relative",style:{height:`${B}px`},children:[e.jsx("div",{className:"w-6"}),e.jsx("div",{className:"flex-grow flex justify-around px-4",children:r.bases.map((s,t)=>{const n=a?s.slug||s.id:s.slug_es||s.slug||s.id;return e.jsx("div",{className:"flex-1 flex justify-center relative",children:e.jsx(i,{to:a?`/en/base/${n}`:`/base/${n}`,className:"text-[9px] text-gray-300 hover:text-white font-bold uppercase whitespace-nowrap origin-right -rotate-45 block absolute -translate-x-1/2 pr-1 transition-all",title:m(s,"base"),style:{to
9p:"4px"},children:m(s,"base").split(",")[0]})},t)})})]})]})]}),e.jsxs("div",{className:"mt-16 pt-12 border-t border-space-800 flex flex-col items-center gap-6",children:[e.jsxs("div",{className:"text-center space-y-2",children:[e.jsx("h3",{className:"text-xl font-bold text-white",children:a?"Did you find this summary useful?":"¿Te ha resultado útil este resumen?"}),e.jsx("p",{className:"text-gray-400 text-sm",children:a?"Help spread the space excitement by sharing it with your contacts":"Ayuda a difundir la emoción espacial compartiéndolo con tus contactos"})]}),e.jsx("button",{onClick:T,className:`flex items-center gap-3 px-8 py-3 rounded-full text-sm font-bold uppercase tracking-widest transition-all active:scale-95 border ${g?"bg-green-500/10 border-green-500 text-green-500 shadow-green-500/10":"bg-space-800/50 border-space-700 text-space-accent hover:text-white hover:bg-space-700"}`,children:g?e.jsxs(e.Fragment,{children:[e.jsx(Z,{size:18}),a?"Copied!":"¡Copiado!"]}):e.jsxs(e.Fragment,{children:[e.jsx(Q,{size:18}),a?"Share Summary":"Compartir Resumen"]})})]}),e.jsxs("div",{className:"mt-20 pt-12 border-t border-space-800 text-center",children:[e.jsx("p",{className:"text-gray-400 italic mb-8",children:a?"Thanks for reading aorbita! See you at the next launch.":"¡Gracias por leer aorbita! Nos vemos en el próximo lanzamiento."}),e.jsx("div",{className:"flex flex-col items-center",children:e.jsxs(i,{to:a?"/en":"/",className:"text-2xl font-bold tracking-tighter flex items-center text-white hover:opacity-80 transition-opacity",children:["aorbit",e.jsxs("span",{className:"relative",children:["a",e.jsx("span",{className:"absolute -top-1 -right-1.5 w-1 h-1 bg-space-accent rounded-full animate-pulse shadow-[0_0_6px_rgba(37,99,235,0.8)]"})]}),"."]})}),e.jsx("div",{className:"mt-12 pt-8 border-t border-space-900 text-center",children:e.jsxs("p",{className:"text-gray-500 text-[11px] font-medium",children:["© ",new Date().getFullYear()," aorbita. ",a?"All rights reserved.":"Todos los derechos reservados."]})})]})]})]})})})};export{xe 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.