@idmui/basic 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- (function(se,u){typeof exports=="object"&&typeof module<"u"?u(exports,require("moment"),require("vue"),require("@idm-plugin/geo"),require("@idm-plugin/meteo"),require("echarts"),require("mapbox-gl"),require("@idmwx/idmui-gl3")):typeof define=="function"&&define.amd?define(["exports","moment","vue","@idm-plugin/geo","@idm-plugin/meteo","echarts","mapbox-gl","@idmwx/idmui-gl3"],u):(se=typeof globalThis<"u"?globalThis:se||self,u(se["idmui-basic"]={},se.moment,se.Vue,se["@idm-plugin/geo"],se["@idm-plugin/meteo"],se.echarts,se["mapbox-gl"],se["@idmwx/idmui-gl3"]))})(this,function(se,u,e,Z,rt,_a,dt,_t){"use strict";function Sa(o){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const t in o)if(t!=="default"){const c=Object.getOwnPropertyDescriptor(o,t);Object.defineProperty(a,t,c.get?c:{enumerable:!0,get:()=>o[t]})}}return a.default=o,Object.freeze(a)}const j=Sa(_a),tr="",tt=(o,a)=>{const t=o.__vccOpts||o;for(const[c,d]of a)t[c]=d;return t},Ea={name:"IdmBrand",props:{name:{type:String,default:"Weather Forecast Report"},issued:{type:String,default:void 0},locale:{type:String,default:"en"}},methods:{computeUTCTime(o,a){return u.utc(o).format(a)}}},La={class:"idm-brand-section"},Va={class:"title-box"},Ha={class:"issue-box"};function Ta(o,a,t,c,d,i){return e.openBlock(),e.createElementBlock("div",La,[a[0]||(a[0]=e.createElementVNode("div",{class:"logo-box"},[e.createElementVNode("a",{href:"https://nop.ormwx.com/",target:"_blank"},[e.createElementVNode("img",{src:"https://osshz.idmwx.com/asset/logo/logo.svg"})])],-1)),e.createElementVNode("div",Va,e.toDisplayString(t.name),1),e.createElementVNode("div",Ha,[e.createElementVNode("div",null,e.toDisplayString(t.locale==="en"?"Mail to":"联系我们")+": op@ormwx.com",1),e.createElementVNode("div",null,e.toDisplayString(t.locale==="en"?"Issued":"发布时间")+": "+e.toDisplayString(i.computeUTCTime(t.issued,"MMM-DD, YYYY")),1)])])}const Nt=tt(Ea,[["render",Ta]]),Ba={install(o){o.component("IdmBrand",Nt)}},Ca={name:"IdmLoading",props:{loading:{type:Boolean,default:!1},text:{type:String,default:"Loading..."}},emits:["timeout"],watch:{loading:{handler(){this.loading&&setTimeout(()=>{this.$emit("timeout",!1)},5e3)},immediate:!0}}},Ma={key:0,style:{width:"100%",height:"100%",display:"flex","justify-content":"center","align-items":"center"}};function Aa(o,a,t,c,d,i){return t.loading?(e.openBlock(),e.createElementBlock("div",Ma,[...a[0]||(a[0]=[e.createElementVNode("img",{style:{height:"60px"},src:"https://osshz.idmwx.com/asset/loading.gif"},null,-1)])])):e.createCommentVNode("",!0)}const ct=tt(Ca,[["render",Aa]]),Ia={install(o){o.component("IdmLoading",ct)}},ar="",Wa={name:"IdmForecast",components:{IdmLoading:ct},props:{reportData:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},theme:{type:String,default:"light"},locale:{type:String,default:"en"}},data(){return{positionGmt:void 0,meteogramData:void 0,hourlyTableData:[]}},computed:{computeHourLT(){return o=>{if(o){const a=u.tz(o,this.positionGmt);return`${a==null?void 0:a.format("HH")}`}return"-"}},computeUTCTime(){return(o,a="MMM-DD/HHmm[Z], YYYY")=>{if(o){const t=u(o).utc();return`${t==null?void 0:t.format(a)}`}return"-"}},computeMMMDDHHmmLT(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("MMM-DD/HHmm")}`}return"-"}},computeTzTime(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("yyyy-MM-DD")}`}return"-"}},computeLat(){return(o,a=4)=>Z.LngLatHelper.lat2pretty(o,a).pretty},computeLng(){return(o,a=4)=>Z.LngLatHelper.lng2pretty(o,a).pretty},roundPrecision(){return(o,a=4)=>isNaN(o)||o===null||o===void 0||isNaN(a)?"-":Z.LngLatHelper.roundPrecision(o,a)}},watch:{"reportData.version":{handler(){var o,a,t,c;(o=this.reportData)!=null&&o.version&&(this.positionGmt=(c=(t=(a=this.reportData)==null?void 0:a.weather)==null?void 0:t[0])==null?void 0:c.timezone,this.handleRender())},immediate:!0}},methods:{handleRender(){this.$nextTick(()=>{this.disposeEcharts(),this.handleMeteogramData(this.reportData),this.initHourlyTableData(this.reportData)})},handleMeteogramData(o){var h;const a=o.forecastDays||7,t=o.interval||3,c=a>7?6:a>3?3:t,d=o.datetime||((h=this.reportData)==null?void 0:h.etime);this.meteogramData={xDates:[],dates:[],hours:[],temperatures:[],weatherIcons:[],weatherNames:[],visibility:[],windspeed:[],windGusts:[],windDir:[],windDirIcons:[],windSpeedReferMax:[],precip:[],sigWaveHeight:[],swellHeight:[],waveHeightRefer:[],markarea:[],gridOffset:{l:4,r:4},singleAxisOffset:{}};let i={start:void 0,end:void 0};const m=this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)",p="data:image/svg+xml;base64,"+window.btoa(`<svg t="1740383449285" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="10797" width="200" height="200"><path d="M133.8 579l-44.4-44.4c-18.8-18.8-18.8-49.2 0-67.8L478 78c18.8-18.8 49.2-18.8 67.8 0l388.6 388.6c18.8 18.8 18.8 49.2 0 67.8L890 578.8c-19 19-50 18.6-68.6-0.8L592 337.2V912c0 26.6-21.4 48-48 48h-64c-26.6 0-48-21.4-48-48V337.2L202.4 578.2c-18.6 19.6-49.6 20-68.6 0.8z" fill="${m}" p-id="10798"></path></svg>`),y=new Image(64,64);y.src=p,y.onload=async()=>{var k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je;const f=(w=(k=u.tz(d,this.positionGmt))==null?void 0:k.set({hour:0,minute:0,second:0,millisecond:0}))==null?void 0:w.format();for(let ie=0;ie<a*24;ie++)if(ie%t===0){const ze=u(f).clone().add(ie,"h").format();(B=this.meteogramData)==null||B.dates.push(ze);const O=((L=rt.Meteo2Assist.pickHourly(o,ze))==null?void 0:L[0])||{};(C=this.meteogramData)==null||C.temperatures.push(this.roundPrecision((V=O==null?void 0:O.weather)==null?void 0:V.temp,0)),(D=this.meteogramData)==null||D.visibility.push(this.roundPrecision((z=O==null?void 0:O.weather)==null?void 0:z.visibility,1)),(W=this.meteogramData)==null||W.windspeed.push(this.roundPrecision((A=(_=O.weather)==null?void 0:_.wind)==null?void 0:A.kts,1)),(S=this.meteogramData)==null||S.windGusts.push(this.roundPrecision((P=(b=O==null?void 0:O.weather)==null?void 0:b.wind)==null?void 0:P.gusts,1)),(v=this.meteogramData)==null||v.windSpeedReferMax.push(16),(x=this.meteogramData)==null||x.sigWaveHeight.push(this.roundPrecision((E=(R=O==null?void 0:O.wave)==null?void 0:R.sig)==null?void 0:E.height)),(G=this.meteogramData)==null||G.swellHeight.push(this.roundPrecision((l=(H=O==null?void 0:O.wave)==null?void 0:H.swell)==null?void 0:l.height)),(r=this.meteogramData)==null||r.waveHeightRefer.push(1.5);const Ke=t===1?"sum1Hours":"sum3Hours";if(($=this.meteogramData)==null||$.precip.push(this.roundPrecision((F=(U=O==null?void 0:O.weather)==null?void 0:U.precip)==null?void 0:F[Ke],1)),t<24&&ie%12===0&&ie%24!==0||t>=24&&ie%24===0?(J=this.meteogramData)==null||J.xDates.push((X=u.tz(ze,this.positionGmt))==null?void 0:X.format("MMM-DD")):(Q=this.meteogramData)==null||Q.xDates.push(""),ie%c===0?(K=this.meteogramData)==null||K.hours.push(this.computeHourLT(ze)):(ee=this.meteogramData)==null||ee.hours.push(""),ie%12===0?((te=O.weather)!=null&&te.url?(oe=this.meteogramData)==null||oe.weatherIcons.push({symbol:"image://"+((ae=O.weather)==null?void 0:ae.url),symbolSize:30}):this.meteogramData.weatherIcons.push({symbol:"image://",symbolSize:0}),(N=this.meteogramData)==null||N.weatherNames.push((q=O.weather)==null?void 0:q.name)):((I=this.meteogramData)==null||I.weatherIcons.push({symbol:"image://",symbolSize:0}),(me=this.meteogramData)==null||me.weatherNames.push("")),ie%c===0?(re=this.meteogramData)==null||re.windDir.push((pe=(he=O.weather)==null?void 0:he.wind)==null?void 0:pe.bearing):(ne=this.meteogramData)==null||ne.windDir.push(void 0),ie%c===0){const we=document.createElement("canvas"),De=we.getContext("2d");we.width=y.width,we.height=y.height;const le=((xe=(s=O.weather)==null?void 0:s.wind)==null?void 0:xe.bearing)*(Math.PI/180);De.translate(we.width/2,we.height/2),De.rotate(le),De.translate(-y.width/2,-y.height/2),De.drawImage(y,0,0,64,64);const _e=we.toDataURL();this.meteogramData.windDirIcons.push({symbol:"image://"+_e,symbolSize:16})}else this.meteogramData.windDirIcons.push({symbol:"image://",symbolSize:0});(Le=O==null?void 0:O.weather)!=null&&Le.isDay?i.end===void 0&&i.start>=0&&(i.end=ie):i.start===void 0&&(i.start=ie),(i.start>=0&&i.end>=0||i.start>=0&&ie===a*24-1)&&((Ae=this.meteogramData)==null||Ae.markarea.push([{x:((Ve=this.meteogramData)==null?void 0:Ve.gridOffset.l)+i.start/(a*24)*(100-((He=this.meteogramData)==null?void 0:He.gridOffset.l)-((Te=this.meteogramData)==null?void 0:Te.gridOffset.r))+"%"},{x:((Be=this.meteogramData)==null?void 0:Be.gridOffset.l)+(i.end+1)/(a*24)*(100-((Ce=this.meteogramData)==null?void 0:Ce.gridOffset.l)-((Me=this.meteogramData)==null?void 0:Me.gridOffset.r))+"%"}]),i={start:void 0,end:void 0})}this.meteogramData.singleAxisOffset.l=((Ie=this.meteogramData)==null?void 0:Ie.gridOffset.l)+.5/((Pe=(We=this.meteogramData)==null?void 0:We.dates)==null?void 0:Pe.length)*(100-((Oe=this.meteogramData)==null?void 0:Oe.gridOffset.l)-((ve=this.meteogramData)==null?void 0:ve.gridOffset.r))+"%",this.meteogramData.singleAxisOffset.r=((Re=this.meteogramData)==null?void 0:Re.gridOffset.r)+.5/(($e=(Ge=this.meteogramData)==null?void 0:Ge.dates)==null?void 0:$e.length)*(100-((Ye=this.meteogramData)==null?void 0:Ye.gridOffset.l)-((je=this.meteogramData)==null?void 0:je.gridOffset.r))+"%",this.$nextTick(()=>{this.initMeteogramEchart(o)})}},initMeteogramEchart(o){var V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je,ie,ze,O,Ke,we,De,at,le,_e,M,it,Se,et,nt,st,lt,mt,ht,pt,gt;o.forecastDays;const a=o.interval||3;let t,c={grid:{show:!0,bottom:"0%",top:"0%",left:`${this.meteogramData.gridOffset.l}%`,right:`${this.meteogramData.gridOffset.r}%`,borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0, 0, 0, 0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"item",show:!0,position:"right",formatter:g=>{const ke=g==null?void 0:g.dataIndex;return g.seriesName==="Weather Icons"?`<strong>${this.meteogramData.weatherNames[ke]}</strong>`:!1}},legend:{show:!1},xAxis:{left:0,right:0,top:"50%",height:"50%",type:"category",data:(V=this.meteogramData)==null?void 0:V.dates,show:!1},singleAxis:[{left:(z=(C=this.meteogramData)==null?void 0:C.singleAxisOffset)==null?void 0:z.l,right:(_=(D=this.meteogramData)==null?void 0:D.singleAxisOffset)==null?void 0:_.r,type:"category",show:!1,axisLine:{show:!1},axisTick:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},boundaryGap:!1,data:(A=this.meteogramData)==null?void 0:A.dates,top:"50%",height:"2%"}],series:[{name:"Weather Icons",type:"scatter",singleAxisIndex:0,coordinateSystem:"singleAxis",data:(W=this.meteogramData)==null?void 0:W.weatherIcons,symbolSize:24}]};document.getElementById("weatherIconsEchart")&&(t=j.init(document.getElementById("weatherIconsEchart")),t.setOption(c));let d=Math.max(...this.meteogramData.temperatures.filter(g=>typeof g=="number"&&!isNaN(g))),i=Math.min(...this.meteogramData.temperatures.filter(g=>typeof g=="number"&&!isNaN(g))),m=Math.floor(i/5)*5,p=Math.ceil(d/5)*5,y=Math.ceil((p-m)/5);m=Math.floor((m-2*y)/5)*5,p=Math.ceil((p+1)/5)*5,y=Math.ceil((p-m)/5);let h="",f=[];a===1?(h=this.locale==="zhHans"?"1小时降水 ( mm ) ":"Precip.1h ( mm ) ",f=[{gte:8,color:"rgba(248, 1, 1, 1)",label:this.locale==="zhHans"?"暴雨,>7.9mm":"Rainstorm, >7.9mm"},{gte:4,lte:7.9,color:"rgba(190, 226, 2, 18)",label:this.locale==="zhHans"?"大雨,<=7.9mm":"Heavy, <=7.9mm"},{gte:2,lte:3.9,color:"rgba(3, 248, 103, 1)",label:this.locale==="zhHans"?"中雨,<=3.9mm":"Moderate, <=3.9mm"},{lt:2,color:"rgba(172, 210, 255, 1)",label:this.locale==="zhHans"?"小雨,<2mm":"Light, <2mm"}]):(h=this.locale==="zhHans"?"3小时降水 ( mm ) ":"Precip.3h ( mm ) ",f=[{gte:25,color:"rgba(248, 1, 1, 1)",label:this.locale==="zhHans"?"暴雨,>24.9mm":"Rainstorm, >24.9mm"},{gte:10,lte:24.9,color:"rgba(190, 226, 2, 18)",label:this.locale==="zhHans"?"大雨,<=24.9mm":"Heavy, <=24.9mm"},{gte:5,lte:9.9,color:"rgba(3, 248, 103, 1)",label:this.locale==="zhHans"?"中雨,<=9.9mm":"Moderate, <=9.9mm"},{lt:5,color:"rgba(172, 210, 255, 1)",label:this.locale==="zhHans"?"小雨,<5mm":"Light, <5mm"}]);let k;c={title:{text:this.locale==="zhHans"?"天气情况":"Weather Conditions",top:"10px",left:0,textStyle:{fontWeight:"500",fontSize:16,color:this.theme==="dark"?"rgba(255, 255, 255, 1)":"rgba(28,31,35,1)"}},grid:{show:!0,bottom:"20%",top:"70px",left:`${this.meteogramData.gridOffset.l}%`,right:`${this.meteogramData.gridOffset.r}%`,borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0, 0, 0, 0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"axis",show:!0,position:"right",formatter:g=>{var Fe,Ue,qe,Ze,Xe,Je,Y,yt,ft,bt,ut,xt,wt,kt,zt,Dt;const ke=(Fe=g==null?void 0:g.find(de=>de.seriesType==="bar"))==null?void 0:Fe.dataIndex;if(g.find(de=>de.seriesType==="scatter"))return!1;{let de="";const Qe=(Ue=g==null?void 0:g.find(ge=>ge.seriesName==="Precipitation"||ge.seriesName==="降水"))==null?void 0:Ue.value;return a===1?(Qe<2?de="rgba(172, 210, 255, 1)":Qe<=3.9?de="rgba(3, 248, 103, 1)":Qe<=7.9?de="rgba(190, 226, 2, 18)":Qe>7.9?de="rgba(248, 1, 1, 1)":de="rgba(172, 210, 255, 1)",`<div style="font-size: 13px;"><strong>${u.tz((qe=this.meteogramData)==null?void 0:qe.dates[ke],this.positionGmt).format("MMM-DD/HHmm[LT]")}</strong></div>
1
+ (function(se,u){typeof exports=="object"&&typeof module<"u"?u(exports,require("moment"),require("vue"),require("@idm-plugin/geo"),require("@idm-plugin/meteo"),require("echarts"),require("mapbox-gl"),require("@idmwx/idmui-gl3")):typeof define=="function"&&define.amd?define(["exports","moment","vue","@idm-plugin/geo","@idm-plugin/meteo","echarts","mapbox-gl","@idmwx/idmui-gl3"],u):(se=typeof globalThis<"u"?globalThis:se||self,u(se["idmui-basic"]={},se.moment,se.Vue,se["@idm-plugin/geo"],se["@idm-plugin/meteo"],se.echarts,se["mapbox-gl"],se["@idmwx/idmui-gl3"]))})(this,function(se,u,e,Z,rt,_a,dt,_t){"use strict";function Sa(o){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const t in o)if(t!=="default"){const c=Object.getOwnPropertyDescriptor(o,t);Object.defineProperty(a,t,c.get?c:{enumerable:!0,get:()=>o[t]})}}return a.default=o,Object.freeze(a)}const j=Sa(_a),tr="",tt=(o,a)=>{const t=o.__vccOpts||o;for(const[c,d]of a)t[c]=d;return t},Ea={name:"IdmBrand",props:{name:{type:String,default:"Weather Forecast Report"},issued:{type:String,default:void 0},locale:{type:String,default:"en"}},methods:{computeUTCTime(o,a){return u.utc(o).format(a)}}},La={class:"idm-brand-section"},Va={class:"title-box"},Ha={class:"issue-box"};function Ta(o,a,t,c,d,i){return e.openBlock(),e.createElementBlock("div",La,[a[0]||(a[0]=e.createElementVNode("div",{class:"logo-box"},[e.createElementVNode("a",{href:"https://nop.ormwx.com/",target:"_blank"},[e.createElementVNode("img",{src:"https://osshz.idmwx.com/asset/logo/logo.svg"})])],-1)),e.createElementVNode("div",Va,e.toDisplayString(t.name),1),e.createElementVNode("div",Ha,[e.createElementVNode("div",null,e.toDisplayString(t.locale==="en"?"Mail to":"联系我们")+": op@ormwx.com",1),e.createElementVNode("div",null,e.toDisplayString(t.locale==="en"?"Issued":"发布时间")+": "+e.toDisplayString(i.computeUTCTime(t.issued,"MMM-DD, YYYY")),1)])])}const Nt=tt(Ea,[["render",Ta],["__scopeId","data-v-58f06b8b"]]),Ba={install(o){o.component("IdmBrand",Nt)}},Ca={name:"IdmLoading",props:{loading:{type:Boolean,default:!1},text:{type:String,default:"Loading..."}},emits:["timeout"],watch:{loading:{handler(){this.loading&&setTimeout(()=>{this.$emit("timeout",!1)},5e3)},immediate:!0}}},Ma={key:0,style:{width:"100%",height:"100%",display:"flex","justify-content":"center","align-items":"center"}};function Aa(o,a,t,c,d,i){return t.loading?(e.openBlock(),e.createElementBlock("div",Ma,[...a[0]||(a[0]=[e.createElementVNode("img",{style:{height:"60px"},src:"https://osshz.idmwx.com/asset/loading.gif"},null,-1)])])):e.createCommentVNode("",!0)}const ct=tt(Ca,[["render",Aa]]),Ia={install(o){o.component("IdmLoading",ct)}},ar="",Wa={name:"IdmForecast",components:{IdmLoading:ct},props:{reportData:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},theme:{type:String,default:"light"},locale:{type:String,default:"en"}},data(){return{positionGmt:void 0,meteogramData:void 0,hourlyTableData:[]}},computed:{computeHourLT(){return o=>{if(o){const a=u.tz(o,this.positionGmt);return`${a==null?void 0:a.format("HH")}`}return"-"}},computeUTCTime(){return(o,a="MMM-DD/HHmm[Z], YYYY")=>{if(o){const t=u(o).utc();return`${t==null?void 0:t.format(a)}`}return"-"}},computeMMMDDHHmmLT(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("MMM-DD/HHmm")}`}return"-"}},computeTzTime(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("yyyy-MM-DD")}`}return"-"}},computeLat(){return(o,a=4)=>Z.LngLatHelper.lat2pretty(o,a).pretty},computeLng(){return(o,a=4)=>Z.LngLatHelper.lng2pretty(o,a).pretty},roundPrecision(){return(o,a=4)=>isNaN(o)||o===null||o===void 0||isNaN(a)?"-":Z.LngLatHelper.roundPrecision(o,a)}},watch:{"reportData.version":{handler(){var o,a,t,c;(o=this.reportData)!=null&&o.version&&(this.positionGmt=(c=(t=(a=this.reportData)==null?void 0:a.weather)==null?void 0:t[0])==null?void 0:c.timezone,this.handleRender())},immediate:!0}},methods:{handleRender(){this.$nextTick(()=>{this.disposeEcharts(),this.handleMeteogramData(this.reportData),this.initHourlyTableData(this.reportData)})},handleMeteogramData(o){var h;const a=o.forecastDays||7,t=o.interval||3,c=a>7?6:a>3?3:t,d=o.datetime||((h=this.reportData)==null?void 0:h.etime);this.meteogramData={xDates:[],dates:[],hours:[],temperatures:[],weatherIcons:[],weatherNames:[],visibility:[],windspeed:[],windGusts:[],windDir:[],windDirIcons:[],windSpeedReferMax:[],precip:[],sigWaveHeight:[],swellHeight:[],waveHeightRefer:[],markarea:[],gridOffset:{l:4,r:4},singleAxisOffset:{}};let i={start:void 0,end:void 0};const m=this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)",p="data:image/svg+xml;base64,"+window.btoa(`<svg t="1740383449285" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="10797" width="200" height="200"><path d="M133.8 579l-44.4-44.4c-18.8-18.8-18.8-49.2 0-67.8L478 78c18.8-18.8 49.2-18.8 67.8 0l388.6 388.6c18.8 18.8 18.8 49.2 0 67.8L890 578.8c-19 19-50 18.6-68.6-0.8L592 337.2V912c0 26.6-21.4 48-48 48h-64c-26.6 0-48-21.4-48-48V337.2L202.4 578.2c-18.6 19.6-49.6 20-68.6 0.8z" fill="${m}" p-id="10798"></path></svg>`),y=new Image(64,64);y.src=p,y.onload=async()=>{var k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je;const f=(w=(k=u.tz(d,this.positionGmt))==null?void 0:k.set({hour:0,minute:0,second:0,millisecond:0}))==null?void 0:w.format();for(let ie=0;ie<a*24;ie++)if(ie%t===0){const ze=u(f).clone().add(ie,"h").format();(B=this.meteogramData)==null||B.dates.push(ze);const O=((L=rt.Meteo2Assist.pickHourly(o,ze))==null?void 0:L[0])||{};(C=this.meteogramData)==null||C.temperatures.push(this.roundPrecision((V=O==null?void 0:O.weather)==null?void 0:V.temp,0)),(D=this.meteogramData)==null||D.visibility.push(this.roundPrecision((z=O==null?void 0:O.weather)==null?void 0:z.visibility,1)),(W=this.meteogramData)==null||W.windspeed.push(this.roundPrecision((A=(_=O.weather)==null?void 0:_.wind)==null?void 0:A.kts,1)),(S=this.meteogramData)==null||S.windGusts.push(this.roundPrecision((P=(b=O==null?void 0:O.weather)==null?void 0:b.wind)==null?void 0:P.gusts,1)),(v=this.meteogramData)==null||v.windSpeedReferMax.push(16),(x=this.meteogramData)==null||x.sigWaveHeight.push(this.roundPrecision((E=(R=O==null?void 0:O.wave)==null?void 0:R.sig)==null?void 0:E.height)),(G=this.meteogramData)==null||G.swellHeight.push(this.roundPrecision((l=(H=O==null?void 0:O.wave)==null?void 0:H.swell)==null?void 0:l.height)),(r=this.meteogramData)==null||r.waveHeightRefer.push(1.5);const Ke=t===1?"sum1Hours":"sum3Hours";if(($=this.meteogramData)==null||$.precip.push(this.roundPrecision((F=(U=O==null?void 0:O.weather)==null?void 0:U.precip)==null?void 0:F[Ke],1)),t<24&&ie%12===0&&ie%24!==0||t>=24&&ie%24===0?(J=this.meteogramData)==null||J.xDates.push((X=u.tz(ze,this.positionGmt))==null?void 0:X.format("MMM-DD")):(Q=this.meteogramData)==null||Q.xDates.push(""),ie%c===0?(K=this.meteogramData)==null||K.hours.push(this.computeHourLT(ze)):(ee=this.meteogramData)==null||ee.hours.push(""),ie%12===0?((te=O.weather)!=null&&te.url?(oe=this.meteogramData)==null||oe.weatherIcons.push({symbol:"image://"+((ae=O.weather)==null?void 0:ae.url),symbolSize:30}):this.meteogramData.weatherIcons.push({symbol:"image://",symbolSize:0}),(N=this.meteogramData)==null||N.weatherNames.push((q=O.weather)==null?void 0:q.name)):((I=this.meteogramData)==null||I.weatherIcons.push({symbol:"image://",symbolSize:0}),(me=this.meteogramData)==null||me.weatherNames.push("")),ie%c===0?(re=this.meteogramData)==null||re.windDir.push((pe=(he=O.weather)==null?void 0:he.wind)==null?void 0:pe.bearing):(ne=this.meteogramData)==null||ne.windDir.push(void 0),ie%c===0){const we=document.createElement("canvas"),De=we.getContext("2d");we.width=y.width,we.height=y.height;const le=((xe=(s=O.weather)==null?void 0:s.wind)==null?void 0:xe.bearing)*(Math.PI/180);De.translate(we.width/2,we.height/2),De.rotate(le),De.translate(-y.width/2,-y.height/2),De.drawImage(y,0,0,64,64);const _e=we.toDataURL();this.meteogramData.windDirIcons.push({symbol:"image://"+_e,symbolSize:16})}else this.meteogramData.windDirIcons.push({symbol:"image://",symbolSize:0});(Le=O==null?void 0:O.weather)!=null&&Le.isDay?i.end===void 0&&i.start>=0&&(i.end=ie):i.start===void 0&&(i.start=ie),(i.start>=0&&i.end>=0||i.start>=0&&ie===a*24-1)&&((Ae=this.meteogramData)==null||Ae.markarea.push([{x:((Ve=this.meteogramData)==null?void 0:Ve.gridOffset.l)+i.start/(a*24)*(100-((He=this.meteogramData)==null?void 0:He.gridOffset.l)-((Te=this.meteogramData)==null?void 0:Te.gridOffset.r))+"%"},{x:((Be=this.meteogramData)==null?void 0:Be.gridOffset.l)+(i.end+1)/(a*24)*(100-((Ce=this.meteogramData)==null?void 0:Ce.gridOffset.l)-((Me=this.meteogramData)==null?void 0:Me.gridOffset.r))+"%"}]),i={start:void 0,end:void 0})}this.meteogramData.singleAxisOffset.l=((Ie=this.meteogramData)==null?void 0:Ie.gridOffset.l)+.5/((Pe=(We=this.meteogramData)==null?void 0:We.dates)==null?void 0:Pe.length)*(100-((Oe=this.meteogramData)==null?void 0:Oe.gridOffset.l)-((ve=this.meteogramData)==null?void 0:ve.gridOffset.r))+"%",this.meteogramData.singleAxisOffset.r=((Re=this.meteogramData)==null?void 0:Re.gridOffset.r)+.5/(($e=(Ge=this.meteogramData)==null?void 0:Ge.dates)==null?void 0:$e.length)*(100-((Ye=this.meteogramData)==null?void 0:Ye.gridOffset.l)-((je=this.meteogramData)==null?void 0:je.gridOffset.r))+"%",this.$nextTick(()=>{this.initMeteogramEchart(o)})}},initMeteogramEchart(o){var V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je,ie,ze,O,Ke,we,De,at,le,_e,M,it,Se,et,nt,st,lt,mt,ht,pt,gt;o.forecastDays;const a=o.interval||3;let t,c={grid:{show:!0,bottom:"0%",top:"0%",left:`${this.meteogramData.gridOffset.l}%`,right:`${this.meteogramData.gridOffset.r}%`,borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0, 0, 0, 0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"item",show:!0,position:"right",formatter:g=>{const ke=g==null?void 0:g.dataIndex;return g.seriesName==="Weather Icons"?`<strong>${this.meteogramData.weatherNames[ke]}</strong>`:!1}},legend:{show:!1},xAxis:{left:0,right:0,top:"50%",height:"50%",type:"category",data:(V=this.meteogramData)==null?void 0:V.dates,show:!1},singleAxis:[{left:(z=(C=this.meteogramData)==null?void 0:C.singleAxisOffset)==null?void 0:z.l,right:(_=(D=this.meteogramData)==null?void 0:D.singleAxisOffset)==null?void 0:_.r,type:"category",show:!1,axisLine:{show:!1},axisTick:{show:!1},axisLabel:{show:!1},splitLine:{show:!1},boundaryGap:!1,data:(A=this.meteogramData)==null?void 0:A.dates,top:"50%",height:"2%"}],series:[{name:"Weather Icons",type:"scatter",singleAxisIndex:0,coordinateSystem:"singleAxis",data:(W=this.meteogramData)==null?void 0:W.weatherIcons,symbolSize:24}]};document.getElementById("weatherIconsEchart")&&(t=j.init(document.getElementById("weatherIconsEchart")),t.setOption(c));let d=Math.max(...this.meteogramData.temperatures.filter(g=>typeof g=="number"&&!isNaN(g))),i=Math.min(...this.meteogramData.temperatures.filter(g=>typeof g=="number"&&!isNaN(g))),m=Math.floor(i/5)*5,p=Math.ceil(d/5)*5,y=Math.ceil((p-m)/5);m=Math.floor((m-2*y)/5)*5,p=Math.ceil((p+1)/5)*5,y=Math.ceil((p-m)/5);let h="",f=[];a===1?(h=this.locale==="zhHans"?"1小时降水 ( mm ) ":"Precip.1h ( mm ) ",f=[{gte:8,color:"rgba(248, 1, 1, 1)",label:this.locale==="zhHans"?"暴雨,>7.9mm":"Rainstorm, >7.9mm"},{gte:4,lte:7.9,color:"rgba(190, 226, 2, 18)",label:this.locale==="zhHans"?"大雨,<=7.9mm":"Heavy, <=7.9mm"},{gte:2,lte:3.9,color:"rgba(3, 248, 103, 1)",label:this.locale==="zhHans"?"中雨,<=3.9mm":"Moderate, <=3.9mm"},{lt:2,color:"rgba(172, 210, 255, 1)",label:this.locale==="zhHans"?"小雨,<2mm":"Light, <2mm"}]):(h=this.locale==="zhHans"?"3小时降水 ( mm ) ":"Precip.3h ( mm ) ",f=[{gte:25,color:"rgba(248, 1, 1, 1)",label:this.locale==="zhHans"?"暴雨,>24.9mm":"Rainstorm, >24.9mm"},{gte:10,lte:24.9,color:"rgba(190, 226, 2, 18)",label:this.locale==="zhHans"?"大雨,<=24.9mm":"Heavy, <=24.9mm"},{gte:5,lte:9.9,color:"rgba(3, 248, 103, 1)",label:this.locale==="zhHans"?"中雨,<=9.9mm":"Moderate, <=9.9mm"},{lt:5,color:"rgba(172, 210, 255, 1)",label:this.locale==="zhHans"?"小雨,<5mm":"Light, <5mm"}]);let k;c={title:{text:this.locale==="zhHans"?"天气情况":"Weather Conditions",top:"10px",left:0,textStyle:{fontWeight:"500",fontSize:16,color:this.theme==="dark"?"rgba(255, 255, 255, 1)":"rgba(28,31,35,1)"}},grid:{show:!0,bottom:"20%",top:"70px",left:`${this.meteogramData.gridOffset.l}%`,right:`${this.meteogramData.gridOffset.r}%`,borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0, 0, 0, 0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"axis",show:!0,position:"right",formatter:g=>{var Fe,Ue,qe,Ze,Xe,Je,Y,yt,ft,bt,ut,xt,wt,kt,zt,Dt;const ke=(Fe=g==null?void 0:g.find(de=>de.seriesType==="bar"))==null?void 0:Fe.dataIndex;if(g.find(de=>de.seriesType==="scatter"))return!1;{let de="";const Qe=(Ue=g==null?void 0:g.find(ge=>ge.seriesName==="Precipitation"||ge.seriesName==="降水"))==null?void 0:Ue.value;return a===1?(Qe<2?de="rgba(172, 210, 255, 1)":Qe<=3.9?de="rgba(3, 248, 103, 1)":Qe<=7.9?de="rgba(190, 226, 2, 18)":Qe>7.9?de="rgba(248, 1, 1, 1)":de="rgba(172, 210, 255, 1)",`<div style="font-size: 13px;"><strong>${u.tz((qe=this.meteogramData)==null?void 0:qe.dates[ke],this.positionGmt).format("MMM-DD/HHmm[LT]")}</strong></div>
2
2
  <div style="display: ${(Ze=this.meteogramData)!=null&&Ze.weatherNames[ke]?"block":"none"}; font-size: 13px;">
3
3
  <span>${this.locale==="zhHans"?"天气":"Weather"} : </span><strong>${(Xe=this.meteogramData)==null?void 0:Xe.weatherNames[ke]}</strong>
4
4
  </div>
@@ -66,7 +66,7 @@
66
66
  <g transform="rotate(${o}, 512, 512)">
67
67
  <path d="M128 896l384-768 384 768-384-128-384 128z" fill="${a}" p-id="9615"></path>
68
68
  </g>
69
- </svg>`;return btoa(unescape(encodeURIComponent(t)))},async convertSvgUrlToBase64(o){try{const t=await(await fetch(o)).text();return`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(t)))}`}catch(a){return console.warn("SVG conversion error:",a),o}}}},Pa={class:"idm-spot-forecast-report"},Oa={class:"row"},va={class:"col",style:{width:"54%"}},Ra={key:0,style:{"margin-left":"8px"}},Ga={key:1,style:{"margin-left":"8px"}},$a={key:0,class:"col",style:{width:"42%"}},Ya={style:{"margin-left":"8px"}},ja={key:1,class:"col",style:{width:"42%"}},Fa={style:{"margin-left":"8px"}},Ua={class:"row"},qa={class:"col",style:{width:"54%"}},Za={style:{"margin-left":"8px"}},Xa={class:"col",style:{width:"42%"}},Ja={style:{"margin-left":"8px"}},Qa={class:"content-box"},Ka={key:0,class:"meteogram-echart-section"},eo={key:2,id:"weatherIconsEchart"},to={key:3,id:"weatherConditionEchart"},ao={key:4,id:"windIconsEchart"},oo={key:5,id:"windEchart"},io={key:6,class:"page-break"},so={key:7,id:"waveChart"},lo={class:"table-section"},ro={key:0,class:"card"},no={class:"date"},co={class:"",style:{"font-size":"16px","font-weight":"500"}},mo={rowspan:"2",colspan:"1",class:"border",style:{width:"90px"}},ho={rowspan:"1",colspan:"1",class:"border"},po={rowspan:"1",colspan:"1",class:"border"},go={rowspan:"1",colspan:"1",class:"border"},yo={rowspan:"1",colspan:"4",class:"border"},fo={rowspan:"1",colspan:"3",class:"border"},bo={rowspan:"1",colspan:"3",class:"border"},uo={rowspan:"1",colspan:"3",class:"border"},xo={rowspan:"1",colspan:"2",class:"border"},wo={rowspan:"1",colspan:"1",class:"border"},ko={rowspan:"1",colspan:"1",class:"border"},zo={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},Do={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},No={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},_o={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},So={rowspan:"1",colspan:"1",class:"border",style:{width:"30px"}},Eo={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},Lo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Vo={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ho={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},To={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Bo={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Co={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Mo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Ao={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Io={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Wo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Po={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Oo={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},vo={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}},Ro={rowspan:"1",colspan:"1",class:"border",style:{width:"90px"}},Go={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},$o={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},Yo={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},jo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Fo=["src"],Uo={key:1},qo={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Zo={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},Xo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Jo=["src"],Qo={key:1},Ko={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ei={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ti={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},ai=["src"],oi={key:1},ii={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},si={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},li=["src"],ri={key:1},ni={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},di={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},ci=["src"],mi={key:1},hi={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},pi={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},gi={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}};function yi(o,a,t,c,d,i){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H;const m=e.resolveComponent("IdmLoading");return e.openBlock(),e.createElementBlock("div",Pa,[(p=t.reportData)!=null&&p.showSummary?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["summary-info-box",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",Oa,[e.createElementVNode("div",va,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"位置":"Position")+":",3),(y=t.reportData)!=null&&y.portName?(e.openBlock(),e.createElementBlock("span",Ra,e.toDisplayString((h=t.reportData)==null?void 0:h.portName)+" "+e.toDisplayString(`[${i.computeLat(t.reportData.lat)}, ${i.computeLng(t.reportData.lng)}]`),1)):(e.openBlock(),e.createElementBlock("span",Ga,e.toDisplayString(`${i.computeLat(t.reportData.lat)} , ${i.computeLng(t.reportData.lng)}`),1))]),(f=t.reportData)!=null&&f.datetime?(e.openBlock(),e.createElementBlock("div",$a,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报时段":"Forecast Period")+":",3),e.createElementVNode("span",Ya,e.toDisplayString(i.computeTzTime((w=(k=t.reportData)==null?void 0:k.dateRange)==null?void 0:w[0],d.positionGmt))+" ~ "+e.toDisplayString(i.computeTzTime((L=(B=t.reportData)==null?void 0:B.dateRange)==null?void 0:L[1],d.positionGmt)),1)])):(e.openBlock(),e.createElementBlock("div",ja,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报天数":"Forecast Days")+":",3),e.createElementVNode("span",Fa,e.toDisplayString((V=t.reportData)==null?void 0:V.forecastDays)+" "+e.toDisplayString(t.locale==="zhHans"?"天":"Days"),1)]))]),e.createElementVNode("div",Ua,[e.createElementVNode("div",qa,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"时区":"Timezone")+":",3),e.createElementVNode("span",Za,"UTC "+e.toDisplayString((C=t.reportData)==null?void 0:C.positionOffset),1)]),e.createElementVNode("div",Xa,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报模式":"Forecast Model")+":",3),e.createElementVNode("span",Ja,e.toDisplayString((z=t.reportData)==null?void 0:z.forecastModel),1)])])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",Qa,[(D=t.reportData)!=null&&D.showWeatherChart||(_=t.reportData)!=null&&_.showWindChart||(A=t.reportData)!=null&&A.showWaveChart?(e.openBlock(),e.createElementBlock("div",Ka,[t.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):t.reportData?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)),!t.loading&&((W=t.reportData)!=null&&W.showWeatherChart)?(e.openBlock(),e.createElementBlock("div",eo)):e.createCommentVNode("",!0),!t.loading&&((b=t.reportData)!=null&&b.showWeatherChart)?(e.openBlock(),e.createElementBlock("div",to)):e.createCommentVNode("",!0),!t.loading&&((P=t.reportData)!=null&&P.showWindChart)?(e.openBlock(),e.createElementBlock("div",ao)):e.createCommentVNode("",!0),!t.loading&&((S=t.reportData)!=null&&S.showWindChart)?(e.openBlock(),e.createElementBlock("div",oo)):e.createCommentVNode("",!0),(v=t.reportData)!=null&&v.showWeatherChart&&((R=t.reportData)!=null&&R.showWindChart)?(e.openBlock(),e.createElementBlock("div",io)):e.createCommentVNode("",!0),!t.loading&&((E=t.reportData)!=null&&E.showWaveChart)?(e.openBlock(),e.createElementBlock("div",so)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",lo,[t.loading?t.loading?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)):(e.openBlock(),e.createElementBlock("div",ro,[e.createElementVNode("div",no,[e.createElementVNode("div",co,e.toDisplayString(t.locale==="zhHans"?"小时预报":"Hourly Forecast"),1),e.createElementVNode("div",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"]),style:{"font-size":"13px","font-weight":"300"}}," * "+e.toDisplayString(t.locale==="zhHans"?"涌浪、显浪高度>=1.5米时标记为黄色, 风速蒲福等级>=4时标记为黄色。":"Swell or Sig.wave height alert in yellow for value>=1.5m, wind speed alert in yellow for beaufort scale >= 4."),3)]),e.createElementVNode("table",{class:e.normalizeClass(["conditions-table",(x=t.reportData)!=null&&x.showSummary?"":"table-header-fixed"])},[e.createElementVNode("thead",{class:e.normalizeClass(t.theme==="dark"?"dark":"light")},[e.createElementVNode("tr",{class:e.normalizeClass(["day",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("th",mo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"时间":"DateTime"),1),a[0]||(a[0]=e.createElementVNode("br",null,null,-1)),a[1]||(a[1]=e.createTextVNode("(LT)",-1))]),e.createElementVNode("th",ho,e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),e.createElementVNode("th",po,e.toDisplayString(t.locale==="zhHans"?`${t.reportData.interval}小时降水`:`Precip.${t.reportData.interval}h`),1),e.createElementVNode("th",go,e.toDisplayString(t.locale==="zhHans"?"能见度":"Visibility"),1),e.createElementVNode("th",yo,e.toDisplayString(t.locale==="zhHans"?"风":"Wind"),1),e.createElementVNode("th",fo,e.toDisplayString(t.locale==="zhHans"?"风浪":"Wind wave"),1),e.createElementVNode("th",bo,e.toDisplayString(t.locale==="zhHans"?"涌浪":"Swell wave"),1),e.createElementVNode("th",uo,e.toDisplayString(t.locale==="zhHans"?"显浪":"Sig.wave"),1),e.createElementVNode("th",xo,e.toDisplayString(t.locale==="zhHans"?"洋流":"Current"),1),e.createElementVNode("th",wo,e.toDisplayString(t.locale==="zhHans"?"海面":"Sea Level"),1),e.createElementVNode("th",ko,e.toDisplayString(t.locale==="zhHans"?"海表":"Sea Surface"),1)],2),e.createElementVNode("tr",{class:e.normalizeClass(["hour",t.theme==="dark"?"dark":"light"])},[a[28]||(a[28]=e.createElementVNode("th",{rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},"°C",-1)),e.createElementVNode("th",zo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"累计":"Acc"),1),a[2]||(a[2]=e.createElementVNode("br",null,null,-1)),a[3]||(a[3]=e.createTextVNode("(mm)",-1))]),e.createElementVNode("th",Do,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"距离":"Dist"),1),a[4]||(a[4]=e.createElementVNode("br",null,null,-1)),a[5]||(a[5]=e.createTextVNode("(nm)",-1))]),e.createElementVNode("th",No,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",_o,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[6]||(a[6]=e.createElementVNode("br",null,null,-1)),a[7]||(a[7]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",So,e.toDisplayString(t.locale==="zhHans"?"等级":"BF"),1),e.createElementVNode("th",Eo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"阵风":"Gusts"),1),a[8]||(a[8]=e.createElementVNode("br",null,null,-1)),a[9]||(a[9]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",Lo,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Vo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[10]||(a[10]=e.createElementVNode("br",null,null,-1)),a[11]||(a[11]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",Ho,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[12]||(a[12]=e.createElementVNode("br",null,null,-1)),a[13]||(a[13]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",To,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Bo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[14]||(a[14]=e.createElementVNode("br",null,null,-1)),a[15]||(a[15]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",Co,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[16]||(a[16]=e.createElementVNode("br",null,null,-1)),a[17]||(a[17]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",Mo,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Ao,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[18]||(a[18]=e.createElementVNode("br",null,null,-1)),a[19]||(a[19]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",Io,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[20]||(a[20]=e.createElementVNode("br",null,null,-1)),a[21]||(a[21]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",Wo,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Po,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[22]||(a[22]=e.createElementVNode("br",null,null,-1)),a[23]||(a[23]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",Oo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[24]||(a[24]=e.createElementVNode("br",null,null,-1)),a[25]||(a[25]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",vo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),a[26]||(a[26]=e.createElementVNode("br",null,null,-1)),a[27]||(a[27]=e.createTextVNode("(°C)",-1))])],2)],2),e.createElementVNode("tbody",{class:e.normalizeClass((H=t.reportData)!=null&&H.showSummary?"":"scroll")},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.hourlyTableData,l=>(e.openBlock(),e.createElementBlock("tr",{key:Math.random()+l.localDate,class:e.normalizeClass(["text border-bottom",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("td",Ro,[e.createElementVNode("div",null,e.toDisplayString(l.localDate),1)]),e.createElementVNode("td",Go,[e.createElementVNode("div",null,e.toDisplayString(l.temp),1)]),e.createElementVNode("td",$o,e.toDisplayString(l.precipSum),1),e.createElementVNode("td",Yo,e.toDisplayString(l.visibility),1),e.createElementVNode("td",jo,[e.createTextVNode(e.toDisplayString(l.windDir)+" ",1),!isNaN(l.windBearing)&&l.windDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWindArrowBase64(l.windBearing,this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Fo)):(e.openBlock(),e.createElementBlock("span",Uo,"-"))]),e.createElementVNode("td",qo,e.toDisplayString(l.windSpeed),1),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.windBF>=4?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"30px"}},e.toDisplayString(l.windBF),3),e.createElementVNode("td",Zo,e.toDisplayString(l.windGusts),1),e.createElementVNode("td",Xo,[e.createTextVNode(e.toDisplayString(l.windWaveDir)+" ",1),!isNaN(l.windWaveBearing)&&l.windWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.windWaveBearing,(this.theme==="dark","#7cc7b3"))}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Jo)):(e.openBlock(),e.createElementBlock("span",Qo,"-"))]),e.createElementVNode("td",Ko,e.toDisplayString(l.windWaveHeight),1),e.createElementVNode("td",ei,e.toDisplayString(l.windWavePeriod),1),e.createElementVNode("td",ti,[e.createTextVNode(e.toDisplayString(l.swellDir)+" ",1),!isNaN(l.swellBearing)&&l.swellDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.swellBearing,this.theme==="dark"?"rgb(17, 245, 211)":"rgba(0, 230, 194, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,ai)):(e.openBlock(),e.createElementBlock("span",oi,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.swellHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.swellHeight),3),e.createElementVNode("td",ii,e.toDisplayString(l.swellPeriod),1),e.createElementVNode("td",si,[e.createTextVNode(e.toDisplayString(l.sigWaveDir)+" ",1),!isNaN(l.sigWaveBearing)&&l.sigWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.sigWaveBearing,this.theme==="dark"?"rgba(89, 199, 211, 1)":"rgba(1, 189, 211, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,li)):(e.openBlock(),e.createElementBlock("span",ri,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.sigWaveHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.sigWaveHeight),3),e.createElementVNode("td",ni,e.toDisplayString(l.sigWavePeriod),1),e.createElementVNode("td",di,[e.createTextVNode(e.toDisplayString(l.currentDir)+" ",1),!isNaN(l.currentBearing)&&l.currentDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.currentBearing,this.theme==="dark"?"rgba(220, 115, 255, 1)":"rgba(178, 51, 220, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,ci)):(e.openBlock(),e.createElementBlock("span",mi,"-"))]),e.createElementVNode("td",hi,e.toDisplayString(l.currentSpd),1),e.createElementVNode("td",pi,e.toDisplayString(l.seaLevel),1),e.createElementVNode("td",gi,e.toDisplayString(l.seaSurfaceTemp),1)],2))),128))],2)],2)]))])])])}const St=tt(Wa,[["render",yi]]),or="",fi={name:"IdmHistorical",components:{IdmLoading:ct},props:{reportData:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},theme:{type:String,default:"light"},locale:{type:String,default:"en"}},data(){return{positionGmt:void 0,meteogramData:void 0,hourlyTableData:[]}},computed:{computeHourLT(){return o=>{if(o){const a=u.tz(o,this.positionGmt);return`${a==null?void 0:a.format("HH")}`}return"-"}},computeUTCTime(){return(o,a="MMM-DD/HHmm[Z], YYYY")=>{if(o){const t=u(o).utc();return`${t==null?void 0:t.format(a)}`}return"-"}},computeMMMDDHHmmLT(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("MMM-DD/HHmm")}`}return"-"}},computeTzTime(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("yyyy-MM-DD")}`}return"-"}},computeLat(){return(o,a=4)=>Z.LngLatHelper.lat2pretty(o,a).pretty},computeLng(){return(o,a=4)=>Z.LngLatHelper.lng2pretty(o,a).pretty},roundPrecision(){return(o,a=4)=>isNaN(o)||o===null||o===void 0||isNaN(a)?"-":Z.LngLatHelper.roundPrecision(o,a)}},watch:{"reportData.version":{handler(){var o,a,t,c;(o=this.reportData)!=null&&o.version&&(this.positionGmt=(c=(t=(a=this.reportData)==null?void 0:a.weather)==null?void 0:t[0])==null?void 0:c.timezone,this.handleRender())},immediate:!0}},methods:{handleRender(){this.$nextTick(()=>{this.disposeEcharts(),this.handleMeteogramData(this.reportData),this.initHourlyTableData(this.reportData)})},handleMeteogramData(o){var h,f;const a=o.forecastDays||7,t=o.interval||3,c=a>7?6:a>3?3:t,d=((h=this.reportData)==null?void 0:h.datetime)||((f=this.reportData)==null?void 0:f.etime);this.meteogramData={xDates:[],dates:[],hours:[],temperatures:[],weatherIcons:[],weatherNames:[],visibility:[],windspeed:[],windGusts:[],windDir:[],windDirIcons:[],windSpeedReferMax:[],precip:[],sigWaveHeight:[],windWaveHeight:[],swellHeight:[],waveHeightRefer:[],currentSpd:[],sst:[],markarea:[],gridOffset:{l:4,r:4},singleAxisOffset:{}};let i={start:void 0,end:void 0};const m=this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)",p="data:image/svg+xml;base64,"+window.btoa(`<svg t="1740383449285" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="10797" width="200" height="200"><path d="M133.8 579l-44.4-44.4c-18.8-18.8-18.8-49.2 0-67.8L478 78c18.8-18.8 49.2-18.8 67.8 0l388.6 388.6c18.8 18.8 18.8 49.2 0 67.8L890 578.8c-19 19-50 18.6-68.6-0.8L592 337.2V912c0 26.6-21.4 48-48 48h-64c-26.6 0-48-21.4-48-48V337.2L202.4 578.2c-18.6 19.6-49.6 20-68.6 0.8z" fill="${m}" p-id="10798"></path></svg>`),y=new Image(64,64);y.src=p,y.onload=async()=>{var w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je,ie,ze,O,Ke,we,De,at;const k=(B=(w=u.tz(d,this.positionGmt))==null?void 0:w.set({hour:0,minute:0,second:0,millisecond:0}))==null?void 0:B.format();for(let le=0;le<a*24;le++)if(le%t===0){const _e=u(k).clone().add(le,"h").format();(L=this.meteogramData)==null||L.dates.push(_e);const M=((V=rt.Meteo2Assist.pickHourly(o,_e))==null?void 0:V[0])||{};(z=this.meteogramData)==null||z.temperatures.push(this.roundPrecision((C=M==null?void 0:M.weather)==null?void 0:C.temp,0)),(_=this.meteogramData)==null||_.visibility.push(this.roundPrecision((D=M==null?void 0:M.weather)==null?void 0:D.visibility,1)),(b=this.meteogramData)==null||b.windspeed.push(this.roundPrecision((W=(A=M.weather)==null?void 0:A.wind)==null?void 0:W.kts,1)),(v=this.meteogramData)==null||v.windGusts.push(this.roundPrecision((S=(P=M==null?void 0:M.weather)==null?void 0:P.wind)==null?void 0:S.gusts,1)),(R=this.meteogramData)==null||R.windSpeedReferMax.push(16),(H=this.meteogramData)==null||H.sigWaveHeight.push(this.roundPrecision((x=(E=M==null?void 0:M.wave)==null?void 0:E.sig)==null?void 0:x.height)),(r=this.meteogramData)==null||r.windWaveHeight.push(this.roundPrecision((G=(l=M==null?void 0:M.wave)==null?void 0:l.wd)==null?void 0:G.height)),($=this.meteogramData)==null||$.swellHeight.push(this.roundPrecision((F=(U=M==null?void 0:M.wave)==null?void 0:U.swell)==null?void 0:F.height)),(X=this.meteogramData)==null||X.waveHeightRefer.push(1.5);const it=t===1?"sum1Hours":"sum3Hours";if((K=this.meteogramData)==null||K.precip.push(this.roundPrecision((Q=(J=M==null?void 0:M.weather)==null?void 0:J.precip)==null?void 0:Q[it],1)),(te=this.meteogramData)==null||te.currentSpd.push(this.roundPrecision((ee=M==null?void 0:M.current)==null?void 0:ee.kts,1)),(ae=this.meteogramData)==null||ae.sst.push(this.roundPrecision(M==null?void 0:M.sst,0)),t<24&&le%12===0&&le%24!==0||t>=24&&le%24===0?(q=this.meteogramData)==null||q.xDates.push((oe=u.tz(_e,this.positionGmt))==null?void 0:oe.format("MMM-DD")):(N=this.meteogramData)==null||N.xDates.push(""),le%c===0?(I=this.meteogramData)==null||I.hours.push(this.computeHourLT(_e)):(me=this.meteogramData)==null||me.hours.push(""),le%12===0?((he=M.weather)!=null&&he.url?(re=this.meteogramData)==null||re.weatherIcons.push({symbol:"image://"+((pe=M.weather)==null?void 0:pe.url),symbolSize:30}):this.meteogramData.weatherIcons.push({symbol:"image://",symbolSize:0}),(s=this.meteogramData)==null||s.weatherNames.push((ne=M.weather)==null?void 0:ne.name)):((xe=this.meteogramData)==null||xe.weatherIcons.push({symbol:"image://",symbolSize:0}),(Le=this.meteogramData)==null||Le.weatherNames.push("")),le%c===0?(Te=this.meteogramData)==null||Te.windDir.push((He=(Ve=M.weather)==null?void 0:Ve.wind)==null?void 0:He.bearing):(Be=this.meteogramData)==null||Be.windDir.push(void 0),le%c===0){const Se=document.createElement("canvas"),et=Se.getContext("2d");Se.width=y.width,Se.height=y.height;const st=((Me=(Ce=M.weather)==null?void 0:Ce.wind)==null?void 0:Me.bearing)*(Math.PI/180);et.translate(Se.width/2,Se.height/2),et.rotate(st),et.translate(-y.width/2,-y.height/2),et.drawImage(y,0,0,64,64);const lt=Se.toDataURL();this.meteogramData.windDirIcons.push({symbol:"image://"+lt,symbolSize:16})}else this.meteogramData.windDirIcons.push({symbol:"image://",symbolSize:0});(Ae=M==null?void 0:M.weather)!=null&&Ae.isDay?i.end===void 0&&i.start>=0&&(i.end=le):i.start===void 0&&(i.start=le),(i.start>=0&&i.end>=0||i.start>=0&&le===a*24-1)&&((Ge=this.meteogramData)==null||Ge.markarea.push([{x:((Ie=this.meteogramData)==null?void 0:Ie.gridOffset.l)+i.start/(a*24)*(100-((We=this.meteogramData)==null?void 0:We.gridOffset.l)-((Pe=this.meteogramData)==null?void 0:Pe.gridOffset.r))+"%"},{x:((Oe=this.meteogramData)==null?void 0:Oe.gridOffset.l)+(i.end+1)/(a*24)*(100-((ve=this.meteogramData)==null?void 0:ve.gridOffset.l)-((Re=this.meteogramData)==null?void 0:Re.gridOffset.r))+"%"}]),i={start:void 0,end:void 0})}this.meteogramData.singleAxisOffset.l=(($e=this.meteogramData)==null?void 0:$e.gridOffset.l)+.5/((je=(Ye=this.meteogramData)==null?void 0:Ye.dates)==null?void 0:je.length)*(100-((ie=this.meteogramData)==null?void 0:ie.gridOffset.l)-((ze=this.meteogramData)==null?void 0:ze.gridOffset.r))+"%",this.meteogramData.singleAxisOffset.r=((O=this.meteogramData)==null?void 0:O.gridOffset.r)+.5/((we=(Ke=this.meteogramData)==null?void 0:Ke.dates)==null?void 0:we.length)*(100-((De=this.meteogramData)==null?void 0:De.gridOffset.l)-((at=this.meteogramData)==null?void 0:at.gridOffset.r))+"%",this.$nextTick(()=>{this.initMeteogramEchart(o)})}},initMeteogramEchart(o){var C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je,ie,ze,O,Ke,we,De,at,le,_e,M,it,Se,et,nt,st,lt,mt,ht,pt,gt,g,ke,Fe,Ue,qe,Ze,Xe,Je,Y,yt,ft,bt,ut,xt,wt,kt,zt,Dt,de,Qe,ge,Ht,Tt,Bt,Ct,Mt,At,It,Wt,Pt,Ot,vt,Rt,Gt,$t,Yt,jt,Ft,Ut,qt,Zt,Xt,Jt,Qt,Kt,ea,ta,aa,oa,ia,sa,la,ra,na,da,ca,ma,ha,pa,ga,ya,fa,ba,ua,xa,wa,ka,za,Da;const a=o.interval||3;let t=Math.max(...this.meteogramData.temperatures.filter(n=>typeof n=="number"&&!isNaN(n))),c=Math.min(...this.meteogramData.temperatures.filter(n=>typeof n=="number"&&!isNaN(n))),d=Math.floor(c/5)*5,i=Math.ceil(t/5)*5,m=Math.ceil((i-d)/5);d=Math.floor((d-2*m)/5)*5,i=Math.ceil((i+1)/5)*5,m=Math.ceil((i-d)/5);let p="";a===1?(p=this.locale==="zhHans"?"1小时降水 ( mm ) ":"Precip.1h ( mm ) ",this.locale,this.locale,this.locale,this.locale):(p=this.locale==="zhHans"?"3小时降水 ( mm ) ":"Precip.3h ( mm ) ",this.locale,this.locale,this.locale,this.locale);let y,h={title:{text:this.locale==="zhHans"?"温度":"Temperature",top:"10px",left:0,textStyle:{fontWeight:"500",fontSize:16,color:this.theme==="dark"?"rgba(255, 255, 255, 1)":"rgba(28,31,35,1)"}},grid:{show:!0,bottom:"20%",top:"40px",left:`${this.meteogramData.gridOffset.l}%`,right:`${this.meteogramData.gridOffset.r}%`,borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0, 0, 0, 0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"axis",show:!0,position:"right",formatter:n=>{var ye,fe,be,ue;const Ee=(ye=n==null?void 0:n.find(T=>T.seriesType==="line"))==null?void 0:ye.dataIndex;return n.find(T=>T.seriesType==="scatter")?!1:`<div style="font-size: 13px;"><strong>${u.tz((fe=this.meteogramData)==null?void 0:fe.dates[Ee],this.positionGmt).format("MMM-DD/HHmm[LT]")}</strong></div>
69
+ </svg>`;return btoa(unescape(encodeURIComponent(t)))},async convertSvgUrlToBase64(o){try{const t=await(await fetch(o)).text();return`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(t)))}`}catch(a){return console.warn("SVG conversion error:",a),o}}}},Pa={class:"idm-spot-forecast-report"},Oa={class:"row"},va={class:"col",style:{width:"54%"}},Ra={key:0,style:{"margin-left":"8px"}},Ga={key:1,style:{"margin-left":"8px"}},$a={key:0,class:"col",style:{width:"42%"}},Ya={style:{"margin-left":"8px"}},ja={key:1,class:"col",style:{width:"42%"}},Fa={style:{"margin-left":"8px"}},Ua={class:"row"},qa={class:"col",style:{width:"54%"}},Za={style:{"margin-left":"8px"}},Xa={class:"col",style:{width:"42%"}},Ja={style:{"margin-left":"8px"}},Qa={class:"content-box"},Ka={key:0,class:"meteogram-echart-section"},eo={key:2,id:"weatherIconsEchart"},to={key:3,id:"weatherConditionEchart"},ao={key:4,id:"windIconsEchart"},oo={key:5,id:"windEchart"},io={key:6,class:"page-break"},so={key:7,id:"waveChart"},lo={class:"table-section"},ro={key:0,class:"card"},no={class:"date"},co={class:"",style:{"font-size":"16px","font-weight":"500"}},mo={rowspan:"2",colspan:"1",class:"border",style:{width:"90px"}},ho={rowspan:"1",colspan:"1",class:"border"},po={rowspan:"1",colspan:"1",class:"border"},go={rowspan:"1",colspan:"1",class:"border"},yo={rowspan:"1",colspan:"4",class:"border"},fo={rowspan:"1",colspan:"3",class:"border"},bo={rowspan:"1",colspan:"3",class:"border"},uo={rowspan:"1",colspan:"3",class:"border"},xo={rowspan:"1",colspan:"2",class:"border"},wo={rowspan:"1",colspan:"1",class:"border"},ko={rowspan:"1",colspan:"1",class:"border"},zo={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},Do={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},No={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},_o={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},So={rowspan:"1",colspan:"1",class:"border",style:{width:"30px"}},Eo={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},Lo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Vo={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ho={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},To={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Bo={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Co={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Mo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Ao={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Io={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Wo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},Po={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Oo={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},vo={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}},Ro={rowspan:"1",colspan:"1",class:"border",style:{width:"90px"}},Go={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},$o={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},Yo={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},jo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Fo=["src"],Uo={key:1},qo={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Zo={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},Xo={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Jo=["src"],Qo={key:1},Ko={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ei={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ti={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},ai=["src"],oi={key:1},ii={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},si={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},li=["src"],ri={key:1},ni={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},di={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},ci=["src"],mi={key:1},hi={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},pi={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},gi={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}};function yi(o,a,t,c,d,i){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H;const m=e.resolveComponent("IdmLoading");return e.openBlock(),e.createElementBlock("div",Pa,[(p=t.reportData)!=null&&p.showSummary?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["summary-info-box",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",Oa,[e.createElementVNode("div",va,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"位置":"Position")+":",3),(y=t.reportData)!=null&&y.portName?(e.openBlock(),e.createElementBlock("span",Ra,e.toDisplayString((h=t.reportData)==null?void 0:h.portName)+" "+e.toDisplayString(`[${i.computeLat(t.reportData.lat)}, ${i.computeLng(t.reportData.lng)}]`),1)):(e.openBlock(),e.createElementBlock("span",Ga,e.toDisplayString(`${i.computeLat(t.reportData.lat)} , ${i.computeLng(t.reportData.lng)}`),1))]),(f=t.reportData)!=null&&f.datetime?(e.openBlock(),e.createElementBlock("div",$a,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报时段":"Forecast Period")+":",3),e.createElementVNode("span",Ya,e.toDisplayString(i.computeTzTime((w=(k=t.reportData)==null?void 0:k.dateRange)==null?void 0:w[0],d.positionGmt))+" ~ "+e.toDisplayString(i.computeTzTime((L=(B=t.reportData)==null?void 0:B.dateRange)==null?void 0:L[1],d.positionGmt)),1)])):(e.openBlock(),e.createElementBlock("div",ja,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报天数":"Forecast Days")+":",3),e.createElementVNode("span",Fa,e.toDisplayString((V=t.reportData)==null?void 0:V.forecastDays)+" "+e.toDisplayString(t.locale==="zhHans"?"天":"Days"),1)]))]),e.createElementVNode("div",Ua,[e.createElementVNode("div",qa,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"时区":"Timezone")+":",3),e.createElementVNode("span",Za,"UTC "+e.toDisplayString((C=t.reportData)==null?void 0:C.positionOffset),1)]),e.createElementVNode("div",Xa,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报模式":"Forecast Model")+":",3),e.createElementVNode("span",Ja,e.toDisplayString((z=t.reportData)==null?void 0:z.forecastModel),1)])])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",Qa,[(D=t.reportData)!=null&&D.showWeatherChart||(_=t.reportData)!=null&&_.showWindChart||(A=t.reportData)!=null&&A.showWaveChart?(e.openBlock(),e.createElementBlock("div",Ka,[t.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):t.reportData?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)),!t.loading&&((W=t.reportData)!=null&&W.showWeatherChart)?(e.openBlock(),e.createElementBlock("div",eo)):e.createCommentVNode("",!0),!t.loading&&((b=t.reportData)!=null&&b.showWeatherChart)?(e.openBlock(),e.createElementBlock("div",to)):e.createCommentVNode("",!0),!t.loading&&((P=t.reportData)!=null&&P.showWindChart)?(e.openBlock(),e.createElementBlock("div",ao)):e.createCommentVNode("",!0),!t.loading&&((S=t.reportData)!=null&&S.showWindChart)?(e.openBlock(),e.createElementBlock("div",oo)):e.createCommentVNode("",!0),(v=t.reportData)!=null&&v.showWeatherChart&&((R=t.reportData)!=null&&R.showWindChart)?(e.openBlock(),e.createElementBlock("div",io)):e.createCommentVNode("",!0),!t.loading&&((E=t.reportData)!=null&&E.showWaveChart)?(e.openBlock(),e.createElementBlock("div",so)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",lo,[t.loading?t.loading?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)):(e.openBlock(),e.createElementBlock("div",ro,[e.createElementVNode("div",no,[e.createElementVNode("div",co,e.toDisplayString(t.locale==="zhHans"?"小时预报":"Hourly Forecast"),1),e.createElementVNode("div",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"]),style:{"font-size":"13px","font-weight":"300"}}," * "+e.toDisplayString(t.locale==="zhHans"?"涌浪、显浪高度>=1.5米时标记为黄色, 风速蒲福等级>=4时标记为黄色。":"Swell or Sig.wave height alert in yellow for value>=1.5m, wind speed alert in yellow for beaufort scale >= 4."),3)]),e.createElementVNode("table",{class:e.normalizeClass(["conditions-table",(x=t.reportData)!=null&&x.showSummary?"":"table-header-fixed"])},[e.createElementVNode("thead",{class:e.normalizeClass(t.theme==="dark"?"dark":"light")},[e.createElementVNode("tr",{class:e.normalizeClass(["day",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("th",mo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"时间":"DateTime"),1),a[0]||(a[0]=e.createElementVNode("br",null,null,-1)),a[1]||(a[1]=e.createTextVNode("(LT)",-1))]),e.createElementVNode("th",ho,e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),e.createElementVNode("th",po,e.toDisplayString(t.locale==="zhHans"?`${t.reportData.interval}小时降水`:`Precip.${t.reportData.interval}h`),1),e.createElementVNode("th",go,e.toDisplayString(t.locale==="zhHans"?"能见度":"Visibility"),1),e.createElementVNode("th",yo,e.toDisplayString(t.locale==="zhHans"?"风":"Wind"),1),e.createElementVNode("th",fo,e.toDisplayString(t.locale==="zhHans"?"风浪":"Wind wave"),1),e.createElementVNode("th",bo,e.toDisplayString(t.locale==="zhHans"?"涌浪":"Swell wave"),1),e.createElementVNode("th",uo,e.toDisplayString(t.locale==="zhHans"?"显浪":"Sig.wave"),1),e.createElementVNode("th",xo,e.toDisplayString(t.locale==="zhHans"?"洋流":"Current"),1),e.createElementVNode("th",wo,e.toDisplayString(t.locale==="zhHans"?"海面":"Sea Level"),1),e.createElementVNode("th",ko,e.toDisplayString(t.locale==="zhHans"?"海表":"Sea Surface"),1)],2),e.createElementVNode("tr",{class:e.normalizeClass(["hour",t.theme==="dark"?"dark":"light"])},[a[28]||(a[28]=e.createElementVNode("th",{rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},"°C",-1)),e.createElementVNode("th",zo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"累计":"Acc"),1),a[2]||(a[2]=e.createElementVNode("br",null,null,-1)),a[3]||(a[3]=e.createTextVNode("(mm)",-1))]),e.createElementVNode("th",Do,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"距离":"Dist"),1),a[4]||(a[4]=e.createElementVNode("br",null,null,-1)),a[5]||(a[5]=e.createTextVNode("(nm)",-1))]),e.createElementVNode("th",No,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",_o,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[6]||(a[6]=e.createElementVNode("br",null,null,-1)),a[7]||(a[7]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",So,e.toDisplayString(t.locale==="zhHans"?"等级":"BF"),1),e.createElementVNode("th",Eo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"阵风":"Gusts"),1),a[8]||(a[8]=e.createElementVNode("br",null,null,-1)),a[9]||(a[9]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",Lo,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Vo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[10]||(a[10]=e.createElementVNode("br",null,null,-1)),a[11]||(a[11]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",Ho,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[12]||(a[12]=e.createElementVNode("br",null,null,-1)),a[13]||(a[13]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",To,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Bo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[14]||(a[14]=e.createElementVNode("br",null,null,-1)),a[15]||(a[15]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",Co,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[16]||(a[16]=e.createElementVNode("br",null,null,-1)),a[17]||(a[17]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",Mo,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Ao,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[18]||(a[18]=e.createElementVNode("br",null,null,-1)),a[19]||(a[19]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",Io,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[20]||(a[20]=e.createElementVNode("br",null,null,-1)),a[21]||(a[21]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",Wo,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",Po,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[22]||(a[22]=e.createElementVNode("br",null,null,-1)),a[23]||(a[23]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",Oo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[24]||(a[24]=e.createElementVNode("br",null,null,-1)),a[25]||(a[25]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",vo,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),a[26]||(a[26]=e.createElementVNode("br",null,null,-1)),a[27]||(a[27]=e.createTextVNode("(°C)",-1))])],2)],2),e.createElementVNode("tbody",{class:e.normalizeClass((H=t.reportData)!=null&&H.showSummary?"":"scroll")},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.hourlyTableData,l=>(e.openBlock(),e.createElementBlock("tr",{key:Math.random()+l.localDate,class:e.normalizeClass(["text border-bottom",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("td",Ro,[e.createElementVNode("div",null,e.toDisplayString(l.localDate),1)]),e.createElementVNode("td",Go,[e.createElementVNode("div",null,e.toDisplayString(l.temp),1)]),e.createElementVNode("td",$o,e.toDisplayString(l.precipSum),1),e.createElementVNode("td",Yo,e.toDisplayString(l.visibility),1),e.createElementVNode("td",jo,[e.createTextVNode(e.toDisplayString(l.windDir)+" ",1),!isNaN(l.windBearing)&&l.windDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWindArrowBase64(l.windBearing,this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Fo)):(e.openBlock(),e.createElementBlock("span",Uo,"-"))]),e.createElementVNode("td",qo,e.toDisplayString(l.windSpeed),1),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.windBF>=4?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"30px"}},e.toDisplayString(l.windBF),3),e.createElementVNode("td",Zo,e.toDisplayString(l.windGusts),1),e.createElementVNode("td",Xo,[e.createTextVNode(e.toDisplayString(l.windWaveDir)+" ",1),!isNaN(l.windWaveBearing)&&l.windWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.windWaveBearing,(this.theme==="dark","#7cc7b3"))}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Jo)):(e.openBlock(),e.createElementBlock("span",Qo,"-"))]),e.createElementVNode("td",Ko,e.toDisplayString(l.windWaveHeight),1),e.createElementVNode("td",ei,e.toDisplayString(l.windWavePeriod),1),e.createElementVNode("td",ti,[e.createTextVNode(e.toDisplayString(l.swellDir)+" ",1),!isNaN(l.swellBearing)&&l.swellDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.swellBearing,this.theme==="dark"?"rgb(17, 245, 211)":"rgba(0, 230, 194, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,ai)):(e.openBlock(),e.createElementBlock("span",oi,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.swellHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.swellHeight),3),e.createElementVNode("td",ii,e.toDisplayString(l.swellPeriod),1),e.createElementVNode("td",si,[e.createTextVNode(e.toDisplayString(l.sigWaveDir)+" ",1),!isNaN(l.sigWaveBearing)&&l.sigWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.sigWaveBearing,this.theme==="dark"?"rgba(89, 199, 211, 1)":"rgba(1, 189, 211, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,li)):(e.openBlock(),e.createElementBlock("span",ri,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.sigWaveHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.sigWaveHeight),3),e.createElementVNode("td",ni,e.toDisplayString(l.sigWavePeriod),1),e.createElementVNode("td",di,[e.createTextVNode(e.toDisplayString(l.currentDir)+" ",1),!isNaN(l.currentBearing)&&l.currentDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.currentBearing,this.theme==="dark"?"rgba(220, 115, 255, 1)":"rgba(178, 51, 220, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,ci)):(e.openBlock(),e.createElementBlock("span",mi,"-"))]),e.createElementVNode("td",hi,e.toDisplayString(l.currentSpd),1),e.createElementVNode("td",pi,e.toDisplayString(l.seaLevel),1),e.createElementVNode("td",gi,e.toDisplayString(l.seaSurfaceTemp),1)],2))),128))],2)],2)]))])])])}const St=tt(Wa,[["render",yi],["__scopeId","data-v-74d509e8"]]),or="",fi={name:"IdmHistorical",components:{IdmLoading:ct},props:{reportData:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},theme:{type:String,default:"light"},locale:{type:String,default:"en"}},data(){return{positionGmt:void 0,meteogramData:void 0,hourlyTableData:[]}},computed:{computeHourLT(){return o=>{if(o){const a=u.tz(o,this.positionGmt);return`${a==null?void 0:a.format("HH")}`}return"-"}},computeUTCTime(){return(o,a="MMM-DD/HHmm[Z], YYYY")=>{if(o){const t=u(o).utc();return`${t==null?void 0:t.format(a)}`}return"-"}},computeMMMDDHHmmLT(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("MMM-DD/HHmm")}`}return"-"}},computeTzTime(){return(o,a)=>{if(o){const t=u.tz(o,a);return`${t==null?void 0:t.format("yyyy-MM-DD")}`}return"-"}},computeLat(){return(o,a=4)=>Z.LngLatHelper.lat2pretty(o,a).pretty},computeLng(){return(o,a=4)=>Z.LngLatHelper.lng2pretty(o,a).pretty},roundPrecision(){return(o,a=4)=>isNaN(o)||o===null||o===void 0||isNaN(a)?"-":Z.LngLatHelper.roundPrecision(o,a)}},watch:{"reportData.version":{handler(){var o,a,t,c;(o=this.reportData)!=null&&o.version&&(this.positionGmt=(c=(t=(a=this.reportData)==null?void 0:a.weather)==null?void 0:t[0])==null?void 0:c.timezone,this.handleRender())},immediate:!0}},methods:{handleRender(){this.$nextTick(()=>{this.disposeEcharts(),this.handleMeteogramData(this.reportData),this.initHourlyTableData(this.reportData)})},handleMeteogramData(o){var h,f;const a=o.forecastDays||7,t=o.interval||3,c=a>7?6:a>3?3:t,d=((h=this.reportData)==null?void 0:h.datetime)||((f=this.reportData)==null?void 0:f.etime);this.meteogramData={xDates:[],dates:[],hours:[],temperatures:[],weatherIcons:[],weatherNames:[],visibility:[],windspeed:[],windGusts:[],windDir:[],windDirIcons:[],windSpeedReferMax:[],precip:[],sigWaveHeight:[],windWaveHeight:[],swellHeight:[],waveHeightRefer:[],currentSpd:[],sst:[],markarea:[],gridOffset:{l:4,r:4},singleAxisOffset:{}};let i={start:void 0,end:void 0};const m=this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)",p="data:image/svg+xml;base64,"+window.btoa(`<svg t="1740383449285" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="10797" width="200" height="200"><path d="M133.8 579l-44.4-44.4c-18.8-18.8-18.8-49.2 0-67.8L478 78c18.8-18.8 49.2-18.8 67.8 0l388.6 388.6c18.8 18.8 18.8 49.2 0 67.8L890 578.8c-19 19-50 18.6-68.6-0.8L592 337.2V912c0 26.6-21.4 48-48 48h-64c-26.6 0-48-21.4-48-48V337.2L202.4 578.2c-18.6 19.6-49.6 20-68.6 0.8z" fill="${m}" p-id="10798"></path></svg>`),y=new Image(64,64);y.src=p,y.onload=async()=>{var w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je,ie,ze,O,Ke,we,De,at;const k=(B=(w=u.tz(d,this.positionGmt))==null?void 0:w.set({hour:0,minute:0,second:0,millisecond:0}))==null?void 0:B.format();for(let le=0;le<a*24;le++)if(le%t===0){const _e=u(k).clone().add(le,"h").format();(L=this.meteogramData)==null||L.dates.push(_e);const M=((V=rt.Meteo2Assist.pickHourly(o,_e))==null?void 0:V[0])||{};(z=this.meteogramData)==null||z.temperatures.push(this.roundPrecision((C=M==null?void 0:M.weather)==null?void 0:C.temp,0)),(_=this.meteogramData)==null||_.visibility.push(this.roundPrecision((D=M==null?void 0:M.weather)==null?void 0:D.visibility,1)),(b=this.meteogramData)==null||b.windspeed.push(this.roundPrecision((W=(A=M.weather)==null?void 0:A.wind)==null?void 0:W.kts,1)),(v=this.meteogramData)==null||v.windGusts.push(this.roundPrecision((S=(P=M==null?void 0:M.weather)==null?void 0:P.wind)==null?void 0:S.gusts,1)),(R=this.meteogramData)==null||R.windSpeedReferMax.push(16),(H=this.meteogramData)==null||H.sigWaveHeight.push(this.roundPrecision((x=(E=M==null?void 0:M.wave)==null?void 0:E.sig)==null?void 0:x.height)),(r=this.meteogramData)==null||r.windWaveHeight.push(this.roundPrecision((G=(l=M==null?void 0:M.wave)==null?void 0:l.wd)==null?void 0:G.height)),($=this.meteogramData)==null||$.swellHeight.push(this.roundPrecision((F=(U=M==null?void 0:M.wave)==null?void 0:U.swell)==null?void 0:F.height)),(X=this.meteogramData)==null||X.waveHeightRefer.push(1.5);const it=t===1?"sum1Hours":"sum3Hours";if((K=this.meteogramData)==null||K.precip.push(this.roundPrecision((Q=(J=M==null?void 0:M.weather)==null?void 0:J.precip)==null?void 0:Q[it],1)),(te=this.meteogramData)==null||te.currentSpd.push(this.roundPrecision((ee=M==null?void 0:M.current)==null?void 0:ee.kts,1)),(ae=this.meteogramData)==null||ae.sst.push(this.roundPrecision(M==null?void 0:M.sst,0)),t<24&&le%12===0&&le%24!==0||t>=24&&le%24===0?(q=this.meteogramData)==null||q.xDates.push((oe=u.tz(_e,this.positionGmt))==null?void 0:oe.format("MMM-DD")):(N=this.meteogramData)==null||N.xDates.push(""),le%c===0?(I=this.meteogramData)==null||I.hours.push(this.computeHourLT(_e)):(me=this.meteogramData)==null||me.hours.push(""),le%12===0?((he=M.weather)!=null&&he.url?(re=this.meteogramData)==null||re.weatherIcons.push({symbol:"image://"+((pe=M.weather)==null?void 0:pe.url),symbolSize:30}):this.meteogramData.weatherIcons.push({symbol:"image://",symbolSize:0}),(s=this.meteogramData)==null||s.weatherNames.push((ne=M.weather)==null?void 0:ne.name)):((xe=this.meteogramData)==null||xe.weatherIcons.push({symbol:"image://",symbolSize:0}),(Le=this.meteogramData)==null||Le.weatherNames.push("")),le%c===0?(Te=this.meteogramData)==null||Te.windDir.push((He=(Ve=M.weather)==null?void 0:Ve.wind)==null?void 0:He.bearing):(Be=this.meteogramData)==null||Be.windDir.push(void 0),le%c===0){const Se=document.createElement("canvas"),et=Se.getContext("2d");Se.width=y.width,Se.height=y.height;const st=((Me=(Ce=M.weather)==null?void 0:Ce.wind)==null?void 0:Me.bearing)*(Math.PI/180);et.translate(Se.width/2,Se.height/2),et.rotate(st),et.translate(-y.width/2,-y.height/2),et.drawImage(y,0,0,64,64);const lt=Se.toDataURL();this.meteogramData.windDirIcons.push({symbol:"image://"+lt,symbolSize:16})}else this.meteogramData.windDirIcons.push({symbol:"image://",symbolSize:0});(Ae=M==null?void 0:M.weather)!=null&&Ae.isDay?i.end===void 0&&i.start>=0&&(i.end=le):i.start===void 0&&(i.start=le),(i.start>=0&&i.end>=0||i.start>=0&&le===a*24-1)&&((Ge=this.meteogramData)==null||Ge.markarea.push([{x:((Ie=this.meteogramData)==null?void 0:Ie.gridOffset.l)+i.start/(a*24)*(100-((We=this.meteogramData)==null?void 0:We.gridOffset.l)-((Pe=this.meteogramData)==null?void 0:Pe.gridOffset.r))+"%"},{x:((Oe=this.meteogramData)==null?void 0:Oe.gridOffset.l)+(i.end+1)/(a*24)*(100-((ve=this.meteogramData)==null?void 0:ve.gridOffset.l)-((Re=this.meteogramData)==null?void 0:Re.gridOffset.r))+"%"}]),i={start:void 0,end:void 0})}this.meteogramData.singleAxisOffset.l=(($e=this.meteogramData)==null?void 0:$e.gridOffset.l)+.5/((je=(Ye=this.meteogramData)==null?void 0:Ye.dates)==null?void 0:je.length)*(100-((ie=this.meteogramData)==null?void 0:ie.gridOffset.l)-((ze=this.meteogramData)==null?void 0:ze.gridOffset.r))+"%",this.meteogramData.singleAxisOffset.r=((O=this.meteogramData)==null?void 0:O.gridOffset.r)+.5/((we=(Ke=this.meteogramData)==null?void 0:Ke.dates)==null?void 0:we.length)*(100-((De=this.meteogramData)==null?void 0:De.gridOffset.l)-((at=this.meteogramData)==null?void 0:at.gridOffset.r))+"%",this.$nextTick(()=>{this.initMeteogramEchart(o)})}},initMeteogramEchart(o){var C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F,$,X,J,Q,K,ee,te,ae,oe,q,N,I,me,he,pe,re,ne,s,xe,Le,Ve,He,Te,Be,Ce,Me,Ae,Ie,We,Pe,Oe,ve,Re,Ge,$e,Ye,je,ie,ze,O,Ke,we,De,at,le,_e,M,it,Se,et,nt,st,lt,mt,ht,pt,gt,g,ke,Fe,Ue,qe,Ze,Xe,Je,Y,yt,ft,bt,ut,xt,wt,kt,zt,Dt,de,Qe,ge,Ht,Tt,Bt,Ct,Mt,At,It,Wt,Pt,Ot,vt,Rt,Gt,$t,Yt,jt,Ft,Ut,qt,Zt,Xt,Jt,Qt,Kt,ea,ta,aa,oa,ia,sa,la,ra,na,da,ca,ma,ha,pa,ga,ya,fa,ba,ua,xa,wa,ka,za,Da;const a=o.interval||3;let t=Math.max(...this.meteogramData.temperatures.filter(n=>typeof n=="number"&&!isNaN(n))),c=Math.min(...this.meteogramData.temperatures.filter(n=>typeof n=="number"&&!isNaN(n))),d=Math.floor(c/5)*5,i=Math.ceil(t/5)*5,m=Math.ceil((i-d)/5);d=Math.floor((d-2*m)/5)*5,i=Math.ceil((i+1)/5)*5,m=Math.ceil((i-d)/5);let p="";a===1?(p=this.locale==="zhHans"?"1小时降水 ( mm ) ":"Precip.1h ( mm ) ",this.locale,this.locale,this.locale,this.locale):(p=this.locale==="zhHans"?"3小时降水 ( mm ) ":"Precip.3h ( mm ) ",this.locale,this.locale,this.locale,this.locale);let y,h={title:{text:this.locale==="zhHans"?"温度":"Temperature",top:"10px",left:0,textStyle:{fontWeight:"500",fontSize:16,color:this.theme==="dark"?"rgba(255, 255, 255, 1)":"rgba(28,31,35,1)"}},grid:{show:!0,bottom:"20%",top:"40px",left:`${this.meteogramData.gridOffset.l}%`,right:`${this.meteogramData.gridOffset.r}%`,borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0, 0, 0, 0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"axis",show:!0,position:"right",formatter:n=>{var ye,fe,be,ue;const Ee=(ye=n==null?void 0:n.find(T=>T.seriesType==="line"))==null?void 0:ye.dataIndex;return n.find(T=>T.seriesType==="scatter")?!1:`<div style="font-size: 13px;"><strong>${u.tz((fe=this.meteogramData)==null?void 0:fe.dates[Ee],this.positionGmt).format("MMM-DD/HHmm[LT]")}</strong></div>
70
70
  <div style="font-size: 13px;display: ${isNaN((be=n==null?void 0:n.find(T=>T.seriesName==="Temperature"||T.seriesName==="温度"))==null?void 0:be.value)?"none":"block"}">
71
71
  <span style="display:inline-block; height: 10px;width: 10px;border-radius: 50%;background-color: ${this.theme==="dark"?"rgba(255, 161, 0, 1)":"rgba(242, 153, 56, 1)"};}"></span>
72
72
  <span>${this.locale==="zhHans"?"温度: ":"Temperature: "}</span>
@@ -138,7 +138,7 @@
138
138
  <g transform="rotate(${o}, 512, 512)">
139
139
  <path d="M128 896l384-768 384 768-384-128-384 128z" fill="${a}" p-id="9615"></path>
140
140
  </g>
141
- </svg>`;return btoa(unescape(encodeURIComponent(t)))},async convertSvgUrlToBase64(o){try{const t=await(await fetch(o)).text();return`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(t)))}`}catch(a){return console.warn("SVG conversion error:",a),o}}}},bi={class:"idm-spot-historical-report"},ui={class:"row"},xi={class:"col",style:{width:"54%"}},wi={key:0,style:{"margin-left":"8px"}},ki={key:1,style:{"margin-left":"8px"}},zi={class:"col",style:{width:"42%"}},Di={style:{"margin-left":"8px"}},Ni={class:"row"},_i={class:"col",style:{width:"54%"}},Si={style:{"margin-left":"8px"}},Ei={class:"content-box"},Li={key:0,class:"meteogram-echart-section"},Vi={key:2,id:"tempEchart"},Hi={key:3,id:"precipEchart"},Ti={key:4,id:"windIconsEchart"},Bi={key:5,id:"windEchart"},Ci={key:6,id:"waveEchart"},Mi={key:7,id:"currentEchart"},Ai={key:8,id:"sstEchart"},Ii={class:"hourly-table-section"},Wi={key:0,class:"card"},Pi={class:"date"},Oi={class:"",style:{"font-size":"16px","font-weight":"500"}},vi={rowspan:"2",colspan:"1",class:"border",style:{width:"90px"}},Ri={rowspan:"1",colspan:"1",class:"border"},Gi={rowspan:"1",colspan:"1",class:"border"},$i={rowspan:"1",colspan:"1",class:"border"},Yi={rowspan:"1",colspan:"4",class:"border"},ji={rowspan:"1",colspan:"3",class:"border"},Fi={rowspan:"1",colspan:"3",class:"border"},Ui={rowspan:"1",colspan:"3",class:"border"},qi={rowspan:"1",colspan:"2",class:"border"},Zi={rowspan:"1",colspan:"1",class:"border"},Xi={rowspan:"1",colspan:"1",class:"border"},Ji={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},Qi={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},Ki={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},es={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ts={rowspan:"1",colspan:"1",class:"border",style:{width:"30px"}},as={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},os={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},is={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ss={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ls={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},rs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ns={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ds={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},cs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ms={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},hs={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},ps={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},gs={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},ys={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}},fs={rowspan:"1",colspan:"1",class:"border",style:{width:"90px"}},bs={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},us={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},xs={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},ws={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},ks=["src"],zs={key:1},Ds={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ns={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},_s={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Ss=["src"],Es={key:1},Ls={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Vs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Hs={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Ts=["src"],Bs={key:1},Cs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ms={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},As=["src"],Is={key:1},Ws={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ps={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Os=["src"],vs={key:1},Rs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Gs={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},$s={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}};function Ys(o,a,t,c,d,i){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H;const m=e.resolveComponent("IdmLoading");return e.openBlock(),e.createElementBlock("div",bi,[(p=t.reportData)!=null&&p.showSummary?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["summary-info-box",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",ui,[e.createElementVNode("div",xi,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"位置":"Position")+":",3),(y=t.reportData)!=null&&y.portName?(e.openBlock(),e.createElementBlock("span",wi,e.toDisplayString((h=t.reportData)==null?void 0:h.portName)+" "+e.toDisplayString(`[${i.computeLat(t.reportData.lat)}, ${i.computeLng(t.reportData.lng)}]`),1)):(e.openBlock(),e.createElementBlock("span",ki,e.toDisplayString(`${i.computeLat(t.reportData.lat)} , ${i.computeLng(t.reportData.lng)}`),1))]),e.createElementVNode("div",zi,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"历史时段":"History Period")+":",3),e.createElementVNode("span",Di,e.toDisplayString(i.computeTzTime((k=(f=t.reportData)==null?void 0:f.dateRange)==null?void 0:k[0],d.positionGmt))+" ~ "+e.toDisplayString(i.computeTzTime((B=(w=t.reportData)==null?void 0:w.dateRange)==null?void 0:B[1],d.positionGmt)),1)])]),e.createElementVNode("div",Ni,[e.createElementVNode("div",_i,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"时区":"Timezone")+":",3),e.createElementVNode("span",Si,"UTC "+e.toDisplayString((L=t.reportData)==null?void 0:L.positionOffset),1)])])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",Ei,[(V=t.reportData)!=null&&V.showTempChart||(C=t.reportData)!=null&&C.showPrecipChart||(z=t.reportData)!=null&&z.showWindChart||(D=t.reportData)!=null&&D.showWaveChart||(_=t.reportData)!=null&&_.showCurrentChart||(A=t.reportData)!=null&&A.showSstChart?(e.openBlock(),e.createElementBlock("div",Li,[t.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):t.reportData?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)),!t.loading&&((W=t.reportData)!=null&&W.showTempChart)?(e.openBlock(),e.createElementBlock("div",Vi)):e.createCommentVNode("",!0),!t.loading&&((b=t.reportData)!=null&&b.showPrecipChart)?(e.openBlock(),e.createElementBlock("div",Hi)):e.createCommentVNode("",!0),!t.loading&&((P=t.reportData)!=null&&P.showWindChart)?(e.openBlock(),e.createElementBlock("div",Ti)):e.createCommentVNode("",!0),!t.loading&&((S=t.reportData)!=null&&S.showWindChart)?(e.openBlock(),e.createElementBlock("div",Bi)):e.createCommentVNode("",!0),!t.loading&&((v=t.reportData)!=null&&v.showWaveChart)?(e.openBlock(),e.createElementBlock("div",Ci)):e.createCommentVNode("",!0),!t.loading&&((R=t.reportData)!=null&&R.showCurrentChart)?(e.openBlock(),e.createElementBlock("div",Mi)):e.createCommentVNode("",!0),!t.loading&&((E=t.reportData)!=null&&E.showSstChart)?(e.openBlock(),e.createElementBlock("div",Ai)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Ii,[t.loading?t.loading?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)):(e.openBlock(),e.createElementBlock("div",Wi,[e.createElementVNode("div",Pi,[e.createElementVNode("div",Oi,e.toDisplayString(t.locale==="zhHans"?"小时预报":"Hourly Forecast"),1),e.createElementVNode("div",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"]),style:{"font-size":"14px","font-weight":"300"}}," * "+e.toDisplayString(t.locale==="zhHans"?"涌浪、显浪高度>=1.5米时标记为黄色, 风速蒲福等级>=4时标记为黄色。":"Swell or Sig.wave height alert in yellow for value>=1.5m, wind speed alert in yellow for beaufort scale >= 4."),3)]),e.createElementVNode("table",{class:e.normalizeClass(["conditions-table",(x=t.reportData)!=null&&x.showSummary?"":"table-header-fixed"])},[e.createElementVNode("thead",{class:e.normalizeClass(t.theme==="dark"?"dark":"light")},[e.createElementVNode("tr",{class:e.normalizeClass(["day tr-title",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("th",vi,e.toDisplayString(t.locale==="zhHans"?"时间(LT)":"DateTime (LT)"),1),e.createElementVNode("th",Ri,e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),e.createElementVNode("th",Gi,e.toDisplayString(t.locale==="zhHans"?"3小时降水":"Precip.3h"),1),e.createElementVNode("th",$i,e.toDisplayString(t.locale==="zhHans"?"能见度":"Visibility"),1),e.createElementVNode("th",Yi,e.toDisplayString(t.locale==="zhHans"?"风":"Wind"),1),e.createElementVNode("th",ji,e.toDisplayString(t.locale==="zhHans"?"风浪":"Wind wave"),1),e.createElementVNode("th",Fi,e.toDisplayString(t.locale==="zhHans"?"涌浪":"Swell wave"),1),e.createElementVNode("th",Ui,e.toDisplayString(t.locale==="zhHans"?"显浪":"Sig.wave"),1),e.createElementVNode("th",qi,e.toDisplayString(t.locale==="zhHans"?"洋流":"Current"),1),e.createElementVNode("th",Zi,e.toDisplayString(t.locale==="zhHans"?"海面":"Sea Level"),1),e.createElementVNode("th",Xi,e.toDisplayString(t.locale==="zhHans"?"海表":"Sea Surface"),1)],2),e.createElementVNode("tr",{class:e.normalizeClass(["hour tr-title",t.theme==="dark"?"dark":"light"])},[a[26]||(a[26]=e.createElementVNode("th",{rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},"°C",-1)),e.createElementVNode("th",Ji,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"累计":"Acc"),1),a[0]||(a[0]=e.createElementVNode("br",null,null,-1)),a[1]||(a[1]=e.createTextVNode("(mm)",-1))]),e.createElementVNode("th",Qi,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"距离":"Dist"),1),a[2]||(a[2]=e.createElementVNode("br",null,null,-1)),a[3]||(a[3]=e.createTextVNode("(nm)",-1))]),e.createElementVNode("th",Ki,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",es,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[4]||(a[4]=e.createElementVNode("br",null,null,-1)),a[5]||(a[5]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",ts,e.toDisplayString(t.locale==="zhHans"?"等级":"BF"),1),e.createElementVNode("th",as,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"阵风":"Gusts"),1),a[6]||(a[6]=e.createElementVNode("br",null,null,-1)),a[7]||(a[7]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",os,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",is,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[8]||(a[8]=e.createElementVNode("br",null,null,-1)),a[9]||(a[9]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ss,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[10]||(a[10]=e.createElementVNode("br",null,null,-1)),a[11]||(a[11]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",ls,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",rs,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[12]||(a[12]=e.createElementVNode("br",null,null,-1)),a[13]||(a[13]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ns,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[14]||(a[14]=e.createElementVNode("br",null,null,-1)),a[15]||(a[15]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",ds,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",cs,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[16]||(a[16]=e.createElementVNode("br",null,null,-1)),a[17]||(a[17]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ms,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[18]||(a[18]=e.createElementVNode("br",null,null,-1)),a[19]||(a[19]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",hs,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",ps,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[20]||(a[20]=e.createElementVNode("br",null,null,-1)),a[21]||(a[21]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",gs,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[22]||(a[22]=e.createElementVNode("br",null,null,-1)),a[23]||(a[23]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ys,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),a[24]||(a[24]=e.createElementVNode("br",null,null,-1)),a[25]||(a[25]=e.createTextVNode("(°C)",-1))])],2)],2),e.createElementVNode("tbody",{class:e.normalizeClass((H=t.reportData)!=null&&H.showSummary?"":"scroll")},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.hourlyTableData,l=>(e.openBlock(),e.createElementBlock("tr",{key:Math.random()+l.localDate,class:e.normalizeClass(["text border-bottom",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("td",fs,[e.createElementVNode("div",null,e.toDisplayString(l.localDate),1)]),e.createElementVNode("td",bs,[e.createElementVNode("div",null,e.toDisplayString(l.temp),1)]),e.createElementVNode("td",us,e.toDisplayString(l.precipSum),1),e.createElementVNode("td",xs,e.toDisplayString(l.visibility),1),e.createElementVNode("td",ws,[e.createTextVNode(e.toDisplayString(l.windDir)+" ",1),!isNaN(l.windBearing)&&l.windDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWindArrowBase64(l.windBearing,this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,ks)):(e.openBlock(),e.createElementBlock("span",zs,"-"))]),e.createElementVNode("td",Ds,e.toDisplayString(l.windSpeed),1),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.windBF>=4?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"30px"}},e.toDisplayString(l.windBF),3),e.createElementVNode("td",Ns,e.toDisplayString(l.windGusts),1),e.createElementVNode("td",_s,[e.createTextVNode(e.toDisplayString(l.windWaveDir)+" ",1),!isNaN(l.windWaveBearing)&&l.windWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.windWaveBearing,(this.theme==="dark","#7cc7b3"))}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Ss)):(e.openBlock(),e.createElementBlock("span",Es,"-"))]),e.createElementVNode("td",Ls,e.toDisplayString(l.windWaveHeight),1),e.createElementVNode("td",Vs,e.toDisplayString(l.windWavePeriod),1),e.createElementVNode("td",Hs,[e.createTextVNode(e.toDisplayString(l.swellDir)+" ",1),!isNaN(l.swellBearing)&&l.swellDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.swellBearing,this.theme==="dark"?"rgb(17, 245, 211)":"rgba(0, 230, 194, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Ts)):(e.openBlock(),e.createElementBlock("span",Bs,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.swellHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.swellHeight),3),e.createElementVNode("td",Cs,e.toDisplayString(l.swellPeriod),1),e.createElementVNode("td",Ms,[e.createTextVNode(e.toDisplayString(l.sigWaveDir)+" ",1),!isNaN(l.sigWaveBearing)&&l.sigWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.sigWaveBearing,this.theme==="dark"?"rgba(89, 199, 211, 1)":"rgba(1, 189, 211, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,As)):(e.openBlock(),e.createElementBlock("span",Is,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.sigWaveHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.sigWaveHeight),3),e.createElementVNode("td",Ws,e.toDisplayString(l.sigWavePeriod),1),e.createElementVNode("td",Ps,[e.createTextVNode(e.toDisplayString(l.currentDir)+" ",1),!isNaN(l.currentBearing)&&l.currentDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.currentBearing,this.theme==="dark"?"rgba(220, 115, 255, 1)":"rgba(178, 51, 220, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Os)):(e.openBlock(),e.createElementBlock("span",vs,"-"))]),e.createElementVNode("td",Rs,e.toDisplayString(l.currentSpd),1),e.createElementVNode("td",Gs,e.toDisplayString(l.seaLevel),1),e.createElementVNode("td",$s,e.toDisplayString(l.seaSurfaceTemp),1)],2))),128))],2)],2)]))])])])}const Et=tt(fi,[["render",Ys]]),ir="",js={name:"IdmSeasonal",components:{IdmLoading:ct},props:{reportData:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},theme:{type:String,default:"light"},locale:{type:String,default:"en"}},data(){return{positionGmt:void 0,meteogramData:void 0,hourlyTableData:[]}},computed:{computeUTCTime(){return(o,a="MMM-DD/HHmm[Z], YYYY")=>{if(o){const t=u(o).utc();return`${t==null?void 0:t.format(a)}`}return"-"}},computeLat(){return(o,a=4)=>Z.LngLatHelper.lat2pretty(o,a).pretty},computeLng(){return(o,a=4)=>Z.LngLatHelper.lng2pretty(o,a).pretty},roundPrecision(){return(o,a=4)=>isNaN(o)||o===null||o===void 0||isNaN(a)?"-":Z.LngLatHelper.roundPrecision(o,a)}},watch:{"reportData.version":{handler(){var o,a,t,c,d;(o=this.reportData)!=null&&o.version&&(this.positionGmt=(d=(c=(t=(a=this.reportData)==null?void 0:a.seasonal)==null?void 0:t.weather)==null?void 0:c[0])==null?void 0:d.timezone,this.handleRender())},immediate:!0}},methods:{handleRender(){this.$nextTick(()=>{this.disposeEcharts(),this.initSeasonalEchart()})},initSeasonalEchart(){var D,_,A,W,b,P,S,v,R,E,x,H,l,G;let o=Math.max(...[...this.reportData.highTemp,...this.reportData.lastYearHighTemp].filter(r=>typeof r=="number"&&!isNaN(r))),a=Math.min(...[...this.reportData.lowTemp,...this.reportData.lastYearLowTemp].filter(r=>typeof r=="number"&&!isNaN(r))),t=Math.ceil((o+1)/5)*5,c=Math.floor((a-1)/5)*5,d=Math.ceil((t-c)/5),i=[{name:this.locale==="zhHans"?"最高温度":"High",type:"line",data:(D=this.reportData)==null?void 0:D.highTemp,show:!0,symbol:"none",smooth:!1,itemStyle:{color:this.theme==="dark"?"rgba(255, 161, 0, 1)":"rgba(242, 153, 56, 1)"},label:{show:!1}},{name:this.locale==="zhHans"?"去年最高温度":"High, last year",type:"line",symbol:"none",data:(_=this.reportData)==null?void 0:_.lastYearHighTemp,show:(A=this.reportData)==null?void 0:A.compareToLastYear,itemStyle:{color:"#f7c587"},lineStyle:{color:"#f7c587"},label:{show:!1}},{name:this.locale==="zhHans"?"最低温度":"Low",type:"line",data:(W=this.reportData)==null?void 0:W.lowTemp,show:!0,symbol:"none",smooth:!1,itemStyle:{color:"#2164bf"},label:{show:!1}},{name:this.locale==="zhHans"?"去年最低温度":"Low, last year",type:"line",symbol:"none",data:(b=this.reportData)==null?void 0:b.lastYearLowTemp,show:(P=this.reportData)==null?void 0:P.compareToLastYear,itemStyle:{color:"#7baef7"},lineStyle:{color:"#7baef7"},label:{show:!1}}];const m={title:{text:this.locale==="zhHans"?"温度":"Temperature",top:"10px",left:0,textStyle:{fontWeight:"500",fontSize:16,color:this.theme==="dark"?"rgba(255, 255, 255, 1)":"rgba(28,31,35,1)"}},grid:{show:!0,bottom:"15%",top:"45px",left:"4%",right:"4%",borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(28,31,35,0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"axis",show:!0,position:"right",formatter:r=>{var F,$,X,J,Q,K,ee,te,ae,oe,q;const U=(F=r==null?void 0:r[0])==null?void 0:F.dataIndex;if(r.find(N=>N.seriesType==="scatter"))return!1;{let N=`<div style="font-size: 13px;"><strong>${($=this.reportData)==null?void 0:$.dates[U]}</strong></div>
141
+ </svg>`;return btoa(unescape(encodeURIComponent(t)))},async convertSvgUrlToBase64(o){try{const t=await(await fetch(o)).text();return`data:image/svg+xml;base64,${btoa(unescape(encodeURIComponent(t)))}`}catch(a){return console.warn("SVG conversion error:",a),o}}}},bi={class:"idm-spot-historical-report"},ui={class:"row"},xi={class:"col",style:{width:"54%"}},wi={key:0,style:{"margin-left":"8px"}},ki={key:1,style:{"margin-left":"8px"}},zi={class:"col",style:{width:"42%"}},Di={style:{"margin-left":"8px"}},Ni={class:"row"},_i={class:"col",style:{width:"54%"}},Si={style:{"margin-left":"8px"}},Ei={class:"content-box"},Li={key:0,class:"meteogram-echart-section"},Vi={key:2,id:"tempEchart"},Hi={key:3,id:"precipEchart"},Ti={key:4,id:"windIconsEchart"},Bi={key:5,id:"windEchart"},Ci={key:6,id:"waveEchart"},Mi={key:7,id:"currentEchart"},Ai={key:8,id:"sstEchart"},Ii={class:"hourly-table-section"},Wi={key:0,class:"card"},Pi={class:"date"},Oi={class:"",style:{"font-size":"16px","font-weight":"500"}},vi={rowspan:"2",colspan:"1",class:"border",style:{width:"90px"}},Ri={rowspan:"1",colspan:"1",class:"border"},Gi={rowspan:"1",colspan:"1",class:"border"},$i={rowspan:"1",colspan:"1",class:"border"},Yi={rowspan:"1",colspan:"4",class:"border"},ji={rowspan:"1",colspan:"3",class:"border"},Fi={rowspan:"1",colspan:"3",class:"border"},Ui={rowspan:"1",colspan:"3",class:"border"},qi={rowspan:"1",colspan:"2",class:"border"},Zi={rowspan:"1",colspan:"1",class:"border"},Xi={rowspan:"1",colspan:"1",class:"border"},Ji={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},Qi={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},Ki={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},es={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ts={rowspan:"1",colspan:"1",class:"border",style:{width:"30px"}},as={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},os={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},is={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ss={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ls={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},rs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ns={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ds={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},cs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},ms={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},hs={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},ps={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},gs={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},ys={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}},fs={rowspan:"1",colspan:"1",class:"border",style:{width:"90px"}},bs={rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},us={rowspan:"1",colspan:"1",class:"border",style:{width:"80px"}},xs={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},ws={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},ks=["src"],zs={key:1},Ds={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ns={rowspan:"1",colspan:"1",class:"border",style:{width:"60px"}},_s={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Ss=["src"],Es={key:1},Ls={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Vs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Hs={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Ts=["src"],Bs={key:1},Cs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ms={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},As=["src"],Is={key:1},Ws={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Ps={rowspan:"1",colspan:"1",class:"border",style:{width:"50px","font-size":"11px","text-align":"right","padding-right":"3px"}},Os=["src"],vs={key:1},Rs={rowspan:"1",colspan:"1",class:"border",style:{width:"45px"}},Gs={rowspan:"1",colspan:"1",class:"border",style:{width:"70px"}},$s={rowspan:"1",colspan:"1",class:"border",style:{width:"85px"}};function Ys(o,a,t,c,d,i){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H;const m=e.resolveComponent("IdmLoading");return e.openBlock(),e.createElementBlock("div",bi,[(p=t.reportData)!=null&&p.showSummary?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["summary-info-box",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",ui,[e.createElementVNode("div",xi,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"位置":"Position")+":",3),(y=t.reportData)!=null&&y.portName?(e.openBlock(),e.createElementBlock("span",wi,e.toDisplayString((h=t.reportData)==null?void 0:h.portName)+" "+e.toDisplayString(`[${i.computeLat(t.reportData.lat)}, ${i.computeLng(t.reportData.lng)}]`),1)):(e.openBlock(),e.createElementBlock("span",ki,e.toDisplayString(`${i.computeLat(t.reportData.lat)} , ${i.computeLng(t.reportData.lng)}`),1))]),e.createElementVNode("div",zi,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"历史时段":"History Period")+":",3),e.createElementVNode("span",Di,e.toDisplayString(i.computeTzTime((k=(f=t.reportData)==null?void 0:f.dateRange)==null?void 0:k[0],d.positionGmt))+" ~ "+e.toDisplayString(i.computeTzTime((B=(w=t.reportData)==null?void 0:w.dateRange)==null?void 0:B[1],d.positionGmt)),1)])]),e.createElementVNode("div",Ni,[e.createElementVNode("div",_i,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"时区":"Timezone")+":",3),e.createElementVNode("span",Si,"UTC "+e.toDisplayString((L=t.reportData)==null?void 0:L.positionOffset),1)])])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",Ei,[(V=t.reportData)!=null&&V.showTempChart||(C=t.reportData)!=null&&C.showPrecipChart||(z=t.reportData)!=null&&z.showWindChart||(D=t.reportData)!=null&&D.showWaveChart||(_=t.reportData)!=null&&_.showCurrentChart||(A=t.reportData)!=null&&A.showSstChart?(e.openBlock(),e.createElementBlock("div",Li,[t.loading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):t.reportData?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)),!t.loading&&((W=t.reportData)!=null&&W.showTempChart)?(e.openBlock(),e.createElementBlock("div",Vi)):e.createCommentVNode("",!0),!t.loading&&((b=t.reportData)!=null&&b.showPrecipChart)?(e.openBlock(),e.createElementBlock("div",Hi)):e.createCommentVNode("",!0),!t.loading&&((P=t.reportData)!=null&&P.showWindChart)?(e.openBlock(),e.createElementBlock("div",Ti)):e.createCommentVNode("",!0),!t.loading&&((S=t.reportData)!=null&&S.showWindChart)?(e.openBlock(),e.createElementBlock("div",Bi)):e.createCommentVNode("",!0),!t.loading&&((v=t.reportData)!=null&&v.showWaveChart)?(e.openBlock(),e.createElementBlock("div",Ci)):e.createCommentVNode("",!0),!t.loading&&((R=t.reportData)!=null&&R.showCurrentChart)?(e.openBlock(),e.createElementBlock("div",Mi)):e.createCommentVNode("",!0),!t.loading&&((E=t.reportData)!=null&&E.showSstChart)?(e.openBlock(),e.createElementBlock("div",Ai)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Ii,[t.loading?t.loading?(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)):(e.openBlock(),e.createElementBlock("div",Wi,[e.createElementVNode("div",Pi,[e.createElementVNode("div",Oi,e.toDisplayString(t.locale==="zhHans"?"小时预报":"Hourly Forecast"),1),e.createElementVNode("div",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"]),style:{"font-size":"14px","font-weight":"300"}}," * "+e.toDisplayString(t.locale==="zhHans"?"涌浪、显浪高度>=1.5米时标记为黄色, 风速蒲福等级>=4时标记为黄色。":"Swell or Sig.wave height alert in yellow for value>=1.5m, wind speed alert in yellow for beaufort scale >= 4."),3)]),e.createElementVNode("table",{class:e.normalizeClass(["conditions-table",(x=t.reportData)!=null&&x.showSummary?"":"table-header-fixed"])},[e.createElementVNode("thead",{class:e.normalizeClass(t.theme==="dark"?"dark":"light")},[e.createElementVNode("tr",{class:e.normalizeClass(["day tr-title",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("th",vi,e.toDisplayString(t.locale==="zhHans"?"时间(LT)":"DateTime (LT)"),1),e.createElementVNode("th",Ri,e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),e.createElementVNode("th",Gi,e.toDisplayString(t.locale==="zhHans"?"3小时降水":"Precip.3h"),1),e.createElementVNode("th",$i,e.toDisplayString(t.locale==="zhHans"?"能见度":"Visibility"),1),e.createElementVNode("th",Yi,e.toDisplayString(t.locale==="zhHans"?"风":"Wind"),1),e.createElementVNode("th",ji,e.toDisplayString(t.locale==="zhHans"?"风浪":"Wind wave"),1),e.createElementVNode("th",Fi,e.toDisplayString(t.locale==="zhHans"?"涌浪":"Swell wave"),1),e.createElementVNode("th",Ui,e.toDisplayString(t.locale==="zhHans"?"显浪":"Sig.wave"),1),e.createElementVNode("th",qi,e.toDisplayString(t.locale==="zhHans"?"洋流":"Current"),1),e.createElementVNode("th",Zi,e.toDisplayString(t.locale==="zhHans"?"海面":"Sea Level"),1),e.createElementVNode("th",Xi,e.toDisplayString(t.locale==="zhHans"?"海表":"Sea Surface"),1)],2),e.createElementVNode("tr",{class:e.normalizeClass(["hour tr-title",t.theme==="dark"?"dark":"light"])},[a[26]||(a[26]=e.createElementVNode("th",{rowspan:"1",colspan:"1",class:"border",style:{width:"50px"}},"°C",-1)),e.createElementVNode("th",Ji,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"累计":"Acc"),1),a[0]||(a[0]=e.createElementVNode("br",null,null,-1)),a[1]||(a[1]=e.createTextVNode("(mm)",-1))]),e.createElementVNode("th",Qi,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"距离":"Dist"),1),a[2]||(a[2]=e.createElementVNode("br",null,null,-1)),a[3]||(a[3]=e.createTextVNode("(nm)",-1))]),e.createElementVNode("th",Ki,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",es,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[4]||(a[4]=e.createElementVNode("br",null,null,-1)),a[5]||(a[5]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",ts,e.toDisplayString(t.locale==="zhHans"?"等级":"BF"),1),e.createElementVNode("th",as,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"阵风":"Gusts"),1),a[6]||(a[6]=e.createElementVNode("br",null,null,-1)),a[7]||(a[7]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",os,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",is,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[8]||(a[8]=e.createElementVNode("br",null,null,-1)),a[9]||(a[9]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ss,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[10]||(a[10]=e.createElementVNode("br",null,null,-1)),a[11]||(a[11]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",ls,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",rs,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[12]||(a[12]=e.createElementVNode("br",null,null,-1)),a[13]||(a[13]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ns,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[14]||(a[14]=e.createElementVNode("br",null,null,-1)),a[15]||(a[15]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",ds,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",cs,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[16]||(a[16]=e.createElementVNode("br",null,null,-1)),a[17]||(a[17]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ms,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"周期":"Prd"),1),a[18]||(a[18]=e.createElementVNode("br",null,null,-1)),a[19]||(a[19]=e.createTextVNode("(s)",-1))]),e.createElementVNode("th",hs,e.toDisplayString(t.locale==="zhHans"?"方向":"Dir"),1),e.createElementVNode("th",ps,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"速度":"Spd"),1),a[20]||(a[20]=e.createElementVNode("br",null,null,-1)),a[21]||(a[21]=e.createTextVNode("(kts)",-1))]),e.createElementVNode("th",gs,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"高度":"Hgt"),1),a[22]||(a[22]=e.createElementVNode("br",null,null,-1)),a[23]||(a[23]=e.createTextVNode("(m)",-1))]),e.createElementVNode("th",ys,[e.createTextVNode(e.toDisplayString(t.locale==="zhHans"?"温度":"Temp"),1),a[24]||(a[24]=e.createElementVNode("br",null,null,-1)),a[25]||(a[25]=e.createTextVNode("(°C)",-1))])],2)],2),e.createElementVNode("tbody",{class:e.normalizeClass((H=t.reportData)!=null&&H.showSummary?"":"scroll")},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.hourlyTableData,l=>(e.openBlock(),e.createElementBlock("tr",{key:Math.random()+l.localDate,class:e.normalizeClass(["text border-bottom",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("td",fs,[e.createElementVNode("div",null,e.toDisplayString(l.localDate),1)]),e.createElementVNode("td",bs,[e.createElementVNode("div",null,e.toDisplayString(l.temp),1)]),e.createElementVNode("td",us,e.toDisplayString(l.precipSum),1),e.createElementVNode("td",xs,e.toDisplayString(l.visibility),1),e.createElementVNode("td",ws,[e.createTextVNode(e.toDisplayString(l.windDir)+" ",1),!isNaN(l.windBearing)&&l.windDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWindArrowBase64(l.windBearing,this.theme==="dark"?"rgba(159, 255, 126, 1)":"rgba(54, 212, 0, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,ks)):(e.openBlock(),e.createElementBlock("span",zs,"-"))]),e.createElementVNode("td",Ds,e.toDisplayString(l.windSpeed),1),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.windBF>=4?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"30px"}},e.toDisplayString(l.windBF),3),e.createElementVNode("td",Ns,e.toDisplayString(l.windGusts),1),e.createElementVNode("td",_s,[e.createTextVNode(e.toDisplayString(l.windWaveDir)+" ",1),!isNaN(l.windWaveBearing)&&l.windWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.windWaveBearing,(this.theme==="dark","#7cc7b3"))}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Ss)):(e.openBlock(),e.createElementBlock("span",Es,"-"))]),e.createElementVNode("td",Ls,e.toDisplayString(l.windWaveHeight),1),e.createElementVNode("td",Vs,e.toDisplayString(l.windWavePeriod),1),e.createElementVNode("td",Hs,[e.createTextVNode(e.toDisplayString(l.swellDir)+" ",1),!isNaN(l.swellBearing)&&l.swellDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.swellBearing,this.theme==="dark"?"rgb(17, 245, 211)":"rgba(0, 230, 194, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Ts)):(e.openBlock(),e.createElementBlock("span",Bs,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.swellHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.swellHeight),3),e.createElementVNode("td",Cs,e.toDisplayString(l.swellPeriod),1),e.createElementVNode("td",Ms,[e.createTextVNode(e.toDisplayString(l.sigWaveDir)+" ",1),!isNaN(l.sigWaveBearing)&&l.sigWaveDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.sigWaveBearing,this.theme==="dark"?"rgba(89, 199, 211, 1)":"rgba(1, 189, 211, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,As)):(e.openBlock(),e.createElementBlock("span",Is,"-"))]),e.createElementVNode("td",{rowspan:"1",colspan:"1",class:e.normalizeClass(["border",l.sigWaveHeight>1.5?"bg-yellow":"",t.theme==="dark"?"dark":"light"]),style:{width:"45px"}},e.toDisplayString(l.sigWaveHeight),3),e.createElementVNode("td",Ws,e.toDisplayString(l.sigWavePeriod),1),e.createElementVNode("td",Ps,[e.createTextVNode(e.toDisplayString(l.currentDir)+" ",1),!isNaN(l.currentBearing)&&l.currentDir?(e.openBlock(),e.createElementBlock("img",{key:0,class:"iconfont icon",src:`data:image/svg+xml;base64,${i.getRotatedWaveArrowBase64(l.currentBearing,this.theme==="dark"?"rgba(220, 115, 255, 1)":"rgba(178, 51, 220, 1)")}`,style:{width:"11px",height:"11px",display:"inline-block"}},null,8,Os)):(e.openBlock(),e.createElementBlock("span",vs,"-"))]),e.createElementVNode("td",Rs,e.toDisplayString(l.currentSpd),1),e.createElementVNode("td",Gs,e.toDisplayString(l.seaLevel),1),e.createElementVNode("td",$s,e.toDisplayString(l.seaSurfaceTemp),1)],2))),128))],2)],2)]))])])])}const Et=tt(fi,[["render",Ys],["__scopeId","data-v-46b3fc93"]]),ir="",js={name:"IdmSeasonal",components:{IdmLoading:ct},props:{reportData:{type:Object,default:()=>({})},loading:{type:Boolean,default:!1},theme:{type:String,default:"light"},locale:{type:String,default:"en"}},data(){return{positionGmt:void 0,meteogramData:void 0,hourlyTableData:[]}},computed:{computeUTCTime(){return(o,a="MMM-DD/HHmm[Z], YYYY")=>{if(o){const t=u(o).utc();return`${t==null?void 0:t.format(a)}`}return"-"}},computeLat(){return(o,a=4)=>Z.LngLatHelper.lat2pretty(o,a).pretty},computeLng(){return(o,a=4)=>Z.LngLatHelper.lng2pretty(o,a).pretty},roundPrecision(){return(o,a=4)=>isNaN(o)||o===null||o===void 0||isNaN(a)?"-":Z.LngLatHelper.roundPrecision(o,a)}},watch:{"reportData.version":{handler(){var o,a,t,c,d;(o=this.reportData)!=null&&o.version&&(this.positionGmt=(d=(c=(t=(a=this.reportData)==null?void 0:a.seasonal)==null?void 0:t.weather)==null?void 0:c[0])==null?void 0:d.timezone,this.handleRender())},immediate:!0}},methods:{handleRender(){this.$nextTick(()=>{this.disposeEcharts(),this.initSeasonalEchart()})},initSeasonalEchart(){var D,_,A,W,b,P,S,v,R,E,x,H,l,G;let o=Math.max(...[...this.reportData.highTemp,...this.reportData.lastYearHighTemp].filter(r=>typeof r=="number"&&!isNaN(r))),a=Math.min(...[...this.reportData.lowTemp,...this.reportData.lastYearLowTemp].filter(r=>typeof r=="number"&&!isNaN(r))),t=Math.ceil((o+1)/5)*5,c=Math.floor((a-1)/5)*5,d=Math.ceil((t-c)/5),i=[{name:this.locale==="zhHans"?"最高温度":"High",type:"line",data:(D=this.reportData)==null?void 0:D.highTemp,show:!0,symbol:"none",smooth:!1,itemStyle:{color:this.theme==="dark"?"rgba(255, 161, 0, 1)":"rgba(242, 153, 56, 1)"},label:{show:!1}},{name:this.locale==="zhHans"?"去年最高温度":"High, last year",type:"line",symbol:"none",data:(_=this.reportData)==null?void 0:_.lastYearHighTemp,show:(A=this.reportData)==null?void 0:A.compareToLastYear,itemStyle:{color:"#f7c587"},lineStyle:{color:"#f7c587"},label:{show:!1}},{name:this.locale==="zhHans"?"最低温度":"Low",type:"line",data:(W=this.reportData)==null?void 0:W.lowTemp,show:!0,symbol:"none",smooth:!1,itemStyle:{color:"#2164bf"},label:{show:!1}},{name:this.locale==="zhHans"?"去年最低温度":"Low, last year",type:"line",symbol:"none",data:(b=this.reportData)==null?void 0:b.lastYearLowTemp,show:(P=this.reportData)==null?void 0:P.compareToLastYear,itemStyle:{color:"#7baef7"},lineStyle:{color:"#7baef7"},label:{show:!1}}];const m={title:{text:this.locale==="zhHans"?"温度":"Temperature",top:"10px",left:0,textStyle:{fontWeight:"500",fontSize:16,color:this.theme==="dark"?"rgba(255, 255, 255, 1)":"rgba(28,31,35,1)"}},grid:{show:!0,bottom:"15%",top:"45px",left:"4%",right:"4%",borderColor:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(28,31,35,0.4)",borderWidth:1,z:1,zlevel:1},tooltip:{trigger:"axis",show:!0,position:"right",formatter:r=>{var F,$,X,J,Q,K,ee,te,ae,oe,q;const U=(F=r==null?void 0:r[0])==null?void 0:F.dataIndex;if(r.find(N=>N.seriesType==="scatter"))return!1;{let N=`<div style="font-size: 13px;"><strong>${($=this.reportData)==null?void 0:$.dates[U]}</strong></div>
142
142
  <div style="font-size: 13px;display: ${isNaN((X=r==null?void 0:r.find(I=>I.seriesName==="High"||I.seriesName==="最高温度"))==null?void 0:X.value)?"none":"block"}">
