+
+
+
+
-
-
-
-
- {{ parseFloat(sensors.temperature).toFixed(1) + '°' }}
-
-
+
-
-
-
- {{ parseFloat(sensors.humidity).toFixed(1) + '%' }}
-
+
+
+
@@ -32,88 +30,128 @@
@@ -126,42 +164,27 @@ export default {
align-items: center;
padding-top: 0.1em;
- .date {
- font-size: 1.3em;
- height: 10%;
+ .row {
+ text-align: center;
}
- .time {
- font-size: 2em;
- height: 14%;
+ .date-time-container {
+ height: 40%;
}
- .weather {
- height: 25%;
- display: flex;
- align-items: center;
- margin-top: 15%;
-
- .temperature {
- font-size: 3.1em;
- margin-left: 0.4em;
- }
+ .weather-container {
+ height: 40%;
}
- .summary {
- height: 28%;
- }
-
- .sensors {
+ .sensors-container {
width: 100%;
- height: 13%;
+ height: 20%;
+ position: relative;
- .sensor {
- padding: 0 0.1em;
- }
-
- .humidity {
- text-align: right;
+ .row {
+ width: 100%;
+ position: absolute;
+ bottom: 0;
}
}
}
diff --git a/platypush/backend/http/webapp/src/widgets/Weather/Index.vue b/platypush/backend/http/webapp/src/widgets/Weather/Index.vue
new file mode 100644
index 000000000..8a9ceef21
--- /dev/null
+++ b/platypush/backend/http/webapp/src/widgets/Weather/Index.vue
@@ -0,0 +1,114 @@
+
+
+
+
+
+
+
+ {{ Math.round(parseFloat(weather.temperature)) + '°' }}
+
+
+
+
+
+
+
+
+
+
diff --git a/platypush/backend/http/webapp/src/widgets/Widget.vue b/platypush/backend/http/webapp/src/widgets/Widget.vue
index 7038faa00..de8a2cd8e 100644
--- a/platypush/backend/http/webapp/src/widgets/Widget.vue
+++ b/platypush/backend/http/webapp/src/widgets/Widget.vue
@@ -15,7 +15,11 @@ export default {
.widget {
background: $background-color;
border-radius: 5px;
- margin-bottom: 1em;
+ margin: 0 1em 1em 0;
+ display: flex;
+ justify-content: center;
+ align-content: center;
+ position: relative;
overflow: hidden;
box-shadow: 0 3px 3px 0 rgba(0,0,0,0.16), 0 0 0 1px rgba(0,0,0,0.08);
}