From 9bddf82d223aa74d9aca53baed7fdc44c0f6dc99 Mon Sep 17 00:00:00 2001 From: Quashnock Date: Fri, 15 Nov 2024 15:52:04 -0800 Subject: [PATCH 1/3] Changed circle indicators to icons, changed background color of indicator, and added hover effect on navbar items. --- src/components/Navbar.vue | 49 ++++++++++++++++----------------------- 1 file changed, 20 insertions(+), 29 deletions(-) diff --git a/src/components/Navbar.vue b/src/components/Navbar.vue index 5cdf99d..37a8cbd 100644 --- a/src/components/Navbar.vue +++ b/src/components/Navbar.vue @@ -10,6 +10,8 @@ import HomeIcon from 'vue-material-design-icons/Home.vue'; import CameraIcon from 'vue-material-design-icons/Camera.vue'; import TuneIcon from 'vue-material-design-icons/Tune.vue'; import BugIcon from 'vue-material-design-icons/Bug.vue'; +import PowerPlugIcon from 'vue-material-design-icons/PowerPlug.vue'; +import ControllerIcon from 'vue-material-design-icons/ControllerClassic.vue'; import { useRoslibStore } from '../store/useRoslib'; import { useControllerStore } from '../store/useController'; @@ -91,26 +93,17 @@ const pageIconArr: PageIcon = [

{{ pageIcon.label }}

-
-

WebSocket

-
+
+

WS

+
-
-

Camera Feed

-
+
+

CAM

+
-
-

Controller Connected

-
+
+

CTRL

+
- @@ -141,7 +140,7 @@ nav { min-width: 4rem; } .navbar-tab:not(.current-page):hover { - background-color: hsl(0, 0%, 12%); + background-color: hsl(0, 0%, 16%); } #logo { max-width: 100%; diff --git a/src/store/useRoslib.ts b/src/store/useRoslib.ts index 2e598e1..661a857 100644 --- a/src/store/useRoslib.ts +++ b/src/store/useRoslib.ts @@ -11,6 +11,7 @@ const SECONDS_TO_TIMESTAMP = 1000; export const useRoslibStore = defineStore('roslib', () => { const ros = new ROSLIB.Ros({ url: undefined }); const isWebSocketConnected = ref(false); + const latency = ref(0); const stop = ref(false); /** * Initializes Ros, websocket with Rover and runs heartbeat subscribes. Should only be used in App.vue @@ -221,6 +222,7 @@ export const useRoslibStore = defineStore('roslib', () => { return { ros, isWebSocketConnected, + latency, stop, init, createNonStandardTopic, From 19c175b64d46f8c23f179a2d3276a9700a3a7ca9 Mon Sep 17 00:00:00 2001 From: Quashnock Date: Fri, 15 Nov 2024 21:03:27 -0800 Subject: [PATCH 3/3] Ran git pull, git run format, changed number case. --- src/components/Navbar.vue | 35 ++++++++++++++++++++++++++++------- src/store/useRoslib.ts | 2 +- 2 files changed, 29 insertions(+), 8 deletions(-) diff --git a/src/components/Navbar.vue b/src/components/Navbar.vue index a246ff2..ce3be18 100644 --- a/src/components/Navbar.vue +++ b/src/components/Navbar.vue @@ -93,21 +93,42 @@ const pageIconArr: PageIcon = [

{{ pageIcon.label }}

-
+

WS

- +
-
+

CAM

- +
-
+

CTRL

- +

Ping

-

{{ roslib.latency + "ms" }}

+

{{ roslib.latency + 'ms' }}

diff --git a/src/store/useRoslib.ts b/src/store/useRoslib.ts index 4280de2..6e61da9 100644 --- a/src/store/useRoslib.ts +++ b/src/store/useRoslib.ts @@ -10,7 +10,7 @@ const SECONDS_TO_TIMESTAMP = 1000; export const useRoslibStore = defineStore('roslib', () => { const ros = new ROSLIB.Ros({ url: undefined }); const isWebSocketConnected = ref(false); - const latency = ref(0); + const latency = ref(0); const stop = { value: false }; /**