143
143
  <span style="display:inline-block; height: 10px;width: 10px;border-radius: 50%;background-color: ${this.theme==="dark"?"rgba(255, 161, 0, 1)":"rgba(242, 153, 56, 1)"};"></span>
144
144
  <span>${this.locale==="zhHans"?"最高温度":"High"} : </span>
@@ -185,7 +185,7 @@
185
185
  <span>${this.locale==="zhHans"?"去年降水量":"Precip, last year"} : </span>
186
186
  <strong>${(oe=r==null?void 0:r.find(N=>N.seriesName==="Precip, last year"||N.seriesName==="去年降水量"))==null?void 0:oe.value}</strong>
187
187
  <span style="padding-left: 3px;">mm</span>
188
- </div>`),q}}},legend:{show:!0,top:"10px",right:"4%",itemWidth:40,textStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"}},xAxis:{show:!0,left:0,right:0,top:"50%",height:"50%",type:"category",boundaryGap:!0,data:(G=this.reportData)==null?void 0:G.xDates,axisLabel:{show:!0,fontSize:12,color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0, 0, 0, 0.7)"},axisLine:{show:!0},axisTick:{show:!0,inside:!0,lineStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0,0,0,0.4)"}},z:1,zlevel:1},yAxis:[{type:"value",name:this.locale==="zhHans"?"风速 ( kts ) ":"Wind speed ( kts ) ",show:!0,min:h,max:f,interval:k,splitNumber:5,nameRotate:90,nameLocation:"middle",nameGap:25,nameTextStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},axisLabel:{show:!0,fontSize:10,color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},splitLine:{show:!0,lineStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.1)":"rgba(0,0,0,0.1)"}},z:0,zlevel:0},{type:"value",name:this.locale==="zhHans"?"降水量 ( mm ) ":"Precipitation ( mm ) ",show:!0,min:L,max:V,interval:C,splitNumber:5,nameRotate:90,nameLocation:"middle",nameGap:30,nameTextStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},axisLabel:{show:!0,fontSize:10,color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},splitLine:{show:!0,lineStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.1)":"rgba(0,0,0,0.1)"}},z:1,zlevel:0}],series:i.filter(r=>r.show)};this.$nextTick(()=>{let r;document.getElementById("wind-precip-echart")&&(r=j.init(document.getElementById("wind-precip-echart")),r.setOption(z))})},disposeEcharts(){document.getElementById("temperature-echart")&&j.dispose(document.getElementById("temperature-echart")),document.getElementById("wind-precip-echart")&&j.dispose(document.getElementById("wind-precip-echart"))}}},Fs={class:"idm-spot-seasonal-report"},Us={class:"row"},qs={class:"col",style:{width:"54%"}},Zs={key:0,style:{"margin-left":"8px"}},Xs={key:1,style:{"margin-left":"8px"}},Js={class:"col",style:{width:"42%"}},Qs={style:{"margin-left":"8px"}},Ks={class:"row"},el={class:"col",style:{width:"54%"}},tl={style:{"margin-left":"8px"}},al={class:"content-box"},ol={class:"summary-section"},il={class:"title",style:{"margin-left":"5px"}},sl={class:"info-block"},ll={class:"text"},rl={class:"text"},nl={class:"text"},dl={class:"text"},cl={class:"text"},ml={class:"text"},hl={class:"text"},pl={class:"text"},gl={class:"text"},yl={class:"text"},fl={class:"text"},bl={class:"seasonal-weather-section",style:{}},ul={key:0,id:"temperature-echart"},xl={key:1,id:"wind-precip-echart"};function wl(o,a,t,c,d,i){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P;const m=e.resolveComponent("IdmLoading");return e.openBlock(),e.createElementBlock("div",Fs,[(p=t.reportData)!=null&&p.showSummary?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["summary-info-box",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",Us,[e.createElementVNode("div",qs,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"位置":"Position")+":",3),(y=t.reportData)!=null&&y.portName?(e.openBlock(),e.createElementBlock("span",Zs,e.toDisplayString((h=t.reportData)==null?void 0:h.portName)+" "+e.toDisplayString(`[${i.computeLat(t.reportData.lat)}, ${i.computeLng(t.reportData.lng)}]`),1)):(e.openBlock(),e.createElementBlock("span",Xs,e.toDisplayString(`${i.computeLat(t.reportData.lat)} , ${i.computeLng(t.reportData.lng)}`),1))]),e.createElementVNode("div",Js,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报月份":"Forecast Month")+":",3),e.createElementVNode("span",Qs,e.toDisplayString((f=t.reportData)==null?void 0:f.forecastMonth),1)])]),e.createElementVNode("div",Ks,[e.createElementVNode("div",el,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"时区":"Timezone")+":",3),e.createElementVNode("span",tl,"UTC "+e.toDisplayString((k=t.reportData)==null?void 0:k.positionOffset),1)])])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",al,[e.createElementVNode("div",ol,[e.createElementVNode("div",il,e.toDisplayString(t.locale==="zhHans"?"总结":"Summary"),1),e.createElementVNode("div",sl,[e.createElementVNode("div",{class:e.normalizeClass(["block",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",{class:e.normalizeClass(["label primary-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"温度":"Temperature"),3),e.createElementVNode("div",{class:e.normalizeClass(["divider",t.theme==="dark"?"dark":"light"])},null,2),e.createElementVNode("div",ll,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"平均最高温度:":"Avg High Temp:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.minHighTemp)+" to "+e.toDisplayString(t.reportData.maxHighTemp)+" °C",1)]),e.createElementVNode("div",rl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"平均最低温度:":"Avg Low Temp:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.minLowTemp)+" to "+e.toDisplayString(t.reportData.maxLowTemp)+" °C",1)]),e.createElementVNode("div",nl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"最热日期:":"Hottest Day:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.hottestDay),1)]),e.createElementVNode("div",dl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"最冷日期:":"Coldest Day:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.coldestDay),1)])],2),e.createElementVNode("div",{class:e.normalizeClass(["block",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",{class:e.normalizeClass(["label primary-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"降水":"Precipitation"),3),e.createElementVNode("div",{class:e.normalizeClass(["divider",t.theme==="dark"?"dark":"light"])},null,2),e.createElementVNode("div",cl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"小雨:":"Light (<10mm):"),3),e.createTextVNode(" "+e.toDisplayString((L=(B=(w=t.reportData)==null?void 0:w.precip)==null?void 0:B.filter(S=>S<10))==null?void 0:L.length)+" days",1)]),e.createElementVNode("div",ml,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"中雨:":"Moderate (<=24.9mm):"),3),e.createTextVNode(" "+e.toDisplayString((z=(C=(V=t.reportData)==null?void 0:V.precip)==null?void 0:C.filter(S=>S>=10&&S<=24.9))==null?void 0:z.length)+" days",1)]),e.createElementVNode("div",hl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"大雨:":"Heavy (<=49.9mm):"),3),e.createTextVNode(" "+e.toDisplayString((A=(_=(D=t.reportData)==null?void 0:D.precip)==null?void 0:_.filter(S=>S>24.9&&S<=49.9))==null?void 0:A.length)+" days",1)]),e.createElementVNode("div",pl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暴雨:":"Rainstorm (>49.9mm):"),3),e.createTextVNode(" "+e.toDisplayString((P=(b=(W=t.reportData)==null?void 0:W.precip)==null?void 0:b.filter(S=>S>49.9))==null?void 0:P.length)+" days",1)])],2),e.createElementVNode("div",{class:e.normalizeClass(["block",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",{class:e.normalizeClass(["label primary-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"风":"Wind"),3),e.createElementVNode("div",{class:e.normalizeClass(["divider",t.theme==="dark"?"dark":"light"])},null,2),e.createElementVNode("div",gl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"平均风速:":"Mean Wind:"),3),e.createTextVNode(" "+e.toDisplayString(i.roundPrecision(t.reportData.meanWind,1))+" kts",1)]),e.createElementVNode("div",yl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"最强风日:":"Windiest Day:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.windiestDay)+" ( "+e.toDisplayString(t.reportData.maxWindSpeed)+"kts )",1)]),e.createElementVNode("div",fl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"主要风向:":"Dominant Wind Dir:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.dominantWind),1)])],2)])]),e.createElementVNode("div",bl,[t.loading?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",ul)),t.loading?t.loading?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):(e.openBlock(),e.createElementBlock("div",{key:3,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)):(e.openBlock(),e.createElementBlock("div",xl))])])])}const Lt=tt(js,[["render",wl]]),kl={install(o){o.component("IdmForecast",St),o.component("IdmHistorical",Et),o.component("IdmSeasonal",Lt)}},sr="",lr="",zl={props:{tropicals:{type:Object,default:()=>({})},ts:{type:String,default:()=>""},container:{type:String,default:()=>""},zoom:{type:Number,default:()=>1}},components:{},data(){return{map:void 0,source:"tropicals-source",bboxSource:"tropicals-bbox-source",historyLayer:"tropicals-history-layer",forecastLayer:"tropicals-forecast-layer",bboxLayer:"tropicals-bbox-layer",interpolateData:void 0}},mounted(){this.initMap()},methods:{async initMap(){dt.accessToken="pk.eyJ1IjoibmVhdGNoZW5oZW5nIiwiYSI6ImNsdXM3cnBmODBsemgycW1vaXc1bjV6bXMifQ.w6fqHGRbhNhLvm0LnX4ZVw";const o=new dt.Map({container:this.container,style:{version:8,name:"light",metadata:{"mapbox:print":{width:8.5,height:11,units:"in",format:"png",resolution:300},"mapbox:type":"default","mapbox:trackposition":!0,"mapbox:autocomposite":!0,"mapbox:sdk-support":{android:"11.0.0",ios:"11.0.0",js:"3.0.0"},"mapbox:origin":"outdoors-v12","mapbox:groups":{"Terrain, terrain-labels":{name:"Terrain, terrain-labels",collapsed:!0},"Administrative boundaries, admin":{name:"Administrative boundaries, admin",collapsed:!0},"Land & water, built":{name:"Land & water, built",collapsed:!0},"Terrain, surface":{name:"Terrain, surface",collapsed:!0},"Land & water, land":{name:"Land & water, land",collapsed:!1},"Natural features, natural-labels":{name:"Natural features, natural-labels",collapsed:!0},e9bb8e77353431519f7918998e9079d9:{name:"Group",collapsed:!1},"Walking, cycling, etc., barriers-bridges":{name:"Walking, cycling, etc., barriers-bridges",collapsed:!0},"Place labels, place-labels":{name:"Place labels, place-labels",collapsed:!1},"Transit, ferries":{name:"Transit, ferries",collapsed:!0},"Transit, elevated":{name:"Transit, elevated",collapsed:!0},"Walking, cycling, etc., tunnels":{name:"Walking, cycling, etc., tunnels",collapsed:!0},"Terrain, land":{name:"Terrain, land",collapsed:!0},"Road network, tunnels-case":{name:"Road network, tunnels-case",collapsed:!0},"Walking, cycling, etc., walking-cycling-labels":{name:"Walking, cycling, etc., walking-cycling-labels",collapsed:!0},"Walking, cycling, etc., surface":{name:"Walking, cycling, etc., surface",collapsed:!0},"Road network, surface-icons":{name:"Road network, surface-icons",collapsed:!0},"Land & water, water":{name:"Land & water, water",collapsed:!1}}},center:[104.01743114258029,17.078999978347557],zoom:1.9133216316430233,bearing:0,pitch:0,lights:[],fog:{range:[.5,10]},sources:{composite:{url:"mapbox://mapbox.mapbox-streets-v8,mapbox.mapbox-terrain-v2,mapbox.mapbox-bathymetry-v2,mapbox.country-boundaries-v1,neatchenheng.d44z21eg,neatchenheng.82kqbc1q,neatchenheng.a4ifbysm,neatchenheng.27issko0,neatchenheng.9uwc9x7l,neatchenheng.7y3kpvvv,neatchenheng.dlkkohie",type:"vector"}},sprite:"mapbox://sprites/neatchenheng/cmd894dwn036m01rf7anc0k0d/bph0p8ithotzwly53az7lwdmv",glyphs:"mapbox://fonts/mapbox/{fontstack}/{range}.pbf",projection:{name:"equirectangular"},layers:[{id:"land",type:"background",layout:{},paint:{"background-color":"#e9ebed"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},maxzoom:12,type:"fill",source:"composite",id:"landcover",paint:{"fill-color":["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","crop","hsla(68, 55%, 70%, 0.6)","grass","hsla(98, 50%, 74%, 0.6)","snow","hsl(205, 45%, 95%)","hsl(98, 48%, 67%)"],"fill-opacity":["interpolate",["exponential",1.5],["zoom"],8,.8,12,0],"fill-antialias":!1},"source-layer":"landcover"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"fill",source:"composite",id:"national-park",paint:{"fill-color":"hsl(98, 38%, 68%)","fill-opacity":["interpolate",["linear"],["zoom"],5,0,6,.6,12,.2]},"source-layer":"landuse_overlay"},{minzoom:9,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"line",source:"composite",id:"national-park_tint-band",paint:{"line-color":"hsl(98, 38%, 68%)","line-width":["interpolate",["exponential",1.5],["zoom"],9,1,14,8],"line-blur":["interpolate",["exponential",1.5],["zoom"],9,1,14,8]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["all",[">=",["to-number",["get","sizerank"]],0],["match",["get","class"],["agriculture","wood","grass","scrub","glacier","pitch","sand"],["step",["zoom"],!1,11,!0],"residential",["step",["zoom"],!0,10,!1],["park","airport"],["step",["zoom"],!1,8,["case",["==",["get","sizerank"],1],!0,!1],10,!0],["facility","industrial"],["step",["zoom"],!1,12,!0],"rock",["step",["zoom"],!1,11,!0],"cemetery",["step",["zoom"],!1,11,!0],"school",["step",["zoom"],!1,11,!0],"hospital",["step",["zoom"],!1,11,!0],"commercial_area",["step",["zoom"],!1,11,!0],!1],["<=",["-",["to-number",["get","sizerank"]],["interpolate",["exponential",1.5],["zoom"],12,0,18,14]],14]],type:"fill",source:"composite",id:"landuse",paint:{"fill-color":["interpolate",["linear"],["zoom"],15,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsl(60, 0%, 85%)","school","hsl(40, 45%, 78%)","commercial_area","hsl(55, 45%, 85%)","residential","hsl(60, 7%, 87%)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"],16,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsla(60, 0%, 85%, 0.5)","school","hsl(40, 45%, 78%)","commercial_area","hsla(55, 45%, 85%, 0.5)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"]],"fill-opacity":["interpolate",["linear"],["zoom"],8,["match",["get","class"],"residential",.8,.2],10,["match",["get","class"],"residential",0,1]],"fill-antialias":!1},"source-layer":"landuse"},{minzoom:15,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"pitch"],type:"line",source:"composite",id:"pitch-outline",paint:{"line-color":"hsl(0, 0%, 69%)"},"source-layer":"landuse"},{id:"waterway-shadow",type:"line",source:"composite","source-layer":"waterway",minzoom:10,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"],visibility:"none"},paint:{"line-color":"hsl(224, 79%, 69%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"line-translate-anchor":"viewport","line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water-shadow",type:"fill",source:"composite","source-layer":"water",minzoom:10,layout:{visibility:"none"},paint:{"fill-color":"hsl(224, 79%, 69%)","fill-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"fill-translate-anchor":"viewport"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"waterway",type:"line",source:"composite","source-layer":"waterway",minzoom:8,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"]},paint:{"line-color":"hsl(198, 100%, 37%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water",type:"fill",source:"composite","source-layer":"water",layout:{},paint:{"fill-color":"hsl(215, 92%, 81%)"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},maxzoom:8,type:"fill",source:"composite",id:"water-depth",paint:{"fill-antialias":!1,"fill-color":["interpolate",["linear"],["zoom"],6,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0.35)",200,"hsla(205, 75%, 63%, 0.35)",7e3,"hsla(205, 75%, 56%, 0.35)"],8,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0)",200,"hsla(205, 75%, 63%, 0)",7e3,"hsla(205, 75%, 53%, 0)"]]},"source-layer":"depth"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,.25,10.5,.15]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland-pattern",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,0,10.5,1],"fill-pattern":"wetland","fill-translate-anchor":"viewport"},"source-layer":"landuse_overlay"},{minzoom:13,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"Polygon"]],type:"fill",source:"composite",id:"land-structure-polygon",paint:{"fill-color":"hsl(0, 0%, 69%)"},"source-layer":"structure"},{minzoom:13,layout:{"line-cap":"square",visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"LineString"]],type:"line",source:"composite",id:"land-structure-line",paint:{"line-width":["interpolate",["exponential",1.99],["zoom"],14,.75,20,40],"line-color":"hsl(60, 20%, 85%)"},"source-layer":"structure"},{id:"empty-layer-0",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-1",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"country-boundaries",type:"fill",source:"composite","source-layer":"country_boundaries",paint:{"fill-color":"rgb(200, 200, 200)"},layout:{visibility:"none"}},{id:"empty-layer-2",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-3",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-4",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"water-outline2",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgb(150, 150, 150)"},layout:{visibility:"none"},source:"composite","source-layer":"water"},{id:"water-outline",type:"line",paint:{"line-color":"hsl(0, 0%, 70%)","line-width":["interpolate",["linear"],["zoom"],0,1.5,4,1]},source:"composite","source-layer":"water"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-bg",paint:{"line-width":["interpolate",["linear"],["zoom"],3,4,12,8],"line-color":"rgb(173, 169, 170)","line-opacity":["interpolate",["linear"],["zoom"],3,0,4,.5],"line-blur":["interpolate",["linear"],["zoom"],3,0,12,2]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","disputed"],"false"],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary",paint:{"line-color":"rgb(143, 143, 143)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[2,0]],7,["literal",[2,2,6,2]]]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","disputed"],"true"],["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-disputed",paint:{"line-color":"rgb(95, 93, 94)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[3,2,5]],7,["literal",[2,1.5]]]},"source-layer":"admin"},{minzoom:13,layout:{"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-max-angle":30,"symbol-spacing":["interpolate",["linear",1],["zoom"],15,250,17,400],"text-size":["interpolate",["linear"],["zoom"],13,12,18,18],"symbol-placement":"line","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["canal","river","stream","disputed_canal","disputed_river","disputed_stream"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"waterway-label",paint:{"text-color":"hsl(205, 43%, 90%)","text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"text-max-angle":30,"text-field":["coalesce",["get","name_en"],["get","name"]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport"},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["glacier","landform","disputed_glacier","disputed_landform"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"natural-line-label",paint:{"text-halo-width":.5,"text-halo-color":"hsl(60, 17%, 84%)","text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"icon-image":["case",["has","maki_beta"],["coalesce",["image",["get","maki_beta"]],["image",["get","maki"]]],["image",["get","maki"]]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-offset":["step",["zoom"],["step",["get","sizerank"],["literal",[0,0]],5,["literal",[0,.8]]],17,["step",["get","sizerank"],["literal",[0,0]],13,["literal",[0,.8]]]],"text-anchor":["step",["zoom"],["step",["get","sizerank"],"center",5,"top"],17,["step",["get","sizerank"],"center",13,"top"]],"text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["dock","glacier","landform","water_feature","wetland","disputed_dock","disputed_glacier","disputed_landform","disputed_water_feature","disputed_wetland"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"natural-point-label",paint:{"icon-opacity":["step",["zoom"],["step",["get","sizerank"],0,5,1],17,["step",["get","sizerank"],0,13,1]],"text-halo-color":"hsl(60, 20%, 98%)","text-halo-width":.5,"text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-max-angle":30,"text-letter-spacing":["match",["get","class"],"ocean",.25,["sea","bay"],.15,0],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"water-line-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-line-height":1.3,"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":["match",["get","class"],"ocean",.25,["bay","sea"],.15,.01],"text-max-width":["match",["get","class"],"ocean",4,"sea",5,["bay","water"],7,10]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"water-point-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:10,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-transform":"uppercase","text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-letter-spacing":["match",["get","type"],"suburb",.15,.05],"text-max-width":7,"text-padding":3,"text-size":["interpolate",["cubic-bezier",.5,0,1,1],["zoom"],11,["match",["get","type"],"suburb",11,10.5],15,["match",["get","type"],"suburb",15,14]],visibility:"none"},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["match",["get","class"],["settlement_subdivision","disputed_settlement_subdivision"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],3],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-subdivision-label",paint:{"text-halo-color":"hsla(60, 25%, 100%, 0.75)","text-halo-width":1,"text-color":"hsl(230, 29%, 36%)","text-halo-blur":.5},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],11,9,10],6,["step",["get","symbolrank"],14,9,12,12,10],8,["step",["get","symbolrank"],16,9,14,12,12,15,10],13,["step",["get","symbolrank"],22,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-justify":"auto",visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:13,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],[">",["get","symbolrank"],6],4,[">=",["get","symbolrank"],7],6,[">=",["get","symbolrank"],8],7,[">=",["get","symbolrank"],10],10,[">=",["get","symbolrank"],11],11,[">=",["get","symbolrank"],13],12,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-minor-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],13,6,11],6,["step",["get","symbolrank"],18,6,16,7,14],8,["step",["get","symbolrank"],20,9,16,10,14],15,["step",["get","symbolrank"],24,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],8,"center"],visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],!1,2,["<=",["get","symbolrank"],6],4,["<",["get","symbolrank"],7],6,["<",["get","symbolrank"],8],7,["<",["get","symbolrank"],10],10,["<",["get","symbolrank"],11],11,["<",["get","symbolrank"],13],12,["<",["get","symbolrank"],15],13,[">=",["get","symbolrank"],11],14,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-major-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:3,layout:{"text-size":["interpolate",["cubic-bezier",.85,.7,.65,1],["zoom"],4,["step",["get","symbolrank"],9,6,8,7,7],9,["step",["get","symbolrank"],21,6,16,7,14]],"text-transform":"uppercase","text-font":["DIN Pro Bold","Arial Unicode MS Bold"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":.15,"text-max-width":6},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:9,filter:["all",["match",["get","class"],["state","disputed_state"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"state-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-opacity":.5},"source-layer":"place_label"},{minzoom:1,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-radial-offset":["step",["zoom"],.6,8,0],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],7,"auto"],"text-size":["interpolate",["cubic-bezier",.2,0,.7,1],["zoom"],1,["step",["get","symbolrank"],12.100000000000001,4,9.9,5,8.8],9,["step",["get","symbolrank"],24.200000000000003,4,20.900000000000002,5,18.700000000000003]]},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:10,filter:["all",["match",["get","class"],["country","disputed_country"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"country-label",paint:{"icon-opacity":["step",["zoom"],["case",["has","text_anchor"],1,0],7,0],"text-color":"hsl(0, 0.00%, 13.70%)","text-halo-color":["interpolate",["linear"],["zoom"],2,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.25},"source-layer":"place_label"},{minzoom:.75,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-size":["interpolate",["exponential",.5],["zoom"],0,10,2.5,15],"text-transform":"uppercase","text-letter-spacing":.05},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:3,filter:["==",["get","class"],"continent"],type:"symbol",source:"composite",id:"continent-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":["interpolate",["linear"],["zoom"],0,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.5,"text-opacity":["interpolate",["linear"],["zoom"],0,.8,1.5,.5,2.5,0]},"source-layer":"natural_label"},{id:"world-12nm-v4-20231025",minzoom:3,type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2],"line-translate":[0,0]},source:"composite","source-layer":"eez_12nm_new1-6jzkww",layout:{"line-join":"round",visibility:"none"}},{id:"china-taiwan",type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2]},layout:{"line-join":"round",visibility:"none"},source:"composite","source-layer":"eez-d4udtm"},{id:"ne-10m-outline",type:"line",paint:{"line-color":"hsl(172, 0%, 33%)"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv",layout:{visibility:"none"}},{id:"ne-10m-label",type:"symbol",paint:{"text-halo-color":"hsl(0, 0%, 100%)","text-halo-width":1,"text-halo-blur":1},layout:{"text-field":["to-string",["get","name"]],"text-size":12,visibility:"none"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv"},{id:"china-route-line",type:"line",paint:{"line-color":"rgba(119, 239, 157, 1)","line-width":2},source:"composite","source-layer":"china_route-bdtx5d",layout:{visibility:"none"}},{id:"china-route-fill",type:"fill",paint:{"fill-color":"rgba(119, 239, 157, 1)","fill-opacity":.2},source:"composite","source-layer":"china_route-bdtx5d",filter:["match",["get","featureType"],["route"],!0,!1],layout:{visibility:"none"}},{id:"china-route-label",type:"symbol",paint:{"text-color":"rgba(0, 0, 0, 1)"},source:"composite","source-layer":"china_route-bdtx5d",layout:{"text-field":["to-string",["get","RouteName"]],"text-size":10,"text-offset":[0,1.6],visibility:"none"}},{id:"ice-area-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(199, 239, 236, 0.7)"},source:"composite","source-layer":"ICE_AREA-6oqazd",layout:{visibility:"none"}},{id:"ice-area-line",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgba(199, 239, 236, 1)"},layout:{visibility:"none"},source:"composite","source-layer":"ICE_AREA-6oqazd"},{id:"tide-stations",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)","text-opacity":["step",["zoom"],0,4,1]},layout:{visibility:"none","text-field":["to-string",["get","Location_EN"]],"text-size":10,"icon-image":"tide","icon-size":1,"icon-offset":[0,-13],"text-offset":[0,1.6],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"]},source:"composite","source-layer":"tide_station_cn-8xvt91"},{id:"loadlines-label",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)"},layout:{"text-field":["to-string",["get","name"]],"text-size":10,"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],visibility:"none","text-offset":[0,1]},source:"composite","source-layer":"loadlines-b6mgr8"},{id:"loadlines-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":["match",["get","val"],["LLGreen"],"rgba(164, 214, 217, 0.6)",["LLBlue"],"rgba(53, 121, 194, 0.6)",["LLRed"],"rgba(217, 150, 151, 0.6)",["LLSUMMER"],"rgba(111, 110, 212, 0.6)","rgba(255, 255, 255, 0.6)"],"fill-outline-color":"rgba(255, 255, 255, 0.3)"},layout:{visibility:"none"},source:"composite","source-layer":"loadlines-b6mgr8"}],created:"2025-07-18T03:20:31.079Z",modified:"2025-07-31T03:57:21.238Z",id:"cmd894dwn036m01rf7anc0k0d",owner:"neatchenheng",visibility:"private",protected:!1,draft:!1},zoom:this.zoom,center:this.tropicals.center||[120,30],preserveDrawingBuffer:!0,projection:"mercator",attributionControl:!1,dragPan:!1});o.on("load",()=>{this.map=o,this.map.scrollZoom.disable(),this.handleSetCenterAndBbox(),this.handleRenderTropcals(),this.handleDrawHurricaneMarker()})},handleSetCenterAndBbox(){var c,d,i;const o=[];(i=(d=(c=this.tropicals)==null?void 0:c.data)==null?void 0:d.features)==null||i.forEach(m=>{var p,y,h,f;((p=m==null?void 0:m.properties)==null?void 0:p.type)==="forecast"&&!m.properties.disabled&&(((y=m==null?void 0:m.geometry)==null?void 0:y.type)==="LineString"?o.push(...(h=m==null?void 0:m.geometry)==null?void 0:h.coordinates):o.push((f=m==null?void 0:m.geometry)==null?void 0:f.coordinates))});const a=Z.LaneHelper.calculateCenter([o]);this.map.setCenter(a);let t=Z.LaneHelper.calculateBBox([o]);this.map.fitScreenCoordinates(this.map.project([t[0]-10,t[1]-10]),this.map.project([t[2]+10,t[3]+10]),this.map.getBearing()),this.map.addSource(this.bboxSource,{type:"geojson",data:{type:"Feature",geometry:{type:"LineString",coordinates:[[t[0]-5,t[1]-5],[t[2]+5,t[1]-5],[t[2]+5,t[3]+5],[t[0]-5,t[3]+5],[t[0]-5,t[1]-5]]}}}),this.map.addLayer({id:this.bboxLayer,type:"line",source:this.bboxSource,layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"rgba(0,0,0,0.6)","line-width":1,"line-opacity":1,"line-dasharray":[2,2]}})},handleRenderTropcals(){var o,a,t,c,d;if(this.tropicals){const i=new Date().valueOf();let m=0,p=0;(o=this.map)!=null&&o.getSource(this.source)?((t=this.map)==null||t.getSource(this.source).setData((a=this.tropicals)!=null&&a.active?this.tropicals.data:this.empty),p=new Date().valueOf()-(i+m),console.log("[tropicals] update elapsed: ",p,", total: ",m+=p)):(this.map.addSource(this.source,{type:"geojson",data:(c=this.tropicals)!=null&&c.active?(d=this.tropicals)==null?void 0:d.data:this.empty}),this.map.addLayer({id:this.historyLayer,type:"line",source:this.source,filter:["all",["==","$type","LineString"],["==","type","history"],["!=","disabled",!0]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#000","line-width":4,"line-opacity":.5}}),this.map.addLayer({id:this.forecastLayer,type:"line",source:this.source,filter:["all",["==","$type","LineString"],["==","type","forecast"],["!=","disabled",!0]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":["match",["get","model"],"cma","#e2ea03","jma","#01d2b7","ecmwf","#f582f2","ukm","#f5bb47","noaa-at","#9758fb","noaa-ep","#9758fb","#fff"],"line-width":3,"line-opacity":1,"line-dasharray":[1,2]}}))}},handleDrawHurricaneMarker(){var c,d,i,m,p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R;const o=Z.TropicalHelper.interpolate(this.tropicals,1),a=JSON.parse(JSON.stringify(o)),t=[];if(a.forEach(E=>{var x,H,l;(x=E.properties)!=null&&x.name&&!t.includes((H=E.properties)==null?void 0:H.name)&&t.push((l=E.properties)==null?void 0:l.name)}),t.forEach(E=>{var l;const H=(l=a.filter(G=>{var r;return((r=G.properties)==null?void 0:r.name)===E})[0])==null?void 0:l.properties.model;a.map((G,r)=>{var U,F;return((U=G.properties)==null?void 0:U.name)===E&&(G.properties.disabled=((F=G.properties)==null?void 0:F.model)!==H),G})}),this.interpolateData=JSON.parse(JSON.stringify(a)),(c=this.interpolateMarkers)==null||c.forEach(E=>E==null?void 0:E.remove()),this.interpolateMarkers=[],(d=this.interpolateData)!=null&&d.length&&this.tropicals.active){const E=this.interpolateData.filter(x=>x.properties.date===this.ts&&!x.properties.disabled);this.interpolateData.forEach(x=>{});for(const x of E)if(!x.properties.disabled){let H="#f44336";((m=(i=x.properties)==null?void 0:i.wind)==null?void 0:m.kts)<32||!((y=(p=x.properties)==null?void 0:p.wind)!=null&&y.kts)?H="#03f869":((f=(h=x.properties)==null?void 0:h.wind)==null?void 0:f.kts)>=32&&((w=(k=x.properties)==null?void 0:k.wind)==null?void 0:w.kts)<47?H="#f2f202":((L=(B=x.properties)==null?void 0:B.wind)==null?void 0:L.kts)>=47&&((C=(V=x.properties)==null?void 0:V.wind)==null?void 0:C.kts)<63?H="#ff9100":((D=(z=x.properties)==null?void 0:z.wind)==null?void 0:D.kts)>=63&&((A=(_=x.properties)==null?void 0:_.wind)==null?void 0:A.kts)<79?H="#f44336":((b=(W=x.properties)==null?void 0:W.wind)==null?void 0:b.kts)>=79&&((S=(P=x.properties)==null?void 0:P.wind)==null?void 0:S.kts)<94?H="#c604a4":((R=(v=x.properties)==null?void 0:v.wind)==null?void 0:R.kts)>=94?H="#6b05bb":H="#f44336";const l=`<svg t="1719918955501"
188
+ </div>`),q}}},legend:{show:!0,top:"10px",right:"4%",itemWidth:40,textStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"}},xAxis:{show:!0,left:0,right:0,top:"50%",height:"50%",type:"category",boundaryGap:!0,data:(G=this.reportData)==null?void 0:G.xDates,axisLabel:{show:!0,fontSize:12,color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0, 0, 0, 0.7)"},axisLine:{show:!0},axisTick:{show:!0,inside:!0,lineStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.4)":"rgba(0,0,0,0.4)"}},z:1,zlevel:1},yAxis:[{type:"value",name:this.locale==="zhHans"?"风速 ( kts ) ":"Wind speed ( kts ) ",show:!0,min:h,max:f,interval:k,splitNumber:5,nameRotate:90,nameLocation:"middle",nameGap:25,nameTextStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},axisLabel:{show:!0,fontSize:10,color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},splitLine:{show:!0,lineStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.1)":"rgba(0,0,0,0.1)"}},z:0,zlevel:0},{type:"value",name:this.locale==="zhHans"?"降水量 ( mm ) ":"Precipitation ( mm ) ",show:!0,min:L,max:V,interval:C,splitNumber:5,nameRotate:90,nameLocation:"middle",nameGap:30,nameTextStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},axisLabel:{show:!0,fontSize:10,color:this.theme==="dark"?"rgba(255, 255, 255, 0.7)":"rgba(0,0,0,0.7)"},splitLine:{show:!0,lineStyle:{color:this.theme==="dark"?"rgba(255, 255, 255, 0.1)":"rgba(0,0,0,0.1)"}},z:1,zlevel:0}],series:i.filter(r=>r.show)};this.$nextTick(()=>{let r;document.getElementById("wind-precip-echart")&&(r=j.init(document.getElementById("wind-precip-echart")),r.setOption(z))})},disposeEcharts(){document.getElementById("temperature-echart")&&j.dispose(document.getElementById("temperature-echart")),document.getElementById("wind-precip-echart")&&j.dispose(document.getElementById("wind-precip-echart"))}}},Fs={class:"idm-spot-seasonal-report"},Us={class:"row"},qs={class:"col",style:{width:"54%"}},Zs={key:0,style:{"margin-left":"8px"}},Xs={key:1,style:{"margin-left":"8px"}},Js={class:"col",style:{width:"42%"}},Qs={style:{"margin-left":"8px"}},Ks={class:"row"},el={class:"col",style:{width:"54%"}},tl={style:{"margin-left":"8px"}},al={class:"content-box"},ol={class:"summary-section"},il={class:"title",style:{"margin-left":"5px"}},sl={class:"info-block"},ll={class:"text"},rl={class:"text"},nl={class:"text"},dl={class:"text"},cl={class:"text"},ml={class:"text"},hl={class:"text"},pl={class:"text"},gl={class:"text"},yl={class:"text"},fl={class:"text"},bl={class:"seasonal-weather-section",style:{}},ul={key:0,id:"temperature-echart"},xl={key:1,id:"wind-precip-echart"};function wl(o,a,t,c,d,i){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P;const m=e.resolveComponent("IdmLoading");return e.openBlock(),e.createElementBlock("div",Fs,[(p=t.reportData)!=null&&p.showSummary?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["summary-info-box",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",Us,[e.createElementVNode("div",qs,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"位置":"Position")+":",3),(y=t.reportData)!=null&&y.portName?(e.openBlock(),e.createElementBlock("span",Zs,e.toDisplayString((h=t.reportData)==null?void 0:h.portName)+" "+e.toDisplayString(`[${i.computeLat(t.reportData.lat)}, ${i.computeLng(t.reportData.lng)}]`),1)):(e.openBlock(),e.createElementBlock("span",Xs,e.toDisplayString(`${i.computeLat(t.reportData.lat)} , ${i.computeLng(t.reportData.lng)}`),1))]),e.createElementVNode("div",Js,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"预报月份":"Forecast Month")+":",3),e.createElementVNode("span",Qs,e.toDisplayString((f=t.reportData)==null?void 0:f.forecastMonth),1)])]),e.createElementVNode("div",Ks,[e.createElementVNode("div",el,[e.createElementVNode("span",{class:e.normalizeClass(["label label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"时区":"Timezone")+":",3),e.createElementVNode("span",tl,"UTC "+e.toDisplayString((k=t.reportData)==null?void 0:k.positionOffset),1)])])],2)):e.createCommentVNode("",!0),e.createElementVNode("div",al,[e.createElementVNode("div",ol,[e.createElementVNode("div",il,e.toDisplayString(t.locale==="zhHans"?"总结":"Summary"),1),e.createElementVNode("div",sl,[e.createElementVNode("div",{class:e.normalizeClass(["block",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",{class:e.normalizeClass(["label primary-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"温度":"Temperature"),3),e.createElementVNode("div",{class:e.normalizeClass(["divider",t.theme==="dark"?"dark":"light"])},null,2),e.createElementVNode("div",ll,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"平均最高温度:":"Avg High Temp:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.minHighTemp)+" to "+e.toDisplayString(t.reportData.maxHighTemp)+" °C",1)]),e.createElementVNode("div",rl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"平均最低温度:":"Avg Low Temp:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.minLowTemp)+" to "+e.toDisplayString(t.reportData.maxLowTemp)+" °C",1)]),e.createElementVNode("div",nl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"最热日期:":"Hottest Day:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.hottestDay),1)]),e.createElementVNode("div",dl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"最冷日期:":"Coldest Day:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.coldestDay),1)])],2),e.createElementVNode("div",{class:e.normalizeClass(["block",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",{class:e.normalizeClass(["label primary-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"降水":"Precipitation"),3),e.createElementVNode("div",{class:e.normalizeClass(["divider",t.theme==="dark"?"dark":"light"])},null,2),e.createElementVNode("div",cl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"小雨:":"Light (<10mm):"),3),e.createTextVNode(" "+e.toDisplayString((L=(B=(w=t.reportData)==null?void 0:w.precip)==null?void 0:B.filter(S=>S<10))==null?void 0:L.length)+" days",1)]),e.createElementVNode("div",ml,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"中雨:":"Moderate (<=24.9mm):"),3),e.createTextVNode(" "+e.toDisplayString((z=(C=(V=t.reportData)==null?void 0:V.precip)==null?void 0:C.filter(S=>S>=10&&S<=24.9))==null?void 0:z.length)+" days",1)]),e.createElementVNode("div",hl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"大雨:":"Heavy (<=49.9mm):"),3),e.createTextVNode(" "+e.toDisplayString((A=(_=(D=t.reportData)==null?void 0:D.precip)==null?void 0:_.filter(S=>S>24.9&&S<=49.9))==null?void 0:A.length)+" days",1)]),e.createElementVNode("div",pl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暴雨:":"Rainstorm (>49.9mm):"),3),e.createTextVNode(" "+e.toDisplayString((P=(b=(W=t.reportData)==null?void 0:W.precip)==null?void 0:b.filter(S=>S>49.9))==null?void 0:P.length)+" days",1)])],2),e.createElementVNode("div",{class:e.normalizeClass(["block",t.theme==="dark"?"dark":"light"])},[e.createElementVNode("div",{class:e.normalizeClass(["label primary-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"风":"Wind"),3),e.createElementVNode("div",{class:e.normalizeClass(["divider",t.theme==="dark"?"dark":"light"])},null,2),e.createElementVNode("div",gl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"平均风速:":"Mean Wind:"),3),e.createTextVNode(" "+e.toDisplayString(i.roundPrecision(t.reportData.meanWind,1))+" kts",1)]),e.createElementVNode("div",yl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"最强风日:":"Windiest Day:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.windiestDay)+" ( "+e.toDisplayString(t.reportData.maxWindSpeed)+"kts )",1)]),e.createElementVNode("div",fl,[e.createElementVNode("span",{class:e.normalizeClass(["label-color",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"主要风向:":"Dominant Wind Dir:"),3),e.createTextVNode(" "+e.toDisplayString(t.reportData.dominantWind),1)])],2)])]),e.createElementVNode("div",bl,[t.loading?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",ul)),t.loading?t.loading?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},[e.createVNode(m,{loading:t.loading},null,8,["loading"])],2)):(e.openBlock(),e.createElementBlock("div",{key:3,class:e.normalizeClass(["loading-box",t.theme==="dark"?"dark":"light"])},e.toDisplayString(t.locale==="zhHans"?"暂无数据":"No Data"),3)):(e.openBlock(),e.createElementBlock("div",xl))])])])}const Lt=tt(js,[["render",wl],["__scopeId","data-v-c8cabdd2"]]),kl={install(o){o.component("IdmForecast",St),o.component("IdmHistorical",Et),o.component("IdmSeasonal",Lt)}},sr="",lr="",zl={props:{tropicals:{type:Object,default:()=>({})},ts:{type:String,default:()=>""},container:{type:String,default:()=>""},zoom:{type:Number,default:()=>1}},components:{},data(){return{map:void 0,source:"tropicals-source",bboxSource:"tropicals-bbox-source",historyLayer:"tropicals-history-layer",forecastLayer:"tropicals-forecast-layer",bboxLayer:"tropicals-bbox-layer",interpolateData:void 0}},mounted(){this.initMap()},methods:{async initMap(){dt.accessToken="pk.eyJ1IjoibmVhdGNoZW5oZW5nIiwiYSI6ImNsdXM3cnBmODBsemgycW1vaXc1bjV6bXMifQ.w6fqHGRbhNhLvm0LnX4ZVw";const o=new dt.Map({container:this.container,style:{version:8,name:"light",metadata:{"mapbox:print":{width:8.5,height:11,units:"in",format:"png",resolution:300},"mapbox:type":"default","mapbox:trackposition":!0,"mapbox:autocomposite":!0,"mapbox:sdk-support":{android:"11.0.0",ios:"11.0.0",js:"3.0.0"},"mapbox:origin":"outdoors-v12","mapbox:groups":{"Terrain, terrain-labels":{name:"Terrain, terrain-labels",collapsed:!0},"Administrative boundaries, admin":{name:"Administrative boundaries, admin",collapsed:!0},"Land & water, built":{name:"Land & water, built",collapsed:!0},"Terrain, surface":{name:"Terrain, surface",collapsed:!0},"Land & water, land":{name:"Land & water, land",collapsed:!1},"Natural features, natural-labels":{name:"Natural features, natural-labels",collapsed:!0},e9bb8e77353431519f7918998e9079d9:{name:"Group",collapsed:!1},"Walking, cycling, etc., barriers-bridges":{name:"Walking, cycling, etc., barriers-bridges",collapsed:!0},"Place labels, place-labels":{name:"Place labels, place-labels",collapsed:!1},"Transit, ferries":{name:"Transit, ferries",collapsed:!0},"Transit, elevated":{name:"Transit, elevated",collapsed:!0},"Walking, cycling, etc., tunnels":{name:"Walking, cycling, etc., tunnels",collapsed:!0},"Terrain, land":{name:"Terrain, land",collapsed:!0},"Road network, tunnels-case":{name:"Road network, tunnels-case",collapsed:!0},"Walking, cycling, etc., walking-cycling-labels":{name:"Walking, cycling, etc., walking-cycling-labels",collapsed:!0},"Walking, cycling, etc., surface":{name:"Walking, cycling, etc., surface",collapsed:!0},"Road network, surface-icons":{name:"Road network, surface-icons",collapsed:!0},"Land & water, water":{name:"Land & water, water",collapsed:!1}}},center:[104.01743114258029,17.078999978347557],zoom:1.9133216316430233,bearing:0,pitch:0,lights:[],fog:{range:[.5,10]},sources:{composite:{url:"mapbox://mapbox.mapbox-streets-v8,mapbox.mapbox-terrain-v2,mapbox.mapbox-bathymetry-v2,mapbox.country-boundaries-v1,neatchenheng.d44z21eg,neatchenheng.82kqbc1q,neatchenheng.a4ifbysm,neatchenheng.27issko0,neatchenheng.9uwc9x7l,neatchenheng.7y3kpvvv,neatchenheng.dlkkohie",type:"vector"}},sprite:"mapbox://sprites/neatchenheng/cmd894dwn036m01rf7anc0k0d/bph0p8ithotzwly53az7lwdmv",glyphs:"mapbox://fonts/mapbox/{fontstack}/{range}.pbf",projection:{name:"equirectangular"},layers:[{id:"land",type:"background",layout:{},paint:{"background-color":"#e9ebed"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},maxzoom:12,type:"fill",source:"composite",id:"landcover",paint:{"fill-color":["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","crop","hsla(68, 55%, 70%, 0.6)","grass","hsla(98, 50%, 74%, 0.6)","snow","hsl(205, 45%, 95%)","hsl(98, 48%, 67%)"],"fill-opacity":["interpolate",["exponential",1.5],["zoom"],8,.8,12,0],"fill-antialias":!1},"source-layer":"landcover"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"fill",source:"composite",id:"national-park",paint:{"fill-color":"hsl(98, 38%, 68%)","fill-opacity":["interpolate",["linear"],["zoom"],5,0,6,.6,12,.2]},"source-layer":"landuse_overlay"},{minzoom:9,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"line",source:"composite",id:"national-park_tint-band",paint:{"line-color":"hsl(98, 38%, 68%)","line-width":["interpolate",["exponential",1.5],["zoom"],9,1,14,8],"line-blur":["interpolate",["exponential",1.5],["zoom"],9,1,14,8]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["all",[">=",["to-number",["get","sizerank"]],0],["match",["get","class"],["agriculture","wood","grass","scrub","glacier","pitch","sand"],["step",["zoom"],!1,11,!0],"residential",["step",["zoom"],!0,10,!1],["park","airport"],["step",["zoom"],!1,8,["case",["==",["get","sizerank"],1],!0,!1],10,!0],["facility","industrial"],["step",["zoom"],!1,12,!0],"rock",["step",["zoom"],!1,11,!0],"cemetery",["step",["zoom"],!1,11,!0],"school",["step",["zoom"],!1,11,!0],"hospital",["step",["zoom"],!1,11,!0],"commercial_area",["step",["zoom"],!1,11,!0],!1],["<=",["-",["to-number",["get","sizerank"]],["interpolate",["exponential",1.5],["zoom"],12,0,18,14]],14]],type:"fill",source:"composite",id:"landuse",paint:{"fill-color":["interpolate",["linear"],["zoom"],15,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsl(60, 0%, 85%)","school","hsl(40, 45%, 78%)","commercial_area","hsl(55, 45%, 85%)","residential","hsl(60, 7%, 87%)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"],16,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsla(60, 0%, 85%, 0.5)","school","hsl(40, 45%, 78%)","commercial_area","hsla(55, 45%, 85%, 0.5)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"]],"fill-opacity":["interpolate",["linear"],["zoom"],8,["match",["get","class"],"residential",.8,.2],10,["match",["get","class"],"residential",0,1]],"fill-antialias":!1},"source-layer":"landuse"},{minzoom:15,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"pitch"],type:"line",source:"composite",id:"pitch-outline",paint:{"line-color":"hsl(0, 0%, 69%)"},"source-layer":"landuse"},{id:"waterway-shadow",type:"line",source:"composite","source-layer":"waterway",minzoom:10,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"],visibility:"none"},paint:{"line-color":"hsl(224, 79%, 69%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"line-translate-anchor":"viewport","line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water-shadow",type:"fill",source:"composite","source-layer":"water",minzoom:10,layout:{visibility:"none"},paint:{"fill-color":"hsl(224, 79%, 69%)","fill-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"fill-translate-anchor":"viewport"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"waterway",type:"line",source:"composite","source-layer":"waterway",minzoom:8,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"]},paint:{"line-color":"hsl(198, 100%, 37%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water",type:"fill",source:"composite","source-layer":"water",layout:{},paint:{"fill-color":"hsl(215, 92%, 81%)"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},maxzoom:8,type:"fill",source:"composite",id:"water-depth",paint:{"fill-antialias":!1,"fill-color":["interpolate",["linear"],["zoom"],6,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0.35)",200,"hsla(205, 75%, 63%, 0.35)",7e3,"hsla(205, 75%, 56%, 0.35)"],8,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0)",200,"hsla(205, 75%, 63%, 0)",7e3,"hsla(205, 75%, 53%, 0)"]]},"source-layer":"depth"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,.25,10.5,.15]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland-pattern",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,0,10.5,1],"fill-pattern":"wetland","fill-translate-anchor":"viewport"},"source-layer":"landuse_overlay"},{minzoom:13,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"Polygon"]],type:"fill",source:"composite",id:"land-structure-polygon",paint:{"fill-color":"hsl(0, 0%, 69%)"},"source-layer":"structure"},{minzoom:13,layout:{"line-cap":"square",visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"LineString"]],type:"line",source:"composite",id:"land-structure-line",paint:{"line-width":["interpolate",["exponential",1.99],["zoom"],14,.75,20,40],"line-color":"hsl(60, 20%, 85%)"},"source-layer":"structure"},{id:"empty-layer-0",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-1",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"country-boundaries",type:"fill",source:"composite","source-layer":"country_boundaries",paint:{"fill-color":"rgb(200, 200, 200)"},layout:{visibility:"none"}},{id:"empty-layer-2",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-3",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-4",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"water-outline2",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgb(150, 150, 150)"},layout:{visibility:"none"},source:"composite","source-layer":"water"},{id:"water-outline",type:"line",paint:{"line-color":"hsl(0, 0%, 70%)","line-width":["interpolate",["linear"],["zoom"],0,1.5,4,1]},source:"composite","source-layer":"water"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-bg",paint:{"line-width":["interpolate",["linear"],["zoom"],3,4,12,8],"line-color":"rgb(173, 169, 170)","line-opacity":["interpolate",["linear"],["zoom"],3,0,4,.5],"line-blur":["interpolate",["linear"],["zoom"],3,0,12,2]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","disputed"],"false"],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary",paint:{"line-color":"rgb(143, 143, 143)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[2,0]],7,["literal",[2,2,6,2]]]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","disputed"],"true"],["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-disputed",paint:{"line-color":"rgb(95, 93, 94)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[3,2,5]],7,["literal",[2,1.5]]]},"source-layer":"admin"},{minzoom:13,layout:{"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-max-angle":30,"symbol-spacing":["interpolate",["linear",1],["zoom"],15,250,17,400],"text-size":["interpolate",["linear"],["zoom"],13,12,18,18],"symbol-placement":"line","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["canal","river","stream","disputed_canal","disputed_river","disputed_stream"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"waterway-label",paint:{"text-color":"hsl(205, 43%, 90%)","text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"text-max-angle":30,"text-field":["coalesce",["get","name_en"],["get","name"]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport"},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["glacier","landform","disputed_glacier","disputed_landform"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"natural-line-label",paint:{"text-halo-width":.5,"text-halo-color":"hsl(60, 17%, 84%)","text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"icon-image":["case",["has","maki_beta"],["coalesce",["image",["get","maki_beta"]],["image",["get","maki"]]],["image",["get","maki"]]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-offset":["step",["zoom"],["step",["get","sizerank"],["literal",[0,0]],5,["literal",[0,.8]]],17,["step",["get","sizerank"],["literal",[0,0]],13,["literal",[0,.8]]]],"text-anchor":["step",["zoom"],["step",["get","sizerank"],"center",5,"top"],17,["step",["get","sizerank"],"center",13,"top"]],"text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["dock","glacier","landform","water_feature","wetland","disputed_dock","disputed_glacier","disputed_landform","disputed_water_feature","disputed_wetland"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"natural-point-label",paint:{"icon-opacity":["step",["zoom"],["step",["get","sizerank"],0,5,1],17,["step",["get","sizerank"],0,13,1]],"text-halo-color":"hsl(60, 20%, 98%)","text-halo-width":.5,"text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-max-angle":30,"text-letter-spacing":["match",["get","class"],"ocean",.25,["sea","bay"],.15,0],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"water-line-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-line-height":1.3,"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":["match",["get","class"],"ocean",.25,["bay","sea"],.15,.01],"text-max-width":["match",["get","class"],"ocean",4,"sea",5,["bay","water"],7,10]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"water-point-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:10,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-transform":"uppercase","text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-letter-spacing":["match",["get","type"],"suburb",.15,.05],"text-max-width":7,"text-padding":3,"text-size":["interpolate",["cubic-bezier",.5,0,1,1],["zoom"],11,["match",["get","type"],"suburb",11,10.5],15,["match",["get","type"],"suburb",15,14]],visibility:"none"},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["match",["get","class"],["settlement_subdivision","disputed_settlement_subdivision"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],3],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-subdivision-label",paint:{"text-halo-color":"hsla(60, 25%, 100%, 0.75)","text-halo-width":1,"text-color":"hsl(230, 29%, 36%)","text-halo-blur":.5},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],11,9,10],6,["step",["get","symbolrank"],14,9,12,12,10],8,["step",["get","symbolrank"],16,9,14,12,12,15,10],13,["step",["get","symbolrank"],22,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-justify":"auto",visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:13,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],[">",["get","symbolrank"],6],4,[">=",["get","symbolrank"],7],6,[">=",["get","symbolrank"],8],7,[">=",["get","symbolrank"],10],10,[">=",["get","symbolrank"],11],11,[">=",["get","symbolrank"],13],12,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-minor-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],13,6,11],6,["step",["get","symbolrank"],18,6,16,7,14],8,["step",["get","symbolrank"],20,9,16,10,14],15,["step",["get","symbolrank"],24,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],8,"center"],visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],!1,2,["<=",["get","symbolrank"],6],4,["<",["get","symbolrank"],7],6,["<",["get","symbolrank"],8],7,["<",["get","symbolrank"],10],10,["<",["get","symbolrank"],11],11,["<",["get","symbolrank"],13],12,["<",["get","symbolrank"],15],13,[">=",["get","symbolrank"],11],14,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-major-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:3,layout:{"text-size":["interpolate",["cubic-bezier",.85,.7,.65,1],["zoom"],4,["step",["get","symbolrank"],9,6,8,7,7],9,["step",["get","symbolrank"],21,6,16,7,14]],"text-transform":"uppercase","text-font":["DIN Pro Bold","Arial Unicode MS Bold"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":.15,"text-max-width":6},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:9,filter:["all",["match",["get","class"],["state","disputed_state"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"state-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-opacity":.5},"source-layer":"place_label"},{minzoom:1,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-radial-offset":["step",["zoom"],.6,8,0],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],7,"auto"],"text-size":["interpolate",["cubic-bezier",.2,0,.7,1],["zoom"],1,["step",["get","symbolrank"],12.100000000000001,4,9.9,5,8.8],9,["step",["get","symbolrank"],24.200000000000003,4,20.900000000000002,5,18.700000000000003]]},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:10,filter:["all",["match",["get","class"],["country","disputed_country"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"country-label",paint:{"icon-opacity":["step",["zoom"],["case",["has","text_anchor"],1,0],7,0],"text-color":"hsl(0, 0.00%, 13.70%)","text-halo-color":["interpolate",["linear"],["zoom"],2,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.25},"source-layer":"place_label"},{minzoom:.75,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-size":["interpolate",["exponential",.5],["zoom"],0,10,2.5,15],"text-transform":"uppercase","text-letter-spacing":.05},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:3,filter:["==",["get","class"],"continent"],type:"symbol",source:"composite",id:"continent-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":["interpolate",["linear"],["zoom"],0,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.5,"text-opacity":["interpolate",["linear"],["zoom"],0,.8,1.5,.5,2.5,0]},"source-layer":"natural_label"},{id:"world-12nm-v4-20231025",minzoom:3,type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2],"line-translate":[0,0]},source:"composite","source-layer":"eez_12nm_new1-6jzkww",layout:{"line-join":"round",visibility:"none"}},{id:"china-taiwan",type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2]},layout:{"line-join":"round",visibility:"none"},source:"composite","source-layer":"eez-d4udtm"},{id:"ne-10m-outline",type:"line",paint:{"line-color":"hsl(172, 0%, 33%)"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv",layout:{visibility:"none"}},{id:"ne-10m-label",type:"symbol",paint:{"text-halo-color":"hsl(0, 0%, 100%)","text-halo-width":1,"text-halo-blur":1},layout:{"text-field":["to-string",["get","name"]],"text-size":12,visibility:"none"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv"},{id:"china-route-line",type:"line",paint:{"line-color":"rgba(119, 239, 157, 1)","line-width":2},source:"composite","source-layer":"china_route-bdtx5d",layout:{visibility:"none"}},{id:"china-route-fill",type:"fill",paint:{"fill-color":"rgba(119, 239, 157, 1)","fill-opacity":.2},source:"composite","source-layer":"china_route-bdtx5d",filter:["match",["get","featureType"],["route"],!0,!1],layout:{visibility:"none"}},{id:"china-route-label",type:"symbol",paint:{"text-color":"rgba(0, 0, 0, 1)"},source:"composite","source-layer":"china_route-bdtx5d",layout:{"text-field":["to-string",["get","RouteName"]],"text-size":10,"text-offset":[0,1.6],visibility:"none"}},{id:"ice-area-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(199, 239, 236, 0.7)"},source:"composite","source-layer":"ICE_AREA-6oqazd",layout:{visibility:"none"}},{id:"ice-area-line",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgba(199, 239, 236, 1)"},layout:{visibility:"none"},source:"composite","source-layer":"ICE_AREA-6oqazd"},{id:"tide-stations",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)","text-opacity":["step",["zoom"],0,4,1]},layout:{visibility:"none","text-field":["to-string",["get","Location_EN"]],"text-size":10,"icon-image":"tide","icon-size":1,"icon-offset":[0,-13],"text-offset":[0,1.6],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"]},source:"composite","source-layer":"tide_station_cn-8xvt91"},{id:"loadlines-label",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)"},layout:{"text-field":["to-string",["get","name"]],"text-size":10,"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],visibility:"none","text-offset":[0,1]},source:"composite","source-layer":"loadlines-b6mgr8"},{id:"loadlines-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":["match",["get","val"],["LLGreen"],"rgba(164, 214, 217, 0.6)",["LLBlue"],"rgba(53, 121, 194, 0.6)",["LLRed"],"rgba(217, 150, 151, 0.6)",["LLSUMMER"],"rgba(111, 110, 212, 0.6)","rgba(255, 255, 255, 0.6)"],"fill-outline-color":"rgba(255, 255, 255, 0.3)"},layout:{visibility:"none"},source:"composite","source-layer":"loadlines-b6mgr8"}],created:"2025-07-18T03:20:31.079Z",modified:"2025-07-31T03:57:21.238Z",id:"cmd894dwn036m01rf7anc0k0d",owner:"neatchenheng",visibility:"private",protected:!1,draft:!1},zoom:this.zoom,center:this.tropicals.center||[120,30],preserveDrawingBuffer:!0,projection:"mercator",attributionControl:!1,dragPan:!1});o.on("load",()=>{this.map=o,this.map.scrollZoom.disable(),this.handleSetCenterAndBbox(),this.handleRenderTropcals(),this.handleDrawHurricaneMarker()})},handleSetCenterAndBbox(){var c,d,i;const o=[];(i=(d=(c=this.tropicals)==null?void 0:c.data)==null?void 0:d.features)==null||i.forEach(m=>{var p,y,h,f;((p=m==null?void 0:m.properties)==null?void 0:p.type)==="forecast"&&!m.properties.disabled&&(((y=m==null?void 0:m.geometry)==null?void 0:y.type)==="LineString"?o.push(...(h=m==null?void 0:m.geometry)==null?void 0:h.coordinates):o.push((f=m==null?void 0:m.geometry)==null?void 0:f.coordinates))});const a=Z.LaneHelper.calculateCenter([o]);this.map.setCenter(a);let t=Z.LaneHelper.calculateBBox([o]);this.map.fitScreenCoordinates(this.map.project([t[0]-10,t[1]-10]),this.map.project([t[2]+10,t[3]+10]),this.map.getBearing()),this.map.addSource(this.bboxSource,{type:"geojson",data:{type:"Feature",geometry:{type:"LineString",coordinates:[[t[0]-5,t[1]-5],[t[2]+5,t[1]-5],[t[2]+5,t[3]+5],[t[0]-5,t[3]+5],[t[0]-5,t[1]-5]]}}}),this.map.addLayer({id:this.bboxLayer,type:"line",source:this.bboxSource,layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"rgba(0,0,0,0.6)","line-width":1,"line-opacity":1,"line-dasharray":[2,2]}})},handleRenderTropcals(){var o,a,t,c,d;if(this.tropicals){const i=new Date().valueOf();let m=0,p=0;(o=this.map)!=null&&o.getSource(this.source)?((t=this.map)==null||t.getSource(this.source).setData((a=this.tropicals)!=null&&a.active?this.tropicals.data:this.empty),p=new Date().valueOf()-(i+m),console.log("[tropicals] update elapsed: ",p,", total: ",m+=p)):(this.map.addSource(this.source,{type:"geojson",data:(c=this.tropicals)!=null&&c.active?(d=this.tropicals)==null?void 0:d.data:this.empty}),this.map.addLayer({id:this.historyLayer,type:"line",source:this.source,filter:["all",["==","$type","LineString"],["==","type","history"],["!=","disabled",!0]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#000","line-width":4,"line-opacity":.5}}),this.map.addLayer({id:this.forecastLayer,type:"line",source:this.source,filter:["all",["==","$type","LineString"],["==","type","forecast"],["!=","disabled",!0]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":["match",["get","model"],"cma","#e2ea03","jma","#01d2b7","ecmwf","#f582f2","ukm","#f5bb47","noaa-at","#9758fb","noaa-ep","#9758fb","#fff"],"line-width":3,"line-opacity":1,"line-dasharray":[1,2]}}))}},handleDrawHurricaneMarker(){var c,d,i,m,p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R;const o=Z.TropicalHelper.interpolate(this.tropicals,1),a=JSON.parse(JSON.stringify(o)),t=[];if(a.forEach(E=>{var x,H,l;(x=E.properties)!=null&&x.name&&!t.includes((H=E.properties)==null?void 0:H.name)&&t.push((l=E.properties)==null?void 0:l.name)}),t.forEach(E=>{var l;const H=(l=a.filter(G=>{var r;return((r=G.properties)==null?void 0:r.name)===E})[0])==null?void 0:l.properties.model;a.map((G,r)=>{var U,F;return((U=G.properties)==null?void 0:U.name)===E&&(G.properties.disabled=((F=G.properties)==null?void 0:F.model)!==H),G})}),this.interpolateData=JSON.parse(JSON.stringify(a)),(c=this.interpolateMarkers)==null||c.forEach(E=>E==null?void 0:E.remove()),this.interpolateMarkers=[],(d=this.interpolateData)!=null&&d.length&&this.tropicals.active){const E=this.interpolateData.filter(x=>x.properties.date===this.ts&&!x.properties.disabled);this.interpolateData.forEach(x=>{});for(const x of E)if(!x.properties.disabled){let H="#f44336";((m=(i=x.properties)==null?void 0:i.wind)==null?void 0:m.kts)<32||!((y=(p=x.properties)==null?void 0:p.wind)!=null&&y.kts)?H="#03f869":((f=(h=x.properties)==null?void 0:h.wind)==null?void 0:f.kts)>=32&&((w=(k=x.properties)==null?void 0:k.wind)==null?void 0:w.kts)<47?H="#f2f202":((L=(B=x.properties)==null?void 0:B.wind)==null?void 0:L.kts)>=47&&((C=(V=x.properties)==null?void 0:V.wind)==null?void 0:C.kts)<63?H="#ff9100":((D=(z=x.properties)==null?void 0:z.wind)==null?void 0:D.kts)>=63&&((A=(_=x.properties)==null?void 0:_.wind)==null?void 0:A.kts)<79?H="#f44336":((b=(W=x.properties)==null?void 0:W.wind)==null?void 0:b.kts)>=79&&((S=(P=x.properties)==null?void 0:P.wind)==null?void 0:S.kts)<94?H="#c604a4":((R=(v=x.properties)==null?void 0:v.wind)==null?void 0:R.kts)>=94?H="#6b05bb":H="#f44336";const l=`<svg t="1719918955501"
189
189
  class="icon" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg" p-id="18382"
