From c38b50911db28fec4d0a78f96e129ab6a506811e Mon Sep 17 00:00:00 2001 From: Devon Doyle Date: Sat, 31 Aug 2024 18:22:07 -0400 Subject: [PATCH] [photon-client] Log Viewer Improvements (#1385) Fixes the following issues with the client log viewer: - Inconsistent and excessive spacing between log entries - Lack of responsiveness to window size or scaling Adds the following features to the log viewer: - Auto-scroll if scrolled to the bottom - Ability to clear logs on button click - Search function to filter logs - Displays the time the frontend captured a log and displays that timestamp in hh::mm::ss in the log viewer - Allows logs to be filtered to be after a certain time - General styling refinements to increase usability --------- Co-authored-by: Sriman Achanta <68172138+srimanachanta@users.noreply.github.com> --- photon-client/package-lock.json | 6 + photon-client/package.json | 1 + .../components/app/photon-camera-stream.vue | 2 +- .../src/components/app/photon-log-entry.vue | 24 ++ .../src/components/app/photon-log-view.vue | 220 ++++++++++++------ .../cameras/CameraCalibrationCard.vue | 8 +- .../components/settings/DeviceControlCard.vue | 4 +- photon-client/src/types/SettingTypes.ts | 1 + 8 files changed, 187 insertions(+), 79 deletions(-) create mode 100644 photon-client/src/components/app/photon-log-entry.vue diff --git a/photon-client/package-lock.json b/photon-client/package-lock.json index b69edce11..53c926e5d 100644 --- a/photon-client/package-lock.json +++ b/photon-client/package-lock.json @@ -17,6 +17,7 @@ "three": "^0.160.0", "vue": "^2.7.14", "vue-router": "^3.6.5", + "vue-virtual-scroll-list": "^2.3.5", "vuetify": "^2.7.1" }, "devDependencies": { @@ -5341,6 +5342,11 @@ "resolved": "https://registry.npmjs.org/vue-router/-/vue-router-3.6.5.tgz", "integrity": "sha512-VYXZQLtjuvKxxcshuRAwjHnciqZVoXAjTjcqBTz4rKc8qih9g9pI3hbDjmqXaHdgL3v8pV6P8Z335XvHzESxLQ==" }, + "node_modules/vue-virtual-scroll-list": { + "version": "2.3.5", + "resolved": "https://registry.npmjs.org/vue-virtual-scroll-list/-/vue-virtual-scroll-list-2.3.5.tgz", + "integrity": "sha512-YFK6u5yltqtAOfTBcij/KGAS2SoZvzbNIAf9qTULauPObEp53xj22tDuohrrM2vNkgoD5kejXICIUBt2Q4ZDqQ==" + }, "node_modules/vuetify": { "version": "2.7.1", "resolved": "https://registry.npmjs.org/vuetify/-/vuetify-2.7.1.tgz", diff --git a/photon-client/package.json b/photon-client/package.json index bd48a1bd0..69a40a299 100644 --- a/photon-client/package.json +++ b/photon-client/package.json @@ -24,6 +24,7 @@ "three": "^0.160.0", "vue": "^2.7.14", "vue-router": "^3.6.5", + "vue-virtual-scroll-list": "^2.3.5", "vuetify": "^2.7.1" }, "devDependencies": { diff --git a/photon-client/src/components/app/photon-camera-stream.vue b/photon-client/src/components/app/photon-camera-stream.vue index 34465e938..710fd81b2 100644 --- a/photon-client/src/components/app/photon-camera-stream.vue +++ b/photon-client/src/components/app/photon-camera-stream.vue @@ -63,7 +63,7 @@ onBeforeUnmount(() => {