import{g as _,o as a,d as i,a as e,t,u as m,r as f,S as p,T as w,c as u,w as h,i as x}from"./F4mCmN5V.js";import{u as b}from"./BJhyvbvB.js";import{b as v}from"./BHNEEQEo.js";import{_ as $}from"./BXGtoald.js";const g={scope:"row",class:"font-normal text-start max-w-0 overflow-hidden text-ellipsis whitespace-nowrap"},y={class:"ps-4 md:ps-content whitespace-nowrap"},O={class:"max-w-24 md:max-w-[30cqw] overflow-hidden ps-4 md:ps-content pe-1 text-ellipsis whitespace-nowrap"},S={class:"ps-4 md:ps-content text-justify [text-align-last:justify] whitespace-nowrap"},j=_({__name:"Observation",props:{city:{},temp:{},weather:{},wind:{}},setup(s){return(l,d)=>(a(),i("tr",null,[e("th",g,[e("bdi",null,t(s.city),1)]),e("td",y,[e("bdi",null,t(s.temp),1)]),e("td",O,[e("bdi",null,t(s.weather),1)]),e("td",S,[e("bdi",null,t(s.wind),1)])]))}}),k=Object.assign(j,{__name:"Observation"}),L={class:"hidden md:table uppercase w-full"},B={scope:"col",class:"font-medium font-stretch-semi-expanded text-[0.75em] ps-content whitespace-nowrap"},D={scope:"col",class:"font-medium font-stretch-semi-expanded text-[0.75em] ps-content whitespace-nowrap text-start"},C={scope:"col",class:"font-medium font-stretch-semi-expanded text-[0.75em] ps-content text-end whitespace-nowrap"},F={class:"md:hidden uppercase flex flex-col gap-2"},N={class:"flex justify-between"},V={class:"truncate pe-1"},q={class:"shrink-0 ps-2"},E={class:"flex justify-between"},P={class:"truncate pe-1"},T={class:"shrink-0 ps-2"},U=_({__name:"Observations",props:{stations:{}},setup(s){const{units:l}=b(),{formatDegrees:d}=v();return(c,r)=>(a(),i(p,null,[e("table",L,[e("thead",null,[e("tr",null,[r[0]||(r[0]=e("th",{scope:"col",class:"text-start max-w-0 w-full"},null,-1)),e("th",B,t(m(l)==="e"?"°F":"°C"),1),e("th",D,t(c.$t("labels.weather")),1),e("th",C,t(c.$t("labels.wind")),1)])]),e("tbody",null,[f(c.$slots,"default")])]),e("div",F,[(a(!0),i(p,null,w(s.stations,n=>(a(),i("div",{key:n.name,class:"flex flex-col"},[e("div",N,[e("span",V,t(n.name),1),e("span",q,t(m(d)(n.temperature)),1)]),e("div",E,[e("span",P,t(n.conditionShort??n.conditionLong),1),e("span",T,t(n.windDirection)+" "+t(n.windSpeed),1)])]))),128))])],64))}}),z=Object.assign(U,{__name:"Observations"}),A=_({__name:"LatestObservations",props:{stations:{}},setup(s){return(l,d)=>{const c=k,r=z,n=$;return a(),u(n,null,{default:h(()=>[x(r,{stations:s.stations},{default:h(()=>[(a(!0),i(p,null,w(s.stations,o=>(a(),u(c,{key:o.name,city:o.name,temp:o.temperature,weather:o.conditionShort??o.conditionLong,wind:`${o.windDirection} ${o.windSpeed}`},null,8,["city","temp","weather","wind"]))),128))]),_:1},8,["stations"])]),_:1})}}}),K=Object.assign(A,{__name:"ScreensLatestObservations"});export{K as _};