save
This commit is contained in:
parent
13b628904a
commit
6d9ddcf23b
Binary file not shown.
After Width: | Height: | Size: 18 KiB |
|
@ -1,5 +1,35 @@
|
||||||
import { defineComponent } from 'vue'
|
import { defineComponent } from 'vue'
|
||||||
|
import useWeatherStore from './useWeatherStore'
|
||||||
|
|
||||||
export default defineComponent(() => {
|
export default defineComponent(() => {
|
||||||
return () => <div class="w-full h-full bg-red-50"></div>
|
const weather = useWeatherStore()
|
||||||
|
|
||||||
|
return () => (
|
||||||
|
<div class="w-full h-full bg-[#ecfbff] ">
|
||||||
|
<div class={'z-10 relative flex justify-between px-3 py-3 items-center text-white'}>
|
||||||
|
<span class="text-[26px] font-din font-bold">{weather.weatherData?.base.stemp}°</span>
|
||||||
|
<div class="flex flex-col gap-y-[1px]">
|
||||||
|
<div class="flex items-center gap-x-1">
|
||||||
|
<span class="font-bold text-[14px] leading-[14px]">
|
||||||
|
{weather.weatherData?.city.name}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<span class={'tracking-tight flex gap-x-1 items-center'}>
|
||||||
|
<span class="text-[12px]">
|
||||||
|
{weather.weatherData?.base.ltemp}°/{weather.weatherData?.base.htemp}°
|
||||||
|
</span>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<span class="text-[12px]">{weather.weatherData?.base.weather}</span>
|
||||||
|
</div>
|
||||||
|
<div
|
||||||
|
class={'w-full h-[73px] absolute left-0 top-0 '}
|
||||||
|
style={{
|
||||||
|
backgroundImage: `url('/weather_img/img/weather_bg_mdeium.webp')`,
|
||||||
|
backgroundRepeat: 'no-repeat',
|
||||||
|
backgroundSize: '100%'
|
||||||
|
}}
|
||||||
|
></div>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
})
|
})
|
||||||
|
|
|
@ -5,7 +5,7 @@ export default defineComponent(() => {
|
||||||
const weather = useWeatherStore()
|
const weather = useWeatherStore()
|
||||||
return () => (
|
return () => (
|
||||||
<div
|
<div
|
||||||
class="w-full h-full items-center px-3 gap-x-3 flex py-3 text-white"
|
class="w-full h-full items-center pl-3 gap-x-2 flex py-3 text-white"
|
||||||
style={{
|
style={{
|
||||||
background: 'linear-gradient(135deg,#5996ff 0%,#4862ff 100%)'
|
background: 'linear-gradient(135deg,#5996ff 0%,#4862ff 100%)'
|
||||||
}}
|
}}
|
||||||
|
@ -16,9 +16,8 @@ export default defineComponent(() => {
|
||||||
<div class="flex items-center gap-x-1">
|
<div class="flex items-center gap-x-1">
|
||||||
<span class="font-bold text-[14px] leading-[14px]">{weather.weatherData?.city.name}</span>
|
<span class="font-bold text-[14px] leading-[14px]">{weather.weatherData?.city.name}</span>
|
||||||
</div>
|
</div>
|
||||||
<span>
|
<span class={'tracking-tight flex gap-x-1 items-center'}>
|
||||||
<span class="text-[12px]">{weather.weatherData?.base.weather}</span>
|
<span class="text-[12px]">{weather.weatherData?.base.weather}</span>
|
||||||
 
|
|
||||||
<span class="text-[12px]">
|
<span class="text-[12px]">
|
||||||
{weather.weatherData?.base.ltemp}°/{weather.weatherData?.base.htemp}°
|
{weather.weatherData?.base.ltemp}°/{weather.weatherData?.base.htemp}°
|
||||||
</span>
|
</span>
|
||||||
|
|
Loading…
Reference in New Issue