From 497d63ef7d94ed497b87574d5046f88a90732eb6 Mon Sep 17 00:00:00 2001 From: LouisLam Date: Sat, 26 Jun 2021 03:03:06 +0800 Subject: [PATCH] implementing heartbeat bar --- server/server.js | 2 +- src/assets/app.scss | 23 ------- src/components/HeartbeatBar.vue | 110 ++++++++++++++++++++++++++++++++ src/pages/Details.vue | 53 +-------------- 4 files changed, 114 insertions(+), 74 deletions(-) create mode 100644 src/components/HeartbeatBar.vue diff --git a/server/server.js b/server/server.js index a3d10dddb..e30f6e7e0 100644 --- a/server/server.js +++ b/server/server.js @@ -167,7 +167,7 @@ let monitorList = {}; callback({ ok: true, - msg: "Paused Successfully." + msg: "Resumed Successfully." }); } catch (e) { diff --git a/src/assets/app.scss b/src/assets/app.scss index a17e18840..980af5011 100644 --- a/src/assets/app.scss +++ b/src/assets/app.scss @@ -31,27 +31,4 @@ } } -.hp-bar-big { - white-space: nowrap; - margin-top: 4px; - text-align: center; - direction: rtl; - margin-bottom: 10px; - transition: all ease-in-out 0.15s; - position: relative; - div { - display: inline-block; - background-color: $primary; - width: 1%; - height: 30px; - margin: 0.3%; - border-radius: 50rem; - transition: all ease-in-out 0.15s; - - &:hover { - opacity: 0.8; - transform: scale(1.5); - } - } -} diff --git a/src/components/HeartbeatBar.vue b/src/components/HeartbeatBar.vue new file mode 100644 index 000000000..544b76f18 --- /dev/null +++ b/src/components/HeartbeatBar.vue @@ -0,0 +1,110 @@ + + + + + diff --git a/src/pages/Details.vue b/src/pages/Details.vue index d1e04d1c3..c5d263d9d 100644 --- a/src/pages/Details.vue +++ b/src/pages/Details.vue @@ -11,56 +11,7 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -85,9 +36,11 @@ import { useToast } from 'vue-toastification' const toast = useToast() import Confirm from "../components/Confirm.vue"; +import HeartbeatBar from "../components/HeartbeatBar.vue"; export default { components: { + HeartbeatBar, Confirm }, mounted() {