Skip to content

Commit e077ec9

Browse files
Norum EidesenNorum Eidesen
authored andcommitted
v1 done
1 parent d9ff09c commit e077ec9

File tree

3 files changed

+20
-19
lines changed

3 files changed

+20
-19
lines changed

business-app/src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ export default {
2222
-webkit-font-smoothing: antialiased;
2323
-moz-osx-font-smoothing: grayscale;
2424
text-align: center;
25-
color: #2c3e50;
25+
color: #0f204b;
2626
margin-top: 60px;
2727
}
2828
</style>

business-app/src/components/Home.vue

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,27 @@
1212
/>
1313
</div>
1414
<div class="weather-now temp-now">
15-
20°
15+
{{ weatherData[0]['data']['instant']['details']['air_temperature']}}°
1616
</div>
1717
<div class="weather-now detailsWeatherNow">
18-
<div class="weather-now detailsWeatherNow percipitation">Regn: 2%</div>
19-
<div class="weather-now detailsWeatherNow humidity">Fuktighet: 6%</div>
20-
<div class="weather-now detailsWeatherNow wind">Vind: 4 m/s</div>
18+
<div class="weather-now detailsWeatherNow percipitation">Regn: {{ weatherData[0]['data']['next_1_hours']['details']['precipitation_amount']}} mm</div>
19+
<div class="weather-now detailsWeatherNow humidity">Fuktighet: {{ weatherData[0]['data']['instant']['details']['relative_humidity']}}%</div>
20+
<div class="weather-now detailsWeatherNow wind">Vind: {{ weatherData[0]['data']['instant']['details']['wind_speed']}} m/s</div>
2121
</div>
2222
</div>
2323
<div class="temperature-graph">
2424
<WeatherGraph
2525
:temperatureDataToPlot="[
26-
{ time: '00:00', temperature: -3.9 },
27-
{ time: '00:02', temperature: -4.1 },
28-
{ time: '00:03', temperature: 3.8 },
29-
{ time: '00:04', temperature: 3.5 },
30-
{ time: '00:05', temperature: 4.2 },
31-
{ time: '00:06', temperature: 4.4 },
32-
{ time: '00:07', temperature: 3.9 },
33-
{ time: '00:08', temperature: 4.2 },
34-
{ time: '00:09', temperature: 5.4 },
35-
{ time: '00:10', temperature: 5.9 },
26+
{ time: weatherData[0]['time'].slice(11,16), temperature: weatherData[0]['data']['instant']['details']['air_temperature'] },
27+
{ time: weatherData[1]['time'].slice(11,16), temperature: weatherData[1]['data']['instant']['details']['air_temperature'] },
28+
{ time: weatherData[2]['time'].slice(11,16), temperature: weatherData[2]['data']['instant']['details']['air_temperature'] },
29+
{ time: weatherData[3]['time'].slice(11,16), temperature: weatherData[3]['data']['instant']['details']['air_temperature'] },
30+
{ time: weatherData[4]['time'].slice(11,16), temperature: weatherData[4]['data']['instant']['details']['air_temperature'] },
31+
{ time: weatherData[5]['time'].slice(11,16), temperature: weatherData[5]['data']['instant']['details']['air_temperature'] },
32+
{ time: weatherData[6]['time'].slice(11,16), temperature: weatherData[6]['data']['instant']['details']['air_temperature'] },
33+
{ time: weatherData[7]['time'].slice(11,16), temperature: weatherData[7]['data']['instant']['details']['air_temperature'] },
34+
{ time: weatherData[8]['time'].slice(11,16), temperature: weatherData[8]['data']['instant']['details']['air_temperature'] },
35+
{ time: weatherData[9]['time'].slice(11,16), temperature: weatherData[9]['data']['instant']['details']['air_temperature'] },
3636
]"
3737
/>
3838
</div>
@@ -356,7 +356,7 @@ export default {
356356
align-content: stretch;
357357
align-items: flex-start;
358358
height: 50%;
359-
width: 6em;
359+
width: 8em;
360360
}
361361
362362
.iconWeatherNow {

business-app/src/components/WeatherGraph.vue

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@
22
<!-- use a function to determine the max and min bound -->
33
<la-cartesian
44
:width="750"
5-
:height="100"
6-
:bound="[-15, (n) => n + 10]"
5+
:height="140"
6+
:bound="[-1, (n) => n + 2]"
77
:data="temperatureDataToPlot"
88
>
99
<la-area prop="temperature"
1010
animated
11-
curve="curveBumpX">
11+
curve="curveBumpX"
12+
color="#1890ff">
1213
<!-- <la-area
1314
prop="temperature"
1415
color="goldenrod"

0 commit comments

Comments
 (0)