You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
7.3 KiB
2 lines
7.3 KiB
(("undefined"!=typeof globalThis?globalThis:self)["makoChunk_ant-design-pro"]=("undefined"!=typeof globalThis?globalThis:self)["makoChunk_ant-design-pro"]||[]).push([["8aa2681b"],{d922d2a1:function(e,t,a){a.d(t,"__esModule",{value:!0}),a.e(t,{default:function(){return M;}});var l=a("777fffbe"),s=a("852bbaa9"),i=a("dac8af92"),d=a("597fad75"),n=a("0c1cbdee"),r=a("c7d71c0a"),o=a("084468f6"),c=l._(o),h=a("78a22024"),u=l._(h),x=a("bfbbdf71"),f=l._(x),p=a("adf76174"),m=l._(p),g=a("809156a1"),j=l._(g),v=a("de4cb180"),y=l._(v),b=a("609f48be"),w=s._(b),_=a("98213865");let S=(0,_.createStyles)(()=>({activeChart:{position:"relative"},activeChartGrid:{p:{position:"absolute",top:"80px"},"p:last-child":{top:"115px"}},activeChartLegend:{position:"relative",height:"20px",marginTop:"8px",fontSize:"0",lineHeight:"20px",span:{display:"inline-block",width:"33.33%",fontSize:"12px",textAlign:"center"},"span:first-child":{textAlign:"left"},"span:last-child":{textAlign:"right"}},dashedLine:{position:"relative",top:"-70px",left:"-3px",height:"1px"},line:{position:"absolute",top:"0",left:"0",width:"100%",height:"100%",backgroundImage:"linear-gradient(to right, transparent 50%, #e9e9e9 50%)",backgroundSize:"6px"},"dashedLine:last-child":{top:"-36px"}})),C=()=>{var e,t,a,l;let s=(0,w.useRef)(null),n=(0,w.useRef)(null),{styles:r}=S(),[o,c]=(0,w.useState)([]),h=(0,w.useCallback)(()=>{n.current=requestAnimationFrame(()=>{s.current=window.setTimeout(()=>{c(function(){let e=[];for(let a=0;a<24;a+=1){var t;e.push({x:`${1*(t=a)<10?`0${t}`:t}:00`,y:Math.floor(200*Math.random())+50*a});}return e;}()),h();},2e3);});},[]);return(0,w.useEffect)(()=>(h(),()=>{clearTimeout(s.current),n.current&&cancelAnimationFrame(n.current);}),[h]),(0,i.jsxs)("div",{className:r.activeChart,children:[(0,i.jsx)(j.default,{title:"\u76EE\u6807\u8BC4\u4F30",value:"\u6709\u671B\u8FBE\u5230\u9884\u671F"}),(0,i.jsx)("div",{style:{marginTop:32},children:(0,i.jsx)(d.Area,{padding:[0,0,0,0],xField:"x",axis:!1,yField:"y",height:84,style:{fill:"linear-gradient(-90deg, white 0%, #6294FA 100%)",fillOpacity:.6},data:o})}),o&&(0,i.jsxs)("div",{children:[(0,i.jsxs)("div",{className:r.activeChartGrid,children:[(0,i.jsxs)("p",{children:[(null===(e=[...o].sort()[o.length-1])||void 0===e?void 0:e.y)+200," \u4EBF\u5143"]}),(0,i.jsxs)("p",{children:[null===(t=[...o].sort()[Math.floor(o.length/2)])||void 0===t?void 0:t.y," ","\u4EBF\u5143"]})]}),(0,i.jsx)("div",{className:r.dashedLine,children:(0,i.jsx)("div",{className:r.line})}),(0,i.jsx)("div",{className:r.dashedLine,children:(0,i.jsx)("div",{className:r.line})})]}),o&&(0,i.jsxs)("div",{className:r.activeChartLegend,children:[(0,i.jsx)("span",{children:"00:00"}),(0,i.jsx)("span",{children:null===(a=o[Math.floor(o.length/2)])||void 0===a?void 0:a.x}),(0,i.jsx)("span",{children:null===(l=o[o.length-1])||void 0===l?void 0:l.x})]})]});};var k=a("f9a266b4"),A=a("d61866bb");let L=["#eff3ff","#c6dbef","#9ecae1","#6baed6","#4292c6","#2171b5","#084594"];class F extends w.Component{state={data:null,grid:null,loading:!1};async componentDidMount(){let[e,t]=await Promise.all([fetch("https://gw.alipayobjects.com/os/bmw-prod/c5dba875-b6ea-4e88-b778-66a862906c93.json").then(e=>e.json()),fetch("https://gw.alipayobjects.com/os/bmw-prod/8990e8b4-c58e-419b-afb9-8ea3daff2dd1.json").then(e=>e.json())]);this.setState({data:e,grid:t,loading:!0});}render(){let{data:e,grid:t,loading:a}=this.state;return!1===a?(0,i.jsx)(k.PageLoading,{}):(0,i.jsxs)(A.MapboxScene,{map:{center:[110.19382669582967,50.258134],pitch:0,style:"blank",zoom:1},style:{position:"relative",width:"100%",height:"452px"},children:[t&&(0,i.jsx)(A.HeatmapLayer,{source:{data:t,transforms:[{type:"hexagon",size:8e5,field:"capacity",method:"sum"}]},color:{values:"#ddd"},shape:{values:"hexagon"},style:{coverage:.7,opacity:.8}},"1"),e&&[(0,i.jsx)(A.PointLayer,{options:{autoFit:!0},source:{data:e},scale:{values:{color:{field:"cum_conf",type:"quantile"},size:{field:"cum_conf",type:"log"}}},color:{field:"cum_conf",values:L},shape:{values:"circle"},active:{option:{color:"#0c2c84"}},size:{field:"cum_conf",values:[0,30]},style:{opacity:.8}},"2"),(0,i.jsx)(A.PointLayer,{source:{data:e},color:{values:"#fff"},shape:{field:"Short_Name_ZH",values:"text"},filter:{field:"cum_conf",values:e=>e>2e3},size:{values:12},style:{opacity:1,strokeOpacity:1,strokeWidth:0}},"5")]]});}}async function z(){return(0,r.request)("/api/tags");}let N=(0,_.createStyles)(({token:e})=>({mapChart:{height:"452px",paddingTop:"24px",img:{display:"inline-block",maxWidth:"100%",maxHeight:"437px"},[`@media screen and (max-width: ${e.screenLG}px)`]:{height:"auto"}}})),{Countdown:T}=j.default,B=Date.now()+1728e5+3e4,M=()=>{let{styles:e}=N(),{loading:t,data:a}=(0,r.useRequest)(z),l=((null==a?void 0:a.list)||[]).map(e=>({id:+Date.now(),word:e.name,weight:e.value}));return(0,i.jsxs)(n.GridContent,{children:[(0,i.jsxs)(m.default,{gutter:24,children:[(0,i.jsx)(u.default,{xl:18,lg:24,md:24,sm:24,xs:24,style:{marginBottom:24},children:(0,i.jsxs)(c.default,{title:"\u6D3B\u52A8\u5B9E\u65F6\u4EA4\u6613\u60C5\u51B5",bordered:!1,children:[(0,i.jsxs)(m.default,{children:[(0,i.jsx)(u.default,{md:6,sm:12,xs:24,children:(0,i.jsx)(j.default,{title:"\u4ECA\u65E5\u4EA4\u6613\u603B\u989D",suffix:"\u5143",value:(0,y.default)(124543233).format("0,0")})}),(0,i.jsx)(u.default,{md:6,sm:12,xs:24,children:(0,i.jsx)(j.default,{title:"\u9500\u552E\u76EE\u6807\u5B8C\u6210\u7387",value:"92%"})}),(0,i.jsx)(u.default,{md:6,sm:12,xs:24,children:(0,i.jsx)(T,{title:"\u6D3B\u52A8\u5269\u4F59\u65F6\u95F4",value:B,format:"HH:mm:ss:SSS"})}),(0,i.jsx)(u.default,{md:6,sm:12,xs:24,children:(0,i.jsx)(j.default,{title:"\u6BCF\u79D2\u4EA4\u6613\u603B\u989D",suffix:"\u5143",value:(0,y.default)(234).format("0,0")})})]}),(0,i.jsx)("div",{className:e.mapChart,children:(0,i.jsx)(F,{})})]})}),(0,i.jsxs)(u.default,{xl:6,lg:24,md:24,sm:24,xs:24,children:[(0,i.jsx)(c.default,{title:"\u6D3B\u52A8\u60C5\u51B5\u9884\u6D4B",style:{marginBottom:24},bordered:!1,children:(0,i.jsx)(C,{})}),(0,i.jsx)(c.default,{title:"\u5238\u6838\u6548\u7387",style:{marginBottom:24},bodyStyle:{textAlign:"center"},bordered:!1,children:(0,i.jsx)(d.Gauge,{height:180,data:{target:80,total:100,name:"score",thresholds:[20,40,60,80,100]},padding:-16,style:{textContent:()=>"\u4F18"},meta:{color:{range:["#6395FA","#62DAAB","#657798","#F7C128","#1F8718"]}}})})]})]}),(0,i.jsxs)(m.default,{gutter:24,children:[(0,i.jsx)(u.default,{xl:12,lg:24,sm:24,xs:24,style:{marginBottom:24},children:(0,i.jsx)(c.default,{title:"\u5404\u54C1\u7C7B\u5360\u6BD4",bordered:!1,children:(0,i.jsxs)(m.default,{style:{padding:"16px 0"},children:[(0,i.jsx)(u.default,{span:8,children:(0,i.jsx)(f.default,{type:"dashboard",percent:75})}),(0,i.jsx)(u.default,{span:8,children:(0,i.jsx)(f.default,{type:"dashboard",percent:48})}),(0,i.jsx)(u.default,{span:8,children:(0,i.jsx)(f.default,{type:"dashboard",percent:33})})]})})}),(0,i.jsx)(u.default,{xl:6,lg:12,sm:24,xs:24,style:{marginBottom:24},children:(0,i.jsx)(c.default,{title:"\u70ED\u95E8\u641C\u7D22",loading:t,bordered:!1,bodyStyle:{overflow:"hidden"},children:(0,i.jsx)(d.WordCloud,{data:l,height:162,textField:"word",colorField:"word",layout:{spiral:"rectangular",fontSize:[10,20]}})})}),(0,i.jsx)(u.default,{xl:6,lg:12,sm:24,xs:24,style:{marginBottom:24},children:(0,i.jsx)(c.default,{title:"\u8D44\u6E90\u5269\u4F59",bodyStyle:{textAlign:"center",fontSize:0},bordered:!1,children:(0,i.jsx)(d.Liquid,{height:160,percent:.35})})})]})]});};}}]);
|
|
//# sourceMappingURL=8aa2681b-async.ebab497b.js.map
|