190
190
  xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200">
191
191
  <path
@@ -199,4 +199,4 @@
199
199
  <path
200
200
  d="M420.66666667 959.17a16.08 16.08 0 0 1-15.91-13.49A15.89 15.89 0 0 1 415.50666667 928c1.49-0.55 38.88-14.76 72.79-65.52A354.55 354.55 0 0 1 162.66666667 509.17a450.14 450.14 0 0 1 450.5-450.5 16.07 16.07 0 0 1 15.91 13.48 15.88 15.88 0 0 1-10.75 17.66c-1.58 0.58-39.13 14.9-73.07 65.95A354.22 354.22 0 0 1 871.66666667 509.17a16 16 0 0 1-0.52 4.05A450.14 450.14 0 0 1 420.66666667 959.17zM554.80666667 94.72C351.57666667 123.2 194.66666667 298.21 194.66666667 509.17c0 177.08 144.06 321.74 321.13 322.48a16 16 0 0 1 14.07 23.49c-16.11 30.42-34.27 52.37-50.85 68C682.25666667 894.63 839.16666667 719.63 839.16666667 508.67a15.94 15.94 0 0 1 0.47-3.86C837.30666667 329.33 693.82666667 187 517.80666667 186.67A16 16 0 0 1 503.66666667 163.21c16.21-30.69 34.47-52.79 51.14-68.49z"
