This commit is contained in:
mei
2026-08-11 10:03:40 +08:00
parent 2086bd79cc
commit fb326279fa
25 changed files with 2590 additions and 2379 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
import React, { useState, useEffect } from 'react'
import { Tag, Spin, Tooltip } from 'antd'
import { CloudOutlined, SunOutlined, CloudRain, ThunderboltOutlined } from '@ant-design/icons'
import { CloudOutlined, SunOutlined, ThunderboltOutlined } from '@ant-design/icons'
import axios from 'axios'
function Weather() {
@@ -27,7 +27,7 @@ function Weather() {
const getWeatherIcon = (code) => {
if (code === 0) return <SunOutlined style={{ color: '#faad14' }} />
if ([95, 96, 99].includes(code)) return <ThunderboltOutlined style={{ color: '#722ed1' }} />
if ([61, 63, 65, 80, 81, 82].includes(code)) return <CloudRainOutlined style={{ color: '#1890ff' }} />
if ([61, 63, 65, 80, 81, 82].includes(code)) return <CloudOutlined style={{ color: '#1890ff' }} />
return <CloudOutlined style={{ color: '#8c8c8c' }} />
}