doc: update HourlyWeather component

This commit is contained in:
Leon Xu committed 2022-02-22 14:21:33 -08:00
1 parent 9dbfb0490b
commit 7b76325dcf
1 file changed
+38 -2
+38 -2
View File
@@ -1,12 +1,48 @@
<template>
<section></section>
<section class="hourly-weather">
<div class="container">
<div
class="hourly-temp"
v-for="(time, index) in filteredList"
:key="index"
>
<HourlyTemp :time="time" />
</div>
</div>
</section>
</template>
<script>
import HourlyTemp from "./HourlyTemp";
export default {
name: "HourlyWeather",
props: ["forecast"],
components: {
HourlyTemp,
},
computed: {
filteredList() {
return this.forecast.hourly.slice(1, 25);
},
},
};
</script>
<style>
<style lang="scss" scoped>
.hourly-weather {
padding: 30px 0;
border-bottom: 1px solid rgba(255, 255, 255, 0.7);
.container {
display: flex;
max-width: 100vw;
overflow: scroll;
padding: 0;
margin: 0 20px;
&::-webkit-scrollbar {
display: none;
}
}
}
</style>