201
201
  fill="#ffffff" p-id="18386"></path>
202
- </svg>`,G=document.createElement("div");G.className="hurricane-hourly-marker-simple",G.innerHTML=`<div class="${x.geometry.coordinates[1]>=0?"center north":"center south"}">${l}</div>`;const r=new dt.Marker(G).setLngLat(x.geometry.coordinates).addTo(this.map);this.interpolateMarkers.push(r)}}}}};function Dl(o,a,t,c,d,i){return null}const Nl=tt(zl,[["render",Dl]]),rr="",nr="",_l={name:"TropicalMapbox",props:{token:{type:String,default:()=>""},tropicals:{type:Object,default:()=>({})},ts:{type:String,default:()=>""},container:{type:String,default:()=>""},zoom:{type:Number,default:()=>1}},components:{TropicalGL:_t.TropicalGL,LatLngGL:_t.LatLngGL},data(){return{map:void 0}},mounted(){this.initMap()},methods:{async initMap(){var d,i,m;const o=[];(m=(i=(d=this.tropicals)==null?void 0:d.data)==null?void 0:i.features)==null||m.forEach(p=>{var y,h,f;((y=p==null?void 0:p.properties)==null?void 0:y.type)==="forecast"&&!p.properties.disabled&&((h=p==null?void 0:p.geometry)==null?void 0:h.type)==="Point"&&u(p.properties.date).diff(u(),"hour")<=123&&o.push((f=p==null?void 0:p.geometry)==null?void 0:f.coordinates)});const a=Z.LaneHelper.calculateBBox([o]),t=Z.LaneHelper.calculateCenter([o]);dt.accessToken="pk.eyJ1IjoibmVhdGNoZW5oZW5nIiwiYSI6ImNsdXM3cnBmODBsemgycW1vaXc1bjV6bXMifQ.w6fqHGRbhNhLvm0LnX4ZVw";const c=new dt.Map({container:this.container,style:{version:8,name:"light",metadata:{"mapbox:print":{width:8.5,height:11,units:"in",format:"png",resolution:300},"mapbox:type":"default","mapbox:trackposition":!0,"mapbox:autocomposite":!0,"mapbox:sdk-support":{android:"11.0.0",ios:"11.0.0",js:"3.0.0"},"mapbox:origin":"outdoors-v12","mapbox:groups":{"Terrain, terrain-labels":{name:"Terrain, terrain-labels",collapsed:!0},"Administrative boundaries, admin":{name:"Administrative boundaries, admin",collapsed:!0},"Land & water, built":{name:"Land & water, built",collapsed:!0},"Terrain, surface":{name:"Terrain, surface",collapsed:!0},"Land & water, land":{name:"Land & water, land",collapsed:!1},"Natural features, natural-labels":{name:"Natural features, natural-labels",collapsed:!0},e9bb8e77353431519f7918998e9079d9:{name:"Group",collapsed:!1},"Walking, cycling, etc., barriers-bridges":{name:"Walking, cycling, etc., barriers-bridges",collapsed:!0},"Place labels, place-labels":{name:"Place labels, place-labels",collapsed:!1},"Transit, ferries":{name:"Transit, ferries",collapsed:!0},"Transit, elevated":{name:"Transit, elevated",collapsed:!0},"Walking, cycling, etc., tunnels":{name:"Walking, cycling, etc., tunnels",collapsed:!0},"Terrain, land":{name:"Terrain, land",collapsed:!0},"Road network, tunnels-case":{name:"Road network, tunnels-case",collapsed:!0},"Walking, cycling, etc., walking-cycling-labels":{name:"Walking, cycling, etc., walking-cycling-labels",collapsed:!0},"Walking, cycling, etc., surface":{name:"Walking, cycling, etc., surface",collapsed:!0},"Road network, surface-icons":{name:"Road network, surface-icons",collapsed:!0},"Land & water, water":{name:"Land & water, water",collapsed:!1}}},center:[104.01743114258029,17.078999978347557],zoom:1.9133216316430233,bearing:0,pitch:0,lights:[],fog:{range:[.5,10]},sources:{composite:{url:"mapbox://mapbox.mapbox-streets-v8,mapbox.mapbox-terrain-v2,mapbox.mapbox-bathymetry-v2,mapbox.country-boundaries-v1,neatchenheng.d44z21eg,neatchenheng.82kqbc1q,neatchenheng.a4ifbysm,neatchenheng.27issko0,neatchenheng.9uwc9x7l,neatchenheng.7y3kpvvv,neatchenheng.dlkkohie",type:"vector"}},sprite:"mapbox://sprites/neatchenheng/cmd894dwn036m01rf7anc0k0d/bph0p8ithotzwly53az7lwdmv",glyphs:"mapbox://fonts/mapbox/{fontstack}/{range}.pbf",projection:{name:"equirectangular"},layers:[{id:"land",type:"background",layout:{},paint:{"background-color":"#e9ebed"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},maxzoom:12,type:"fill",source:"composite",id:"landcover",paint:{"fill-color":["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","crop","hsla(68, 55%, 70%, 0.6)","grass","hsla(98, 50%, 74%, 0.6)","snow","hsl(205, 45%, 95%)","hsl(98, 48%, 67%)"],"fill-opacity":["interpolate",["exponential",1.5],["zoom"],8,.8,12,0],"fill-antialias":!1},"source-layer":"landcover"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"fill",source:"composite",id:"national-park",paint:{"fill-color":"hsl(98, 38%, 68%)","fill-opacity":["interpolate",["linear"],["zoom"],5,0,6,.6,12,.2]},"source-layer":"landuse_overlay"},{minzoom:9,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"line",source:"composite",id:"national-park_tint-band",paint:{"line-color":"hsl(98, 38%, 68%)","line-width":["interpolate",["exponential",1.5],["zoom"],9,1,14,8],"line-blur":["interpolate",["exponential",1.5],["zoom"],9,1,14,8]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["all",[">=",["to-number",["get","sizerank"]],0],["match",["get","class"],["agriculture","wood","grass","scrub","glacier","pitch","sand"],["step",["zoom"],!1,11,!0],"residential",["step",["zoom"],!0,10,!1],["park","airport"],["step",["zoom"],!1,8,["case",["==",["get","sizerank"],1],!0,!1],10,!0],["facility","industrial"],["step",["zoom"],!1,12,!0],"rock",["step",["zoom"],!1,11,!0],"cemetery",["step",["zoom"],!1,11,!0],"school",["step",["zoom"],!1,11,!0],"hospital",["step",["zoom"],!1,11,!0],"commercial_area",["step",["zoom"],!1,11,!0],!1],["<=",["-",["to-number",["get","sizerank"]],["interpolate",["exponential",1.5],["zoom"],12,0,18,14]],14]],type:"fill",source:"composite",id:"landuse",paint:{"fill-color":["interpolate",["linear"],["zoom"],15,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsl(60, 0%, 85%)","school","hsl(40, 45%, 78%)","commercial_area","hsl(55, 45%, 85%)","residential","hsl(60, 7%, 87%)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"],16,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsla(60, 0%, 85%, 0.5)","school","hsl(40, 45%, 78%)","commercial_area","hsla(55, 45%, 85%, 0.5)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"]],"fill-opacity":["interpolate",["linear"],["zoom"],8,["match",["get","class"],"residential",.8,.2],10,["match",["get","class"],"residential",0,1]],"fill-antialias":!1},"source-layer":"landuse"},{minzoom:15,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"pitch"],type:"line",source:"composite",id:"pitch-outline",paint:{"line-color":"hsl(0, 0%, 69%)"},"source-layer":"landuse"},{id:"waterway-shadow",type:"line",source:"composite","source-layer":"waterway",minzoom:10,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"],visibility:"none"},paint:{"line-color":"hsl(224, 79%, 69%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"line-translate-anchor":"viewport","line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water-shadow",type:"fill",source:"composite","source-layer":"water",minzoom:10,layout:{visibility:"none"},paint:{"fill-color":"hsl(224, 79%, 69%)","fill-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"fill-translate-anchor":"viewport"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"waterway",type:"line",source:"composite","source-layer":"waterway",minzoom:8,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"]},paint:{"line-color":"hsl(198, 100%, 37%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water",type:"fill",source:"composite","source-layer":"water",layout:{},paint:{"fill-color":"hsl(215, 92%, 81%)"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},maxzoom:8,type:"fill",source:"composite",id:"water-depth",paint:{"fill-antialias":!1,"fill-color":["interpolate",["linear"],["zoom"],6,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0.35)",200,"hsla(205, 75%, 63%, 0.35)",7e3,"hsla(205, 75%, 56%, 0.35)"],8,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0)",200,"hsla(205, 75%, 63%, 0)",7e3,"hsla(205, 75%, 53%, 0)"]]},"source-layer":"depth"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,.25,10.5,.15]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland-pattern",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,0,10.5,1],"fill-pattern":"wetland","fill-translate-anchor":"viewport"},"source-layer":"landuse_overlay"},{minzoom:13,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"Polygon"]],type:"fill",source:"composite",id:"land-structure-polygon",paint:{"fill-color":"hsl(0, 0%, 69%)"},"source-layer":"structure"},{minzoom:13,layout:{"line-cap":"square",visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"LineString"]],type:"line",source:"composite",id:"land-structure-line",paint:{"line-width":["interpolate",["exponential",1.99],["zoom"],14,.75,20,40],"line-color":"hsl(60, 20%, 85%)"},"source-layer":"structure"},{id:"empty-layer-0",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-1",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"country-boundaries",type:"fill",source:"composite","source-layer":"country_boundaries",paint:{"fill-color":"rgb(200, 200, 200)"},layout:{visibility:"none"}},{id:"empty-layer-2",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-3",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-4",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"water-outline2",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgb(150, 150, 150)"},layout:{visibility:"none"},source:"composite","source-layer":"water"},{id:"water-outline",type:"line",paint:{"line-color":"hsl(0, 0%, 70%)","line-width":["interpolate",["linear"],["zoom"],0,1.5,4,1]},source:"composite","source-layer":"water"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-bg",paint:{"line-width":["interpolate",["linear"],["zoom"],3,4,12,8],"line-color":"rgb(173, 169, 170)","line-opacity":["interpolate",["linear"],["zoom"],3,0,4,.5],"line-blur":["interpolate",["linear"],["zoom"],3,0,12,2]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","disputed"],"false"],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary",paint:{"line-color":"rgb(143, 143, 143)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[2,0]],7,["literal",[2,2,6,2]]]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","disputed"],"true"],["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-disputed",paint:{"line-color":"rgb(95, 93, 94)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[3,2,5]],7,["literal",[2,1.5]]]},"source-layer":"admin"},{minzoom:13,layout:{"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-max-angle":30,"symbol-spacing":["interpolate",["linear",1],["zoom"],15,250,17,400],"text-size":["interpolate",["linear"],["zoom"],13,12,18,18],"symbol-placement":"line","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["canal","river","stream","disputed_canal","disputed_river","disputed_stream"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"waterway-label",paint:{"text-color":"hsl(205, 43%, 90%)","text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"text-max-angle":30,"text-field":["coalesce",["get","name_en"],["get","name"]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport"},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["glacier","landform","disputed_glacier","disputed_landform"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"natural-line-label",paint:{"text-halo-width":.5,"text-halo-color":"hsl(60, 17%, 84%)","text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"icon-image":["case",["has","maki_beta"],["coalesce",["image",["get","maki_beta"]],["image",["get","maki"]]],["image",["get","maki"]]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-offset":["step",["zoom"],["step",["get","sizerank"],["literal",[0,0]],5,["literal",[0,.8]]],17,["step",["get","sizerank"],["literal",[0,0]],13,["literal",[0,.8]]]],"text-anchor":["step",["zoom"],["step",["get","sizerank"],"center",5,"top"],17,["step",["get","sizerank"],"center",13,"top"]],"text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["dock","glacier","landform","water_feature","wetland","disputed_dock","disputed_glacier","disputed_landform","disputed_water_feature","disputed_wetland"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"natural-point-label",paint:{"icon-opacity":["step",["zoom"],["step",["get","sizerank"],0,5,1],17,["step",["get","sizerank"],0,13,1]],"text-halo-color":"hsl(60, 20%, 98%)","text-halo-width":.5,"text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-max-angle":30,"text-letter-spacing":["match",["get","class"],"ocean",.25,["sea","bay"],.15,0],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"water-line-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-line-height":1.3,"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":["match",["get","class"],"ocean",.25,["bay","sea"],.15,.01],"text-max-width":["match",["get","class"],"ocean",4,"sea",5,["bay","water"],7,10]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"water-point-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:10,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-transform":"uppercase","text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-letter-spacing":["match",["get","type"],"suburb",.15,.05],"text-max-width":7,"text-padding":3,"text-size":["interpolate",["cubic-bezier",.5,0,1,1],["zoom"],11,["match",["get","type"],"suburb",11,10.5],15,["match",["get","type"],"suburb",15,14]],visibility:"none"},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["match",["get","class"],["settlement_subdivision","disputed_settlement_subdivision"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],3],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-subdivision-label",paint:{"text-halo-color":"hsla(60, 25%, 100%, 0.75)","text-halo-width":1,"text-color":"hsl(230, 29%, 36%)","text-halo-blur":.5},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],11,9,10],6,["step",["get","symbolrank"],14,9,12,12,10],8,["step",["get","symbolrank"],16,9,14,12,12,15,10],13,["step",["get","symbolrank"],22,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-justify":"auto",visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:13,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],[">",["get","symbolrank"],6],4,[">=",["get","symbolrank"],7],6,[">=",["get","symbolrank"],8],7,[">=",["get","symbolrank"],10],10,[">=",["get","symbolrank"],11],11,[">=",["get","symbolrank"],13],12,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-minor-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],13,6,11],6,["step",["get","symbolrank"],18,6,16,7,14],8,["step",["get","symbolrank"],20,9,16,10,14],15,["step",["get","symbolrank"],24,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],8,"center"],visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],!1,2,["<=",["get","symbolrank"],6],4,["<",["get","symbolrank"],7],6,["<",["get","symbolrank"],8],7,["<",["get","symbolrank"],10],10,["<",["get","symbolrank"],11],11,["<",["get","symbolrank"],13],12,["<",["get","symbolrank"],15],13,[">=",["get","symbolrank"],11],14,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-major-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:3,layout:{"text-size":["interpolate",["cubic-bezier",.85,.7,.65,1],["zoom"],4,["step",["get","symbolrank"],9,6,8,7,7],9,["step",["get","symbolrank"],21,6,16,7,14]],"text-transform":"uppercase","text-font":["DIN Pro Bold","Arial Unicode MS Bold"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":.15,"text-max-width":6},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:9,filter:["all",["match",["get","class"],["state","disputed_state"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"state-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-opacity":.5},"source-layer":"place_label"},{minzoom:1,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-radial-offset":["step",["zoom"],.6,8,0],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],7,"auto"],"text-size":["interpolate",["cubic-bezier",.2,0,.7,1],["zoom"],1,["step",["get","symbolrank"],12.100000000000001,4,9.9,5,8.8],9,["step",["get","symbolrank"],24.200000000000003,4,20.900000000000002,5,18.700000000000003]]},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:10,filter:["all",["match",["get","class"],["country","disputed_country"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"country-label",paint:{"icon-opacity":["step",["zoom"],["case",["has","text_anchor"],1,0],7,0],"text-color":"hsl(0, 0.00%, 13.70%)","text-halo-color":["interpolate",["linear"],["zoom"],2,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.25},"source-layer":"place_label"},{minzoom:.75,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-size":["interpolate",["exponential",.5],["zoom"],0,10,2.5,15],"text-transform":"uppercase","text-letter-spacing":.05},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:3,filter:["==",["get","class"],"continent"],type:"symbol",source:"composite",id:"continent-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":["interpolate",["linear"],["zoom"],0,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.5,"text-opacity":["interpolate",["linear"],["zoom"],0,.8,1.5,.5,2.5,0]},"source-layer":"natural_label"},{id:"world-12nm-v4-20231025",minzoom:3,type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2],"line-translate":[0,0]},source:"composite","source-layer":"eez_12nm_new1-6jzkww",layout:{"line-join":"round",visibility:"none"}},{id:"china-taiwan",type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2]},layout:{"line-join":"round",visibility:"none"},source:"composite","source-layer":"eez-d4udtm"},{id:"ne-10m-outline",type:"line",paint:{"line-color":"hsl(172, 0%, 33%)"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv",layout:{visibility:"none"}},{id:"ne-10m-label",type:"symbol",paint:{"text-halo-color":"hsl(0, 0%, 100%)","text-halo-width":1,"text-halo-blur":1},layout:{"text-field":["to-string",["get","name"]],"text-size":12,visibility:"none"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv"},{id:"china-route-line",type:"line",paint:{"line-color":"rgba(119, 239, 157, 1)","line-width":2},source:"composite","source-layer":"china_route-bdtx5d",layout:{visibility:"none"}},{id:"china-route-fill",type:"fill",paint:{"fill-color":"rgba(119, 239, 157, 1)","fill-opacity":.2},source:"composite","source-layer":"china_route-bdtx5d",filter:["match",["get","featureType"],["route"],!0,!1],layout:{visibility:"none"}},{id:"china-route-label",type:"symbol",paint:{"text-color":"rgba(0, 0, 0, 1)"},source:"composite","source-layer":"china_route-bdtx5d",layout:{"text-field":["to-string",["get","RouteName"]],"text-size":10,"text-offset":[0,1.6],visibility:"none"}},{id:"ice-area-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(199, 239, 236, 0.7)"},source:"composite","source-layer":"ICE_AREA-6oqazd",layout:{visibility:"none"}},{id:"ice-area-line",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgba(199, 239, 236, 1)"},layout:{visibility:"none"},source:"composite","source-layer":"ICE_AREA-6oqazd"},{id:"tide-stations",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)","text-opacity":["step",["zoom"],0,4,1]},layout:{visibility:"none","text-field":["to-string",["get","Location_EN"]],"text-size":10,"icon-image":"tide","icon-size":1,"icon-offset":[0,-13],"text-offset":[0,1.6],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"]},source:"composite","source-layer":"tide_station_cn-8xvt91"},{id:"loadlines-label",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)"},layout:{"text-field":["to-string",["get","name"]],"text-size":10,"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],visibility:"none","text-offset":[0,1]},source:"composite","source-layer":"loadlines-b6mgr8"},{id:"loadlines-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":["match",["get","val"],["LLGreen"],"rgba(164, 214, 217, 0.6)",["LLBlue"],"rgba(53, 121, 194, 0.6)",["LLRed"],"rgba(217, 150, 151, 0.6)",["LLSUMMER"],"rgba(111, 110, 212, 0.6)","rgba(255, 255, 255, 0.6)"],"fill-outline-color":"rgba(255, 255, 255, 0.3)"},layout:{visibility:"none"},source:"composite","source-layer":"loadlines-b6mgr8"}],created:"2025-07-18T03:20:31.079Z",modified:"2025-07-31T03:57:21.238Z",id:"cmd894dwn036m01rf7anc0k0d",owner:"neatchenheng",visibility:"private",protected:!1,draft:!1},zoom:this.zoom,center:t||this.tropicals.center||[120,30],preserveDrawingBuffer:!0,projection:"mercator",attributionControl:!1});c.on("load",()=>{this.map=c,this.map.fitScreenCoordinates(this.map.project([a[0]-1,a[1]-1]),this.map.project([a[2]+1,a[3]+1]),this.map.getBearing())})}}},Sl={class:"map-box"};function El(o,a,t,c,d,i){const m=e.resolveComponent("TropicalGL"),p=e.resolveComponent("LatLngGL");return e.openBlock(),e.createElementBlock("div",Sl,[d.map?(e.openBlock(),e.createBlock(m,{key:0,class:"hurricane",fromTropicalReport:!0,map:d.map,tropicals:t.tropicals,date:t.ts,hideTropicalsLegend:!0},null,8,["map","tropicals","date"])):e.createCommentVNode("",!0),d.map?(e.openBlock(),e.createBlock(p,{key:1,map:d.map,show:!0,bottom:"10px"},null,8,["map"])):e.createCommentVNode("",!0)])}const Ll=tt(_l,[["render",El]]),Vl={props:{id:{type:String,default:function(){return""}},title:{type:String,default:function(){return""}},series:{type:Array,default:function(){return[]}},xAxis:{type:Array,default:function(){return[]}},color:{type:Array,default:function(){return[]}}},data(){return{chart:void 0,currentWidth:void 0,currentHeight:void 0,handleResize:void 0,handleRecover:void 0,handleResizePrint:void 0}},watch:{series:{handler(o,a){JSON.stringify(o)!=="[]"&&JSON.stringify(o)!==JSON.stringify(a)&&this.$nextTick(()=>{this.initProbabilityData()})},immediate:!0}},mounted(){this.handleResize=()=>{this.chart.resize()},window.addEventListener("resize",this.handleResize)},beforeUnmount(){window.removeEventListener("resize",this.handleResize)},methods:{initProbabilityData(){if(!this.chart){let c=document.getElementById(this.id);this.chart=j.init(c)}const o=Number(u(this.xAxis[0]).utc().format("x"))-8*60*60*1e3,a=Number(u(this.xAxis[this.xAxis.length-1]).utc().format("x"))-8*60*60*1e3;let t={title:{text:this.title,textStyle:{fontSize:14}},grid:{left:"30",right:"0",bottom:"30",top:"70"},tooltip:{trigger:"axis"},legend:{show:!0,top:"40",right:"0",textStyle:{fontSize:11},itemWidth:12,itemHeight:12},color:this.color,xAxis:{type:"time",min:o,max:a,axisLabel:{show:!0,formatter:function(c,d){const i=u(c).format("MMM-DD"),m=u(c).format("HH");return m==="00"||d===0?i:m},fontSize:"11px"}},yAxis:{name:"",type:"value",splitLine:{show:!1},axisLine:{show:!0},axisLabel:{show:!0,textStyle:{fontSize:11}},axisTick:{show:!1}},series:this.series};this.id==="pressureChart"&&(t.yAxis.min="900"),this.$nextTick(()=>{this.chart.setOption(t)})}}},Hl=["id"];function Tl(o,a,t,c,d,i){return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",{id:t.id,style:{height:"240px"}},null,8,Hl)])}const Bl=tt(Vl,[["render",Tl]]),dr="",cr="",mr="",Cl={name:"IdmTropical",components:{IdmBrand:Nt,MiniMap:Nl,Mapbox:Ll,Echart:Bl},props:{report:{type:Object,default:()=>({})},ts:{type:String,default:()=>""},token:{type:String,default:""},model:{type:String,default:""}},emits:["center"],data(){return{loading:!1,tropicals:void 0,activeForecast:void 0,timeSubscript:["0","6","12","18","24","36","48","72"],hourSubscript:[6,12,18,24],records:void 0,xAxis:[],probabilityColor:["#6b05bb","#c604a4","#f44336","#ff9100","#f2f202","#03f869"],probabilitySeries:[],center:[]}},computed:{computeTime(){return function(o){if(o){const a=u(o).utc();return`${a.format("yyyy-MM-DD HH:mm[ (UTC) ]")} (${a==null?void 0:a.fromNow()})`}return"-"}},computePrecision(){return function(o,a=0){return isNaN(o)||o===-999?"-":Z.LngLatHelper.roundPrecision(o,a)}},computeHours(){return function(o,a){return u(a).add(o,"h").utc().format("MMMDD/HH[Z]")}},computedLngLat(){return function(o,a){return`${Z.LngLatHelper.lat2pretty(o).pretty} / ${Z.LngLatHelper.lng2pretty(a).pretty}`}},computeCandidateIndex(){return function(o,a){let t=0;for(const c in o){if(Number(c)>a)return{prev:t,next:Number(c)};t=Number(c)}return{prev:t,next:-1}}},computeInterpolateValue(){return function(o,a,t){return o?a?Math.round((o+(a-o)*t)*100)/100:o:a}},computeHourSubscript(){return function(o){let a="";return this.hourSubscript.forEach((t,c)=>{o<t&&a===""&&(a=c)}),a}},computeKLineData(){return function(o){const a=o.length;if(a){const t={time:o[0][0],min:void 0,max:void 0,first:o[0][1],last:o[a-1][1],middle:""};let c=o[0][1],d=o[0][1];return o.forEach(i=>{c=!c||c<i[1]?i[1]:c,d=!d||d>i[1]?i[1]:d}),d||c?t.middle=(Number(d)+Number(c))/2:t.middle="-",t.min=d,t.max=c,t}}},computeBF(){return function(o){const a=rt.Meteo2Assist.kts2ms(o);return rt.Meteo2Assist.beaufort(a)}}},watch:{model:{handler(){var o;(o=this.report)!=null&&o.id&&!this.loading&&this.prepare()},immediate:!0},"report.id":{handler(){var o;(o=this.report)!=null&&o.id&&!this.loading&&this.prepare()},immediate:!0}},methods:{async prepare(){var d,i,m,p,y,h,f,k,w,B,L,V,C,z;this.loading=!0;const o=Z.TropicalHelper.convert2Geojson([this.report]);this.model&&(o.features=o.features.filter(D=>{var _,A;return((_=D.properties)==null?void 0:_.model)===this.model&&((A=D.properties)==null?void 0:A.type)==="forecast"||D.properties.type==="history"}));const a=(m=(i=(d=this.report)==null?void 0:d.forecasts)==null?void 0:i[0])==null?void 0:m.hours;this.center=((y=(p=this.report)==null?void 0:p.history)==null?void 0:y[0])||a[Object.keys(a)[0]],this.tropicals={data:o,active:!0,cached:!1,type:"json",etime:this.ts,version:Math.random()+1,center:[(h=this.center)==null?void 0:h.lng,(f=this.center)==null?void 0:f.lat]},this.activeForecast=this.model?((w=(k=this.report)==null?void 0:k.forecasts)==null?void 0:w.filter(D=>D.model===this.model)[0])||((L=(B=this.report)==null?void 0:B.forecasts)==null?void 0:L[0]):(C=(V=this.report)==null?void 0:V.forecasts)==null?void 0:C[0],this.activeForecast.sample=[];const t=u((z=this.activeForecast)==null?void 0:z.date);let c=0;for(const D in this.activeForecast.hours)if(c<8){const _=this.activeForecast.hours[D];_.hour=Number(D),_.date=t.clone().add(_.hour,"h").utc().format("MMM-DD/HH[Z]"),this.activeForecast.sample.push(_),c++}else break;this.records=await this.interpolatedRecord(this.activeForecast.date,this.activeForecast.hours,1),this.fetchData().then(),this.loading=!1},async fetchData(){var p;const o=this.ts?u(Number(this.ts)).utc().format("YYYY-MM-DD HH"):u().utc().format("YYYY-MM-DD HH");for(let y in this.records)u(this.activeForecast.date).add(y,"h").utc().format("YYYY-MM-DD HH")===o&&this.$emit("center",this.records[y]);let a=this.computeHourSubscript(u(this.activeForecast.date).utc().format("H"));const t=[],c=[];let d=[],i=[],m=[];for(let y in this.records){const h=this.records[y],f=u(this.activeForecast.date).add(y,"h").utc(),k=this.computeHourSubscript(u(f).format("H")),w=`${u(f).format("YYYY-MM-DD")} ${this.hourSubscript[k]}:00:00`;a===k?(i.push([w,h.wind.kts]),m.push([w,h.pressure]),d.push([w,h.wind.kts])):(t.push(d),a=k,d=[],i=[],m=[],d.push([w,h.wind.kts]),i.push([w,h.wind.kts]),m.push([w,h.pressure]),this.xAxis.push(f))}for(let y in this.activeForecast.hours){const h=this.activeForecast.hours[y],f=u(this.activeForecast.date).add(y,"h").utc(),k=this.computeHourSubscript(u(f).format("H")),w=`${u(f).format("YYYY-MM-DD")} ${this.hourSubscript[k]}:00:00`;c.push([w,((p=h.gusts)==null?void 0:p.kts)??"-"])}this.fetchProbabilityData(t)},fetchProbabilityData(o){let a={td:[],ts:[],sts:[],ty:[],sty:[],supty:[]};o.forEach(t=>{var f,k,w,B,L,V;let c=0,d=0,i=0,m=0,p=0,y=0;t.forEach(C=>{const z=C[1];z<=32?c++:z<47?d++:z<63?i++:z<79?m++:z<94?p++:z>=94&&y++});const h=t.length;a.td.push([(f=t[0])==null?void 0:f[0],Z.LngLatHelper.roundPrecision(c/h,2)*100]),a.ts.push([(k=t[0])==null?void 0:k[0],Z.LngLatHelper.roundPrecision(d/h,2)*100]),a.sts.push([(w=t[0])==null?void 0:w[0],Z.LngLatHelper.roundPrecision(i/h,2)*100]),a.ty.push([(B=t[0])==null?void 0:B[0],Z.LngLatHelper.roundPrecision(m/h,2)*100]),a.sty.push([(L=t[0])==null?void 0:L[0],Z.LngLatHelper.roundPrecision(p/h,2)*100]),a.supty.push([(V=t[0])==null?void 0:V[0],Z.LngLatHelper.roundPrecision(y/h,2)*100])}),this.probabilitySeries=[{name:"SuperTY [>94kts]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.supty},{name:"STY [80-94]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.sty},{name:"TY [64-79]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.ty},{name:"STS [48-63]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.sts},{name:"TS [33-47]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.ts},{name:"TD [<32]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.td}]},async interpolatedRecord(o,a,t=3){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F;const c=u(o).set({second:0}).utc();let d=t-(c.get("hour")*60+c.get("minute"))%(t*60)/60,i;const m={};for(;i=this.computeCandidateIndex(a,d),i.next!==-1||d===i.prev;){const $=(d-i.prev)/(i.next-i.prev);m[d]={gusts:this.computeInterpolateValue((p=a[i.prev])==null?void 0:p.gusts,(y=a[i.next])==null?void 0:y.gusts,$),lat:this.computeInterpolateValue((h=a[i.prev])==null?void 0:h.lat,(f=a[i.next])==null?void 0:f.lat,$),lng:this.computeInterpolateValue((k=a[i.prev])==null?void 0:k.lng,(w=a[i.next])==null?void 0:w.lng,$),movement:{deg:this.computeInterpolateValue((L=(B=a[i.prev])==null?void 0:B.movement)==null?void 0:L.deg,(C=(V=a[i.next])==null?void 0:V.movement)==null?void 0:C.deg,$),kts:this.computeInterpolateValue((D=(z=a[i.prev])==null?void 0:z.movement)==null?void 0:D.kts,(A=(_=a[i.next])==null?void 0:_.movement)==null?void 0:A.kts,$)},pressure:this.computeInterpolateValue((W=a[i.prev])==null?void 0:W.pressure,(b=a[i.next])==null?void 0:b.pressure,$),wind:{kts:this.computeInterpolateValue((S=(P=a[i.prev])==null?void 0:P.wind)==null?void 0:S.kts,(R=(v=a[i.next])==null?void 0:v.wind)==null?void 0:R.kts,$),lat:this.computeInterpolateValue((x=(E=a[i.prev])==null?void 0:E.wind)==null?void 0:x.lat,(l=(H=a[i.next])==null?void 0:H.wind)==null?void 0:l.lat,$),lng:this.computeInterpolateValue((r=(G=a[i.prev])==null?void 0:G.wind)==null?void 0:r.lng,(F=(U=a[i.next])==null?void 0:U.wind)==null?void 0:F.lng,$)}},d+=t}return m}}},Ml={class:"typhoon-report"},Al={class:"content-box"},Il={class:"row"},Wl={class:"info-box"},Pl={class:"title-card table-bg-blue-light"},Ol={class:"item"},vl={class:"name"},Rl={class:"type"},Gl={class:"info"},$l={class:"item"},Yl={style:{flex:"4"}},jl={style:{flex:"6"}},Fl={class:"item"},Ul={style:{flex:"4"}},ql={style:{flex:"6"}},Zl={id:"miniMap",class:"mini-map"},Xl={id:"normalMap",class:"normal-map"},Jl={class:"echart-container"},Ql={class:"typ-table"};function Kl(o,a,t,c,d,i){var f,k,w,B,L,V,C,z,D,_,A,W;const m=e.resolveComponent("IdmBrand"),p=e.resolveComponent("MiniMap"),y=e.resolveComponent("Mapbox"),h=e.resolveComponent("Echart");return e.openBlock(),e.createElementBlock("div",Ml,[e.createVNode(m,{name:"Tropical Cyclone Strike Probability Report"}),e.createElementVNode("div",Al,[e.createElementVNode("div",Il,[e.createElementVNode("div",Wl,[e.createElementVNode("div",Pl,[e.createElementVNode("div",Ol,[e.createElementVNode("div",null,[e.createElementVNode("span",vl,e.toDisplayString((f=t.report)==null?void 0:f.name),1),a[0]||(a[0]=e.createTextVNode(", ",-1)),e.createElementVNode("span",Rl,e.toDisplayString((w=(k=t.report)==null?void 0:k.history[0])==null?void 0:w.type),1),e.createElementVNode("span",null," [ "+e.toDisplayString((B=this.model)==null?void 0:B.toUpperCase())+" ]",1)]),e.createElementVNode("div",Gl,[e.createElementVNode("span",null,"Last updated: "+e.toDisplayString(i.computeTime(((V=(L=d.records)==null?void 0:L.history)==null?void 0:V.updated)||((D=(z=(C=t.report)==null?void 0:C.forecasts)==null?void 0:z.filter(b=>!b.disabled)[0])==null?void 0:D.date))),1)])]),e.createElementVNode("div",$l,[e.createElementVNode("div",Yl,[a[1]||(a[1]=e.createElementVNode("span",{class:"label"},"Position:",-1)),e.createElementVNode("span",null,e.toDisplayString(i.computedLngLat(d.center.lat,d.center.lng)),1)]),e.createElementVNode("div",jl,[a[2]||(a[2]=e.createElementVNode("span",{class:"label"},"Pressure:",-1)),e.createElementVNode("span",null,e.toDisplayString(d.center.pressure||"-")+" hPa",1)])]),e.createElementVNode("div",Fl,[e.createElementVNode("div",Ul,[a[3]||(a[3]=e.createElementVNode("span",{class:"label"},"Present Movement:",-1)),e.createElementVNode("span",null,e.toDisplayString(((_=d.center.movement)==null?void 0:_.deg)||"-")+"°",1),a[4]||(a[4]=e.createTextVNode(" / ",-1)),e.createElementVNode("span",null,e.toDisplayString(((A=d.center.movement)==null?void 0:A.kts)||"-")+" kts",1)]),e.createElementVNode("div",ql,[a[5]||(a[5]=e.createElementVNode("span",{class:"label"},"Maximum sustained wind near center:",-1)),e.createElementVNode("span",null,e.toDisplayString(d.center.kts||"-")+" kts, BF"+e.toDisplayString(i.computeBF(d.center.kts)),1)])])]),a[6]||(a[6]=e.createStaticVNode('<div class="legend-card table-bg-blue-light text-label" data-v-4ea12a45><div class="item" data-v-4ea12a45><div class="legend" data-v-4ea12a45><div class="icon history" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>Past Track</div></div><div class="legend" data-v-4ea12a45><div class="icon forecast" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>Forecast Track</div></div><div class="legend" data-v-4ea12a45><div class="icon td" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>TD</div></div><div class="legend" data-v-4ea12a45><div class="icon ts" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>TS</div></div><div class="legend" data-v-4ea12a45><div class="icon sts" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>STS</div></div><div class="legend" data-v-4ea12a45><div class="icon ty" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>TY</div></div><div class="legend" data-v-4ea12a45><div class="icon sty" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>STY</div></div><div class="legend" data-v-4ea12a45><div class="icon supper-ty" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>Super TY</div></div><div class="legend" data-v-4ea12a45><div class="icon r7" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>35kts Radii</div></div><div class="legend" data-v-4ea12a45><div class="icon r10" data-v-4ea12a45></div><div class="label" data-v-4ea12a45>50kts Radii</div></div></div></div>',1))]),e.createElementVNode("div",Zl,[e.createVNode(p,{tropicals:d.tropicals,ts:t.ts,token:t.token,container:"miniMap",zoom:1},null,8,["tropicals","ts","token"])])]),e.createElementVNode("div",Xl,[e.createVNode(y,{tropicals:d.tropicals,model:t.model,ts:t.ts,token:t.token,container:"normalMap",zoom:4},null,8,["tropicals","model","ts","token"])]),e.createElementVNode("div",Jl,[e.createElementVNode("table",Ql,[a[7]||(a[7]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("td",null,"Time"),e.createElementVNode("td",null,"Position"),e.createElementVNode("td",null,"Pres(hPa)"),e.createElementVNode("td",null,"Max(kts)"),e.createElementVNode("td",null,"35/50(kts)"),e.createElementVNode("td",null,"Dir(deg)"),e.createElementVNode("td",null,"Spd(kts)")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((W=d.activeForecast)==null?void 0:W.sample,(b,P)=>{var S,v,R,E,x;return e.openBlock(),e.createElementBlock("tr",{key:P},[e.createElementVNode("td",null,e.toDisplayString(b.date),1),e.createElementVNode("td",null,e.toDisplayString(i.computedLngLat(b.lat,b.lng)),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(b.pressure??"-")),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(((S=b==null?void 0:b.wind)==null?void 0:S.kts)??"-")),1),e.createElementVNode("td",null,e.toDisplayString(`${i.computePrecision(((v=b==null?void 0:b.wind)==null?void 0:v.r7)||"-")} / ${i.computePrecision(((R=b==null?void 0:b.wind)==null?void 0:R.r10)||"-")} nm`),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(((E=b==null?void 0:b.movement)==null?void 0:E.deg)??"-")),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(((x=b==null?void 0:b.movement)==null?void 0:x.kts)??"-")),1)])}),128))])]),e.createVNode(h,{id:"probabilityChart",class:"echart-box",title:"Probability(%) of Tropical Cyclone Intensity falling in each category","x-axis":d.xAxis,color:d.probabilityColor,series:d.probabilitySeries},null,8,["x-axis","color","series"])])]),a[8]||(a[8]=e.createElementVNode("div",{class:"report-tips text-tips"}," * The report is for reference only. All the material is an advisory provided so as to assist the Master in making the final route decision. ",-1))])}const Vt=tt(Cl,[["render",Kl],["__scopeId","data-v-4ea12a45"]]),er={install(o){o.component("IdmTropical",Vt)}};se.BrandPlugin=Ba,se.IdmBrand=Nt,se.IdmForecast=St,se.IdmHistorical=Et,se.IdmLoading=ct,se.IdmLoadingPlugin=Ia,se.IdmSeasonal=Lt,se.IdmSpotPlugin=kl,se.IdmTropical=Vt,se.IdmTropicalPlugin=er,Object.defineProperty(se,Symbol.toStringTag,{value:"Module"})});
202
+ </svg>`,G=document.createElement("div");G.className="hurricane-hourly-marker-simple",G.innerHTML=`<div class="${x.geometry.coordinates[1]>=0?"center north":"center south"}">${l}</div>`;const r=new dt.Marker(G).setLngLat(x.geometry.coordinates).addTo(this.map);this.interpolateMarkers.push(r)}}}}};function Dl(o,a,t,c,d,i){return null}const Nl=tt(zl,[["render",Dl]]),rr="",nr="",_l={name:"TropicalMapbox",props:{token:{type:String,default:()=>""},tropicals:{type:Object,default:()=>({})},ts:{type:String,default:()=>""},container:{type:String,default:()=>""},zoom:{type:Number,default:()=>1}},components:{TropicalGL:_t.TropicalGL,LatLngGL:_t.LatLngGL},data(){return{map:void 0}},mounted(){this.initMap()},methods:{async initMap(){var d,i,m;const o=[];(m=(i=(d=this.tropicals)==null?void 0:d.data)==null?void 0:i.features)==null||m.forEach(p=>{var y,h,f;((y=p==null?void 0:p.properties)==null?void 0:y.type)==="forecast"&&!p.properties.disabled&&((h=p==null?void 0:p.geometry)==null?void 0:h.type)==="Point"&&u(p.properties.date).diff(u(),"hour")<=123&&o.push((f=p==null?void 0:p.geometry)==null?void 0:f.coordinates)});const a=Z.LaneHelper.calculateBBox([o]),t=Z.LaneHelper.calculateCenter([o]);dt.accessToken="pk.eyJ1IjoibmVhdGNoZW5oZW5nIiwiYSI6ImNsdXM3cnBmODBsemgycW1vaXc1bjV6bXMifQ.w6fqHGRbhNhLvm0LnX4ZVw";const c=new dt.Map({container:this.container,style:{version:8,name:"light",metadata:{"mapbox:print":{width:8.5,height:11,units:"in",format:"png",resolution:300},"mapbox:type":"default","mapbox:trackposition":!0,"mapbox:autocomposite":!0,"mapbox:sdk-support":{android:"11.0.0",ios:"11.0.0",js:"3.0.0"},"mapbox:origin":"outdoors-v12","mapbox:groups":{"Terrain, terrain-labels":{name:"Terrain, terrain-labels",collapsed:!0},"Administrative boundaries, admin":{name:"Administrative boundaries, admin",collapsed:!0},"Land & water, built":{name:"Land & water, built",collapsed:!0},"Terrain, surface":{name:"Terrain, surface",collapsed:!0},"Land & water, land":{name:"Land & water, land",collapsed:!1},"Natural features, natural-labels":{name:"Natural features, natural-labels",collapsed:!0},e9bb8e77353431519f7918998e9079d9:{name:"Group",collapsed:!1},"Walking, cycling, etc., barriers-bridges":{name:"Walking, cycling, etc., barriers-bridges",collapsed:!0},"Place labels, place-labels":{name:"Place labels, place-labels",collapsed:!1},"Transit, ferries":{name:"Transit, ferries",collapsed:!0},"Transit, elevated":{name:"Transit, elevated",collapsed:!0},"Walking, cycling, etc., tunnels":{name:"Walking, cycling, etc., tunnels",collapsed:!0},"Terrain, land":{name:"Terrain, land",collapsed:!0},"Road network, tunnels-case":{name:"Road network, tunnels-case",collapsed:!0},"Walking, cycling, etc., walking-cycling-labels":{name:"Walking, cycling, etc., walking-cycling-labels",collapsed:!0},"Walking, cycling, etc., surface":{name:"Walking, cycling, etc., surface",collapsed:!0},"Road network, surface-icons":{name:"Road network, surface-icons",collapsed:!0},"Land & water, water":{name:"Land & water, water",collapsed:!1}}},center:[104.01743114258029,17.078999978347557],zoom:1.9133216316430233,bearing:0,pitch:0,lights:[],fog:{range:[.5,10]},sources:{composite:{url:"mapbox://mapbox.mapbox-streets-v8,mapbox.mapbox-terrain-v2,mapbox.mapbox-bathymetry-v2,mapbox.country-boundaries-v1,neatchenheng.d44z21eg,neatchenheng.82kqbc1q,neatchenheng.a4ifbysm,neatchenheng.27issko0,neatchenheng.9uwc9x7l,neatchenheng.7y3kpvvv,neatchenheng.dlkkohie",type:"vector"}},sprite:"mapbox://sprites/neatchenheng/cmd894dwn036m01rf7anc0k0d/bph0p8ithotzwly53az7lwdmv",glyphs:"mapbox://fonts/mapbox/{fontstack}/{range}.pbf",projection:{name:"equirectangular"},layers:[{id:"land",type:"background",layout:{},paint:{"background-color":"#e9ebed"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},maxzoom:12,type:"fill",source:"composite",id:"landcover",paint:{"fill-color":["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","crop","hsla(68, 55%, 70%, 0.6)","grass","hsla(98, 50%, 74%, 0.6)","snow","hsl(205, 45%, 95%)","hsl(98, 48%, 67%)"],"fill-opacity":["interpolate",["exponential",1.5],["zoom"],8,.8,12,0],"fill-antialias":!1},"source-layer":"landcover"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"fill",source:"composite",id:"national-park",paint:{"fill-color":"hsl(98, 38%, 68%)","fill-opacity":["interpolate",["linear"],["zoom"],5,0,6,.6,12,.2]},"source-layer":"landuse_overlay"},{minzoom:9,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"national_park"],type:"line",source:"composite",id:"national-park_tint-band",paint:{"line-color":"hsl(98, 38%, 68%)","line-width":["interpolate",["exponential",1.5],["zoom"],9,1,14,8],"line-blur":["interpolate",["exponential",1.5],["zoom"],9,1,14,8]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["all",[">=",["to-number",["get","sizerank"]],0],["match",["get","class"],["agriculture","wood","grass","scrub","glacier","pitch","sand"],["step",["zoom"],!1,11,!0],"residential",["step",["zoom"],!0,10,!1],["park","airport"],["step",["zoom"],!1,8,["case",["==",["get","sizerank"],1],!0,!1],10,!0],["facility","industrial"],["step",["zoom"],!1,12,!0],"rock",["step",["zoom"],!1,11,!0],"cemetery",["step",["zoom"],!1,11,!0],"school",["step",["zoom"],!1,11,!0],"hospital",["step",["zoom"],!1,11,!0],"commercial_area",["step",["zoom"],!1,11,!0],!1],["<=",["-",["to-number",["get","sizerank"]],["interpolate",["exponential",1.5],["zoom"],12,0,18,14]],14]],type:"fill",source:"composite",id:"landuse",paint:{"fill-color":["interpolate",["linear"],["zoom"],15,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsl(60, 0%, 85%)","school","hsl(40, 45%, 78%)","commercial_area","hsl(55, 45%, 85%)","residential","hsl(60, 7%, 87%)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"],16,["match",["get","class"],"wood","hsla(103, 50%, 60%, 0.8)","scrub","hsla(98, 47%, 68%, 0.6)","agriculture","hsla(98, 50%, 74%, 0.6)","park",["match",["get","type"],["garden","playground","zoo"],"hsl(98, 38%, 68%)","hsl(98, 55%, 70%)"],"grass","hsla(98, 50%, 74%, 0.6)","airport","hsl(230, 40%, 82%)","cemetery","hsl(98, 45%, 75%)","glacier","hsl(205, 45%, 95%)","hospital","hsl(20, 45%, 82%)","pitch","hsl(88, 65%, 75%)","sand","hsl(69, 60%, 72%)","rock","hsla(60, 0%, 85%, 0.5)","school","hsl(40, 45%, 78%)","commercial_area","hsla(55, 45%, 85%, 0.5)",["facility","industrial"],"hsl(230, 20%, 85%)","hsl(60, 12%, 72%)"]],"fill-opacity":["interpolate",["linear"],["zoom"],8,["match",["get","class"],"residential",.8,.2],10,["match",["get","class"],"residential",0,1]],"fill-antialias":!1},"source-layer":"landuse"},{minzoom:15,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, land"},filter:["==",["get","class"],"pitch"],type:"line",source:"composite",id:"pitch-outline",paint:{"line-color":"hsl(0, 0%, 69%)"},"source-layer":"landuse"},{id:"waterway-shadow",type:"line",source:"composite","source-layer":"waterway",minzoom:10,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"],visibility:"none"},paint:{"line-color":"hsl(224, 79%, 69%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"line-translate-anchor":"viewport","line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water-shadow",type:"fill",source:"composite","source-layer":"water",minzoom:10,layout:{visibility:"none"},paint:{"fill-color":"hsl(224, 79%, 69%)","fill-translate":["interpolate",["exponential",1.2],["zoom"],7,["literal",[0,0]],16,["literal",[-1,-1]]],"fill-translate-anchor":"viewport"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"waterway",type:"line",source:"composite","source-layer":"waterway",minzoom:8,layout:{"line-cap":["step",["zoom"],"butt",11,"round"],"line-join":["step",["zoom"],"miter",11,"round"]},paint:{"line-color":"hsl(198, 100%, 37%)","line-width":["interpolate",["exponential",1.3],["zoom"],9,["match",["get","class"],["canal","river"],.1,0],20,["match",["get","class"],["canal","river"],8,3]],"line-opacity":["interpolate",["linear"],["zoom"],8,0,8.5,1]},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{id:"water",type:"fill",source:"composite","source-layer":"water",layout:{},paint:{"fill-color":"hsl(215, 92%, 81%)"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"}},{layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},maxzoom:8,type:"fill",source:"composite",id:"water-depth",paint:{"fill-antialias":!1,"fill-color":["interpolate",["linear"],["zoom"],6,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0.35)",200,"hsla(205, 75%, 63%, 0.35)",7e3,"hsla(205, 75%, 56%, 0.35)"],8,["interpolate",["linear"],["get","min_depth"],0,"hsla(205, 75%, 70%, 0)",200,"hsla(205, 75%, 63%, 0)",7e3,"hsla(205, 75%, 53%, 0)"]]},"source-layer":"depth"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,.25,10.5,.15]},"source-layer":"landuse_overlay"},{minzoom:5,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, water"},filter:["match",["get","class"],["wetland","wetland_noveg"],!0,!1],type:"fill",source:"composite",id:"wetland-pattern",paint:{"fill-color":"hsl(194, 38%, 74%)","fill-opacity":["interpolate",["linear"],["zoom"],10,0,10.5,1],"fill-pattern":"wetland","fill-translate-anchor":"viewport"},"source-layer":"landuse_overlay"},{minzoom:13,layout:{visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"Polygon"]],type:"fill",source:"composite",id:"land-structure-polygon",paint:{"fill-color":"hsl(0, 0%, 69%)"},"source-layer":"structure"},{minzoom:13,layout:{"line-cap":"square",visibility:"none"},metadata:{"mapbox:featureComponent":"land-and-water","mapbox:group":"Land & water, built"},filter:["all",["==",["get","class"],"land"],["==",["geometry-type"],"LineString"]],type:"line",source:"composite",id:"land-structure-line",paint:{"line-width":["interpolate",["exponential",1.99],["zoom"],14,.75,20,40],"line-color":"hsl(60, 20%, 85%)"},"source-layer":"structure"},{id:"empty-layer-0",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-1",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"country-boundaries",type:"fill",source:"composite","source-layer":"country_boundaries",paint:{"fill-color":"rgb(200, 200, 200)"},layout:{visibility:"none"}},{id:"empty-layer-2",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-3",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"empty-layer-4",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(0, 0, 0, 0)"},layout:{},source:"composite","source-layer":"country_boundaries"},{id:"water-outline2",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgb(150, 150, 150)"},layout:{visibility:"none"},source:"composite","source-layer":"water"},{id:"water-outline",type:"line",paint:{"line-color":"hsl(0, 0%, 70%)","line-width":["interpolate",["linear"],["zoom"],0,1.5,4,1]},source:"composite","source-layer":"water"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-bg",paint:{"line-width":["interpolate",["linear"],["zoom"],3,4,12,8],"line-color":"rgb(173, 169, 170)","line-opacity":["interpolate",["linear"],["zoom"],3,0,4,.5],"line-blur":["interpolate",["linear"],["zoom"],3,0,12,2]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","admin_level"],0],["==",["get","disputed"],"false"],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary",paint:{"line-color":"rgb(143, 143, 143)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[2,0]],7,["literal",[2,2,6,2]]]},"source-layer":"admin"},{minzoom:1,layout:{},metadata:{"mapbox:featureComponent":"admin-boundaries","mapbox:group":"Administrative boundaries, admin"},filter:["all",["==",["get","disputed"],"true"],["==",["get","admin_level"],0],["==",["get","maritime"],"false"],["match",["get","worldview"],["all","CN"],!0,!1]],type:"line",source:"composite",id:"admin-0-boundary-disputed",paint:{"line-color":"rgb(95, 93, 94)","line-width":["interpolate",["linear"],["zoom"],3,.5,12,2],"line-dasharray":["step",["zoom"],["literal",[3,2,5]],7,["literal",[2,1.5]]]},"source-layer":"admin"},{minzoom:13,layout:{"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-max-angle":30,"symbol-spacing":["interpolate",["linear",1],["zoom"],15,250,17,400],"text-size":["interpolate",["linear"],["zoom"],13,12,18,18],"symbol-placement":"line","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["canal","river","stream","disputed_canal","disputed_river","disputed_stream"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"waterway-label",paint:{"text-color":"hsl(205, 43%, 90%)","text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"text-max-angle":30,"text-field":["coalesce",["get","name_en"],["get","name"]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport"},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["glacier","landform","disputed_glacier","disputed_landform"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"natural-line-label",paint:{"text-halo-width":.5,"text-halo-color":"hsl(60, 17%, 84%)","text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:4,layout:{"text-size":["step",["zoom"],["step",["get","sizerank"],18,5,12],17,["step",["get","sizerank"],18,13,12]],"icon-image":["case",["has","maki_beta"],["coalesce",["image",["get","maki_beta"]],["image",["get","maki"]]],["image",["get","maki"]]],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-offset":["step",["zoom"],["step",["get","sizerank"],["literal",[0,0]],5,["literal",[0,.8]]],17,["step",["get","sizerank"],["literal",[0,0]],13,["literal",[0,.8]]]],"text-anchor":["step",["zoom"],["step",["get","sizerank"],"center",5,"top"],17,["step",["get","sizerank"],"center",13,"top"]],"text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["dock","glacier","landform","water_feature","wetland","disputed_dock","disputed_glacier","disputed_landform","disputed_water_feature","disputed_wetland"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],4],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"natural-point-label",paint:{"icon-opacity":["step",["zoom"],["step",["get","sizerank"],0,5,1],17,["step",["get","sizerank"],0,13,1]],"text-halo-color":"hsl(60, 20%, 98%)","text-halo-width":.5,"text-halo-blur":.5,"text-color":"hsl(340, 10%, 38%)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-max-angle":30,"text-letter-spacing":["match",["get","class"],"ocean",.25,["sea","bay"],.15,0],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"symbol-placement":"line-center","text-pitch-alignment":"viewport","text-field":["coalesce",["get","name_en"],["get","name"]]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"LineString"]],type:"symbol",source:"composite",id:"water-line-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:1,layout:{"text-line-height":1.3,"text-size":["interpolate",["linear"],["zoom"],0,["*",["-",16,["sqrt",["get","sizerank"]]],1],22,["*",["-",22,["sqrt",["get","sizerank"]]],1]],"text-font":["DIN Pro Italic","Arial Unicode MS Regular"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":["match",["get","class"],"ocean",.25,["bay","sea"],.15,.01],"text-max-width":["match",["get","class"],"ocean",4,"sea",5,["bay","water"],7,10]},metadata:{"mapbox:featureComponent":"natural-features","mapbox:group":"Natural features, natural-labels"},filter:["all",["match",["get","class"],["bay","ocean","reservoir","sea","water","disputed_bay","disputed_ocean","disputed_reservoir","disputed_sea","disputed_water"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],1],60,["<",["distance-from-center"],1.5],70,["<",["distance-from-center"],2]],["==",["geometry-type"],"Point"]],type:"symbol",source:"composite",id:"water-point-label",paint:{"text-color":["match",["get","class"],["bay","ocean","sea"],"hsl(205, 71%, 90%)","hsl(205, 43%, 90%)"],"text-halo-color":"hsla(60, 17%, 84%, 0.5)"},"source-layer":"natural_label"},{minzoom:10,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-transform":"uppercase","text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-letter-spacing":["match",["get","type"],"suburb",.15,.05],"text-max-width":7,"text-padding":3,"text-size":["interpolate",["cubic-bezier",.5,0,1,1],["zoom"],11,["match",["get","type"],"suburb",11,10.5],15,["match",["get","type"],"suburb",15,14]],visibility:"none"},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["match",["get","class"],["settlement_subdivision","disputed_settlement_subdivision"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["<=",["get","filterrank"],3],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-subdivision-label",paint:{"text-halo-color":"hsla(60, 25%, 100%, 0.75)","text-halo-width":1,"text-color":"hsl(230, 29%, 36%)","text-halo-blur":.5},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],11,9,10],6,["step",["get","symbolrank"],14,9,12,12,10],8,["step",["get","symbolrank"],16,9,14,12,12,15,10],13,["step",["get","symbolrank"],22,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],"text-justify":"auto",visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:13,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],[">",["get","symbolrank"],6],4,[">=",["get","symbolrank"],7],6,[">=",["get","symbolrank"],8],7,[">=",["get","symbolrank"],10],10,[">=",["get","symbolrank"],11],11,[">=",["get","symbolrank"],13],12,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-minor-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:2,layout:{"text-line-height":1.1,"text-size":["interpolate",["cubic-bezier",.2,0,.9,1],["zoom"],3,["step",["get","symbolrank"],13,6,11],6,["step",["get","symbolrank"],18,6,16,7,14],8,["step",["get","symbolrank"],20,9,16,10,14],15,["step",["get","symbolrank"],24,9,20,12,16,15,14]],"text-radial-offset":["step",["zoom"],["match",["get","capital"],2,.6,.55],8,0],"symbol-sort-key":["get","symbolrank"],"icon-image":["step",["zoom"],["case",["==",["get","capital"],2],"border-dot-13",["step",["get","symbolrank"],"dot-11",9,"dot-10",11,"dot-9"]],8,""],"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],8,"center"],visibility:"none","text-anchor":["step",["zoom"],["get","text_anchor"],8,"center"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-max-width":7},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:15,filter:["all",["<=",["get","filterrank"],3],["match",["get","class"],["settlement","disputed_settlement"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["zoom"],!1,2,["<=",["get","symbolrank"],6],4,["<",["get","symbolrank"],7],6,["<",["get","symbolrank"],8],7,["<",["get","symbolrank"],10],10,["<",["get","symbolrank"],11],11,["<",["get","symbolrank"],13],12,["<",["get","symbolrank"],15],13,[">=",["get","symbolrank"],11],14,[">=",["get","symbolrank"],15]],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"settlement-major-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-halo-blur":1},"source-layer":"place_label"},{minzoom:3,layout:{"text-size":["interpolate",["cubic-bezier",.85,.7,.65,1],["zoom"],4,["step",["get","symbolrank"],9,6,8,7,7],9,["step",["get","symbolrank"],21,6,16,7,14]],"text-transform":"uppercase","text-font":["DIN Pro Bold","Arial Unicode MS Bold"],"text-field":["coalesce",["get","name_en"],["get","name"]],"text-letter-spacing":.15,"text-max-width":6},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:9,filter:["all",["match",["get","class"],["state","disputed_state"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"state-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":"hsl(60, 25%, 100%)","text-halo-width":1,"text-opacity":.5},"source-layer":"place_label"},{minzoom:1,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-radial-offset":["step",["zoom"],.6,8,0],"text-justify":["step",["zoom"],["match",["get","text_anchor"],["left","bottom-left","top-left"],"left",["right","bottom-right","top-right"],"right","center"],7,"auto"],"text-size":["interpolate",["cubic-bezier",.2,0,.7,1],["zoom"],1,["step",["get","symbolrank"],12.100000000000001,4,9.9,5,8.8],9,["step",["get","symbolrank"],24.200000000000003,4,20.900000000000002,5,18.700000000000003]]},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:10,filter:["all",["match",["get","class"],["country","disputed_country"],["match",["get","worldview"],["all","CN"],!0,!1],!1],["step",["pitch"],!0,50,["<",["distance-from-center"],3],60,["<",["distance-from-center"],4],70,["<",["distance-from-center"],5]]],type:"symbol",source:"composite",id:"country-label",paint:{"icon-opacity":["step",["zoom"],["case",["has","text_anchor"],1,0],7,0],"text-color":"hsl(0, 0.00%, 13.70%)","text-halo-color":["interpolate",["linear"],["zoom"],2,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.25},"source-layer":"place_label"},{minzoom:.75,layout:{"text-field":["coalesce",["get","name_en"],["get","name"]],"text-line-height":1.1,"text-max-width":6,"text-font":["DIN Pro Medium","Arial Unicode MS Regular"],"text-size":["interpolate",["exponential",.5],["zoom"],0,10,2.5,15],"text-transform":"uppercase","text-letter-spacing":.05},metadata:{"mapbox:featureComponent":"place-labels","mapbox:group":"Place labels, place-labels"},maxzoom:3,filter:["==",["get","class"],"continent"],type:"symbol",source:"composite",id:"continent-label",paint:{"text-color":"hsl(230, 29%, 0%)","text-halo-color":["interpolate",["linear"],["zoom"],0,"hsla(60, 25%, 100%, 0.75)",3,"hsl(60, 25%, 100%)"],"text-halo-width":1.5,"text-opacity":["interpolate",["linear"],["zoom"],0,.8,1.5,.5,2.5,0]},"source-layer":"natural_label"},{id:"world-12nm-v4-20231025",minzoom:3,type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2],"line-translate":[0,0]},source:"composite","source-layer":"eez_12nm_new1-6jzkww",layout:{"line-join":"round",visibility:"none"}},{id:"china-taiwan",type:"line",paint:{"line-color":"hsl(2, 88%, 55%)","line-opacity":.62,"line-width":["interpolate",["linear"],["zoom"],0,2,22,2]},layout:{"line-join":"round",visibility:"none"},source:"composite","source-layer":"eez-d4udtm"},{id:"ne-10m-outline",type:"line",paint:{"line-color":"hsl(172, 0%, 33%)"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv",layout:{visibility:"none"}},{id:"ne-10m-label",type:"symbol",paint:{"text-halo-color":"hsl(0, 0%, 100%)","text-halo-width":1,"text-halo-blur":1},layout:{"text-field":["to-string",["get","name"]],"text-size":12,visibility:"none"},source:"composite","source-layer":"ne_10m_geography_marine_polys-3968bv"},{id:"china-route-line",type:"line",paint:{"line-color":"rgba(119, 239, 157, 1)","line-width":2},source:"composite","source-layer":"china_route-bdtx5d",layout:{visibility:"none"}},{id:"china-route-fill",type:"fill",paint:{"fill-color":"rgba(119, 239, 157, 1)","fill-opacity":.2},source:"composite","source-layer":"china_route-bdtx5d",filter:["match",["get","featureType"],["route"],!0,!1],layout:{visibility:"none"}},{id:"china-route-label",type:"symbol",paint:{"text-color":"rgba(0, 0, 0, 1)"},source:"composite","source-layer":"china_route-bdtx5d",layout:{"text-field":["to-string",["get","RouteName"]],"text-size":10,"text-offset":[0,1.6],visibility:"none"}},{id:"ice-area-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":"rgba(199, 239, 236, 0.7)"},source:"composite","source-layer":"ICE_AREA-6oqazd",layout:{visibility:"none"}},{id:"ice-area-line",minzoom:0,maxzoom:22,type:"line",paint:{"line-color":"rgba(199, 239, 236, 1)"},layout:{visibility:"none"},source:"composite","source-layer":"ICE_AREA-6oqazd"},{id:"tide-stations",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)","text-opacity":["step",["zoom"],0,4,1]},layout:{visibility:"none","text-field":["to-string",["get","Location_EN"]],"text-size":10,"icon-image":"tide","icon-size":1,"icon-offset":[0,-13],"text-offset":[0,1.6],"text-font":["DIN Pro Regular","Arial Unicode MS Regular"]},source:"composite","source-layer":"tide_station_cn-8xvt91"},{id:"loadlines-label",minzoom:0,maxzoom:22,type:"symbol",paint:{"text-color":"rgb(0, 0, 0)"},layout:{"text-field":["to-string",["get","name"]],"text-size":10,"text-font":["DIN Pro Regular","Arial Unicode MS Regular"],visibility:"none","text-offset":[0,1]},source:"composite","source-layer":"loadlines-b6mgr8"},{id:"loadlines-fill",minzoom:0,maxzoom:22,type:"fill",paint:{"fill-color":["match",["get","val"],["LLGreen"],"rgba(164, 214, 217, 0.6)",["LLBlue"],"rgba(53, 121, 194, 0.6)",["LLRed"],"rgba(217, 150, 151, 0.6)",["LLSUMMER"],"rgba(111, 110, 212, 0.6)","rgba(255, 255, 255, 0.6)"],"fill-outline-color":"rgba(255, 255, 255, 0.3)"},layout:{visibility:"none"},source:"composite","source-layer":"loadlines-b6mgr8"}],created:"2025-07-18T03:20:31.079Z",modified:"2025-07-31T03:57:21.238Z",id:"cmd894dwn036m01rf7anc0k0d",owner:"neatchenheng",visibility:"private",protected:!1,draft:!1},zoom:this.zoom,center:t||this.tropicals.center||[120,30],preserveDrawingBuffer:!0,projection:"mercator",attributionControl:!1});c.on("load",()=>{this.map=c,this.map.fitScreenCoordinates(this.map.project([a[0]-1,a[1]-1]),this.map.project([a[2]+1,a[3]+1]),this.map.getBearing())})}}},Sl={class:"map-box"};function El(o,a,t,c,d,i){const m=e.resolveComponent("TropicalGL"),p=e.resolveComponent("LatLngGL");return e.openBlock(),e.createElementBlock("div",Sl,[d.map?(e.openBlock(),e.createBlock(m,{key:0,class:"hurricane",fromTropicalReport:!0,map:d.map,tropicals:t.tropicals,date:t.ts,hideTropicalsLegend:!0},null,8,["map","tropicals","date"])):e.createCommentVNode("",!0),d.map?(e.openBlock(),e.createBlock(p,{key:1,map:d.map,show:!0,bottom:"10px"},null,8,["map"])):e.createCommentVNode("",!0)])}const Ll=tt(_l,[["render",El]]),Vl={props:{id:{type:String,default:function(){return""}},title:{type:String,default:function(){return""}},series:{type:Array,default:function(){return[]}},xAxis:{type:Array,default:function(){return[]}},color:{type:Array,default:function(){return[]}}},data(){return{chart:void 0,currentWidth:void 0,currentHeight:void 0,handleResize:void 0,handleRecover:void 0,handleResizePrint:void 0}},watch:{series:{handler(o,a){JSON.stringify(o)!=="[]"&&JSON.stringify(o)!==JSON.stringify(a)&&this.$nextTick(()=>{this.initProbabilityData()})},immediate:!0}},mounted(){this.handleResize=()=>{this.chart.resize()},window.addEventListener("resize",this.handleResize)},beforeUnmount(){window.removeEventListener("resize",this.handleResize)},methods:{initProbabilityData(){if(!this.chart){let c=document.getElementById(this.id);this.chart=j.init(c)}const o=Number(u(this.xAxis[0]).utc().format("x"))-8*60*60*1e3,a=Number(u(this.xAxis[this.xAxis.length-1]).utc().format("x"))-8*60*60*1e3;let t={title:{text:this.title,textStyle:{fontSize:14}},grid:{left:"30",right:"0",bottom:"30",top:"70"},tooltip:{trigger:"axis"},legend:{show:!0,top:"40",right:"0",textStyle:{fontSize:11},itemWidth:12,itemHeight:12},color:this.color,xAxis:{type:"time",min:o,max:a,axisLabel:{show:!0,formatter:function(c,d){const i=u(c).format("MMM-DD"),m=u(c).format("HH");return m==="00"||d===0?i:m},fontSize:"11px"}},yAxis:{name:"",type:"value",splitLine:{show:!1},axisLine:{show:!0},axisLabel:{show:!0,textStyle:{fontSize:11}},axisTick:{show:!1}},series:this.series};this.id==="pressureChart"&&(t.yAxis.min="900"),this.$nextTick(()=>{this.chart.setOption(t)})}}},Hl=["id"];function Tl(o,a,t,c,d,i){return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",{id:t.id,style:{height:"240px"}},null,8,Hl)])}const Bl=tt(Vl,[["render",Tl]]),dr="",cr="",mr="",Cl={name:"IdmTropical",components:{IdmBrand:Nt,MiniMap:Nl,Mapbox:Ll,Echart:Bl},props:{report:{type:Object,default:()=>({})},ts:{type:String,default:()=>""},token:{type:String,default:""},model:{type:String,default:""}},emits:["center"],data(){return{loading:!1,tropicals:void 0,activeForecast:void 0,timeSubscript:["0","6","12","18","24","36","48","72"],hourSubscript:[6,12,18,24],records:void 0,xAxis:[],probabilityColor:["#6b05bb","#c604a4","#f44336","#ff9100","#f2f202","#03f869"],probabilitySeries:[],center:[]}},computed:{computeTime(){return function(o){if(o){const a=u(o).utc();return`${a.format("yyyy-MM-DD HH:mm[ (UTC) ]")} (${a==null?void 0:a.fromNow()})`}return"-"}},computePrecision(){return function(o,a=0){return isNaN(o)||o===-999?"-":Z.LngLatHelper.roundPrecision(o,a)}},computeHours(){return function(o,a){return u(a).add(o,"h").utc().format("MMMDD/HH[Z]")}},computedLngLat(){return function(o,a){return`${Z.LngLatHelper.lat2pretty(o).pretty} / ${Z.LngLatHelper.lng2pretty(a).pretty}`}},computeCandidateIndex(){return function(o,a){let t=0;for(const c in o){if(Number(c)>a)return{prev:t,next:Number(c)};t=Number(c)}return{prev:t,next:-1}}},computeInterpolateValue(){return function(o,a,t){return o?a?Math.round((o+(a-o)*t)*100)/100:o:a}},computeHourSubscript(){return function(o){let a="";return this.hourSubscript.forEach((t,c)=>{o<t&&a===""&&(a=c)}),a}},computeKLineData(){return function(o){const a=o.length;if(a){const t={time:o[0][0],min:void 0,max:void 0,first:o[0][1],last:o[a-1][1],middle:""};let c=o[0][1],d=o[0][1];return o.forEach(i=>{c=!c||c<i[1]?i[1]:c,d=!d||d>i[1]?i[1]:d}),d||c?t.middle=(Number(d)+Number(c))/2:t.middle="-",t.min=d,t.max=c,t}}},computeBF(){return function(o){const a=rt.Meteo2Assist.kts2ms(o);return rt.Meteo2Assist.beaufort(a)}}},watch:{model:{handler(){var o;(o=this.report)!=null&&o.id&&!this.loading&&this.prepare()},immediate:!0},"report.id":{handler(){var o;(o=this.report)!=null&&o.id&&!this.loading&&this.prepare()},immediate:!0}},methods:{async prepare(){var d,i,m,p,y,h,f,k,w,B,L,V,C,z;this.loading=!0;const o=Z.TropicalHelper.convert2Geojson([this.report]);this.model&&(o.features=o.features.filter(D=>{var _,A;return((_=D.properties)==null?void 0:_.model)===this.model&&((A=D.properties)==null?void 0:A.type)==="forecast"||D.properties.type==="history"}));const a=(m=(i=(d=this.report)==null?void 0:d.forecasts)==null?void 0:i[0])==null?void 0:m.hours;this.center=((y=(p=this.report)==null?void 0:p.history)==null?void 0:y[0])||a[Object.keys(a)[0]],this.tropicals={data:o,active:!0,cached:!1,type:"json",etime:this.ts,version:Math.random()+1,center:[(h=this.center)==null?void 0:h.lng,(f=this.center)==null?void 0:f.lat]},this.activeForecast=this.model?((w=(k=this.report)==null?void 0:k.forecasts)==null?void 0:w.filter(D=>D.model===this.model)[0])||((L=(B=this.report)==null?void 0:B.forecasts)==null?void 0:L[0]):(C=(V=this.report)==null?void 0:V.forecasts)==null?void 0:C[0],this.activeForecast.sample=[];const t=u((z=this.activeForecast)==null?void 0:z.date);let c=0;for(const D in this.activeForecast.hours)if(c<8){const _=this.activeForecast.hours[D];_.hour=Number(D),_.date=t.clone().add(_.hour,"h").utc().format("MMM-DD/HH[Z]"),this.activeForecast.sample.push(_),c++}else break;this.records=await this.interpolatedRecord(this.activeForecast.date,this.activeForecast.hours,1),this.fetchData().then(),this.loading=!1},async fetchData(){var p;const o=this.ts?u(Number(this.ts)).utc().format("YYYY-MM-DD HH"):u().utc().format("YYYY-MM-DD HH");for(let y in this.records)u(this.activeForecast.date).add(y,"h").utc().format("YYYY-MM-DD HH")===o&&this.$emit("center",this.records[y]);let a=this.computeHourSubscript(u(this.activeForecast.date).utc().format("H"));const t=[],c=[];let d=[],i=[],m=[];for(let y in this.records){const h=this.records[y],f=u(this.activeForecast.date).add(y,"h").utc(),k=this.computeHourSubscript(u(f).format("H")),w=`${u(f).format("YYYY-MM-DD")} ${this.hourSubscript[k]}:00:00`;a===k?(i.push([w,h.wind.kts]),m.push([w,h.pressure]),d.push([w,h.wind.kts])):(t.push(d),a=k,d=[],i=[],m=[],d.push([w,h.wind.kts]),i.push([w,h.wind.kts]),m.push([w,h.pressure]),this.xAxis.push(f))}for(let y in this.activeForecast.hours){const h=this.activeForecast.hours[y],f=u(this.activeForecast.date).add(y,"h").utc(),k=this.computeHourSubscript(u(f).format("H")),w=`${u(f).format("YYYY-MM-DD")} ${this.hourSubscript[k]}:00:00`;c.push([w,((p=h.gusts)==null?void 0:p.kts)??"-"])}this.fetchProbabilityData(t)},fetchProbabilityData(o){let a={td:[],ts:[],sts:[],ty:[],sty:[],supty:[]};o.forEach(t=>{var f,k,w,B,L,V;let c=0,d=0,i=0,m=0,p=0,y=0;t.forEach(C=>{const z=C[1];z<=32?c++:z<47?d++:z<63?i++:z<79?m++:z<94?p++:z>=94&&y++});const h=t.length;a.td.push([(f=t[0])==null?void 0:f[0],Z.LngLatHelper.roundPrecision(c/h,2)*100]),a.ts.push([(k=t[0])==null?void 0:k[0],Z.LngLatHelper.roundPrecision(d/h,2)*100]),a.sts.push([(w=t[0])==null?void 0:w[0],Z.LngLatHelper.roundPrecision(i/h,2)*100]),a.ty.push([(B=t[0])==null?void 0:B[0],Z.LngLatHelper.roundPrecision(m/h,2)*100]),a.sty.push([(L=t[0])==null?void 0:L[0],Z.LngLatHelper.roundPrecision(p/h,2)*100]),a.supty.push([(V=t[0])==null?void 0:V[0],Z.LngLatHelper.roundPrecision(y/h,2)*100])}),this.probabilitySeries=[{name:"SuperTY [>94kts]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.supty},{name:"STY [80-94]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.sty},{name:"TY [64-79]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.ty},{name:"STS [48-63]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.sts},{name:"TS [33-47]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.ts},{name:"TD [<32]",type:"bar",stack:"machine",barMaxWidth:20,label:{show:!1},data:a.td}]},async interpolatedRecord(o,a,t=3){var p,y,h,f,k,w,B,L,V,C,z,D,_,A,W,b,P,S,v,R,E,x,H,l,G,r,U,F;const c=u(o).set({second:0}).utc();let d=t-(c.get("hour")*60+c.get("minute"))%(t*60)/60,i;const m={};for(;i=this.computeCandidateIndex(a,d),i.next!==-1||d===i.prev;){const $=(d-i.prev)/(i.next-i.prev);m[d]={gusts:this.computeInterpolateValue((p=a[i.prev])==null?void 0:p.gusts,(y=a[i.next])==null?void 0:y.gusts,$),lat:this.computeInterpolateValue((h=a[i.prev])==null?void 0:h.lat,(f=a[i.next])==null?void 0:f.lat,$),lng:this.computeInterpolateValue((k=a[i.prev])==null?void 0:k.lng,(w=a[i.next])==null?void 0:w.lng,$),movement:{deg:this.computeInterpolateValue((L=(B=a[i.prev])==null?void 0:B.movement)==null?void 0:L.deg,(C=(V=a[i.next])==null?void 0:V.movement)==null?void 0:C.deg,$),kts:this.computeInterpolateValue((D=(z=a[i.prev])==null?void 0:z.movement)==null?void 0:D.kts,(A=(_=a[i.next])==null?void 0:_.movement)==null?void 0:A.kts,$)},pressure:this.computeInterpolateValue((W=a[i.prev])==null?void 0:W.pressure,(b=a[i.next])==null?void 0:b.pressure,$),wind:{kts:this.computeInterpolateValue((S=(P=a[i.prev])==null?void 0:P.wind)==null?void 0:S.kts,(R=(v=a[i.next])==null?void 0:v.wind)==null?void 0:R.kts,$),lat:this.computeInterpolateValue((x=(E=a[i.prev])==null?void 0:E.wind)==null?void 0:x.lat,(l=(H=a[i.next])==null?void 0:H.wind)==null?void 0:l.lat,$),lng:this.computeInterpolateValue((r=(G=a[i.prev])==null?void 0:G.wind)==null?void 0:r.lng,(F=(U=a[i.next])==null?void 0:U.wind)==null?void 0:F.lng,$)}},d+=t}return m}}},Ml={class:"typhoon-report"},Al={class:"content-box"},Il={class:"row"},Wl={class:"info-box"},Pl={class:"title-card table-bg-blue-light"},Ol={class:"item"},vl={class:"name"},Rl={class:"type"},Gl={class:"info"},$l={class:"item"},Yl={style:{flex:"4"}},jl={style:{flex:"6"}},Fl={class:"item"},Ul={style:{flex:"4"}},ql={style:{flex:"6"}},Zl={id:"miniMap",class:"mini-map"},Xl={id:"normalMap",class:"normal-map"},Jl={class:"echart-container"},Ql={class:"typ-table"};function Kl(o,a,t,c,d,i){var f,k,w,B,L,V,C,z,D,_,A,W;const m=e.resolveComponent("IdmBrand"),p=e.resolveComponent("MiniMap"),y=e.resolveComponent("Mapbox"),h=e.resolveComponent("Echart");return e.openBlock(),e.createElementBlock("div",Ml,[e.createVNode(m,{name:"Tropical Cyclone Strike Probability Report"}),e.createElementVNode("div",Al,[e.createElementVNode("div",Il,[e.createElementVNode("div",Wl,[e.createElementVNode("div",Pl,[e.createElementVNode("div",Ol,[e.createElementVNode("div",null,[e.createElementVNode("span",vl,e.toDisplayString((f=t.report)==null?void 0:f.name),1),a[0]||(a[0]=e.createTextVNode(", ",-1)),e.createElementVNode("span",Rl,e.toDisplayString((w=(k=t.report)==null?void 0:k.history[0])==null?void 0:w.type),1),e.createElementVNode("span",null," [ "+e.toDisplayString((B=this.model)==null?void 0:B.toUpperCase())+" ]",1)]),e.createElementVNode("div",Gl,[e.createElementVNode("span",null,"Last updated: "+e.toDisplayString(i.computeTime(((V=(L=d.records)==null?void 0:L.history)==null?void 0:V.updated)||((D=(z=(C=t.report)==null?void 0:C.forecasts)==null?void 0:z.filter(b=>!b.disabled)[0])==null?void 0:D.date))),1)])]),e.createElementVNode("div",$l,[e.createElementVNode("div",Yl,[a[1]||(a[1]=e.createElementVNode("span",{class:"label"},"Position:",-1)),e.createElementVNode("span",null,e.toDisplayString(i.computedLngLat(d.center.lat,d.center.lng)),1)]),e.createElementVNode("div",jl,[a[2]||(a[2]=e.createElementVNode("span",{class:"label"},"Pressure:",-1)),e.createElementVNode("span",null,e.toDisplayString(d.center.pressure||"-")+" hPa",1)])]),e.createElementVNode("div",Fl,[e.createElementVNode("div",Ul,[a[3]||(a[3]=e.createElementVNode("span",{class:"label"},"Present Movement:",-1)),e.createElementVNode("span",null,e.toDisplayString(((_=d.center.movement)==null?void 0:_.deg)||"-")+"°",1),a[4]||(a[4]=e.createTextVNode(" / ",-1)),e.createElementVNode("span",null,e.toDisplayString(((A=d.center.movement)==null?void 0:A.kts)||"-")+" kts",1)]),e.createElementVNode("div",ql,[a[5]||(a[5]=e.createElementVNode("span",{class:"label"},"Maximum sustained wind near center:",-1)),e.createElementVNode("span",null,e.toDisplayString(d.center.kts||"-")+" kts, BF"+e.toDisplayString(i.computeBF(d.center.kts)),1)])])]),a[6]||(a[6]=e.createStaticVNode('<div class="legend-card table-bg-blue-light text-label" data-v-cf1e262c><div class="item" data-v-cf1e262c><div class="legend" data-v-cf1e262c><div class="icon history" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>Past Track</div></div><div class="legend" data-v-cf1e262c><div class="icon forecast" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>Forecast Track</div></div><div class="legend" data-v-cf1e262c><div class="icon td" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>TD</div></div><div class="legend" data-v-cf1e262c><div class="icon ts" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>TS</div></div><div class="legend" data-v-cf1e262c><div class="icon sts" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>STS</div></div><div class="legend" data-v-cf1e262c><div class="icon ty" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>TY</div></div><div class="legend" data-v-cf1e262c><div class="icon sty" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>STY</div></div><div class="legend" data-v-cf1e262c><div class="icon supper-ty" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>Super TY</div></div><div class="legend" data-v-cf1e262c><div class="icon r7" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>35kts Radii</div></div><div class="legend" data-v-cf1e262c><div class="icon r10" data-v-cf1e262c></div><div class="label" data-v-cf1e262c>50kts Radii</div></div></div></div>',1))]),e.createElementVNode("div",Zl,[e.createVNode(p,{tropicals:d.tropicals,ts:t.ts,token:t.token,container:"miniMap",zoom:1},null,8,["tropicals","ts","token"])])]),e.createElementVNode("div",Xl,[e.createVNode(y,{tropicals:d.tropicals,model:t.model,ts:t.ts,token:t.token,container:"normalMap",zoom:4},null,8,["tropicals","model","ts","token"])]),e.createElementVNode("div",Jl,[e.createElementVNode("table",Ql,[a[7]||(a[7]=e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("td",null,"Time"),e.createElementVNode("td",null,"Position"),e.createElementVNode("td",null,"Pres(hPa)"),e.createElementVNode("td",null,"Max(kts)"),e.createElementVNode("td",null,"35/50(kts)"),e.createElementVNode("td",null,"Dir(deg)"),e.createElementVNode("td",null,"Spd(kts)")])],-1)),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((W=d.activeForecast)==null?void 0:W.sample,(b,P)=>{var S,v,R,E,x;return e.openBlock(),e.createElementBlock("tr",{key:P},[e.createElementVNode("td",null,e.toDisplayString(b.date),1),e.createElementVNode("td",null,e.toDisplayString(i.computedLngLat(b.lat,b.lng)),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(b.pressure??"-")),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(((S=b==null?void 0:b.wind)==null?void 0:S.kts)??"-")),1),e.createElementVNode("td",null,e.toDisplayString(`${i.computePrecision(((v=b==null?void 0:b.wind)==null?void 0:v.r7)||"-")} / ${i.computePrecision(((R=b==null?void 0:b.wind)==null?void 0:R.r10)||"-")} nm`),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(((E=b==null?void 0:b.movement)==null?void 0:E.deg)??"-")),1),e.createElementVNode("td",null,e.toDisplayString(i.computePrecision(((x=b==null?void 0:b.movement)==null?void 0:x.kts)??"-")),1)])}),128))])]),e.createVNode(h,{id:"probabilityChart",class:"echart-box",title:"Probability(%) of Tropical Cyclone Intensity falling in each category","x-axis":d.xAxis,color:d.probabilityColor,series:d.probabilitySeries},null,8,["x-axis","color","series"])])]),a[8]||(a[8]=e.createElementVNode("div",{class:"report-tips text-tips"}," * The report is for reference only. All the material is an advisory provided so as to assist the Master in making the final route decision. ",-1))])}const Vt=tt(Cl,[["render",Kl],["__scopeId","data-v-cf1e262c"]]),er={install(o){o.component("IdmTropical",Vt)}};se.BrandPlugin=Ba,se.IdmBrand=Nt,se.IdmForecast=St,se.IdmHistorical=Et,se.IdmLoading=ct,se.IdmLoadingPlugin=Ia,se.IdmSeasonal=Lt,se.IdmSpotPlugin=kl,se.IdmTropical=Vt,se.IdmTropicalPlugin=er,Object.defineProperty(se,Symbol.toStringTag,{value:"Module"})});