From 083e922e89e05f34fd1707333099de37f85dd610 Mon Sep 17 00:00:00 2001 From: Stefan Dej Date: Sun, 22 Oct 2023 18:37:39 +0200 Subject: [PATCH 1/4] feat: add option to hide parts of the ToolheadPanel Signed-off-by: Stefan Dej --- .../panels/ToolheadControlPanel.vue | 23 ++++- .../panels/ToolheadControls/MoveToControl.vue | 12 ++- .../ToolheadPanelSettings.vue | 98 +++++++++++++++++++ src/store/gui/index.ts | 7 ++ src/store/gui/types.ts | 7 ++ 5 files changed, 141 insertions(+), 6 deletions(-) create mode 100644 src/components/panels/ToolheadControls/ToolheadPanelSettings.vue diff --git a/src/components/panels/ToolheadControlPanel.vue b/src/components/panels/ToolheadControlPanel.vue index 25d0277c3..ccb104dea 100644 --- a/src/components/panels/ToolheadControlPanel.vue +++ b/src/components/panels/ToolheadControlPanel.vue @@ -82,6 +82,7 @@ + @@ -90,13 +91,13 @@ - - + + - - + + diff --git a/src/components/panels/ToolheadControls/MoveToControl.vue b/src/components/panels/ToolheadControls/MoveToControl.vue index 22cbb3588..8c4b539b8 100644 --- a/src/components/panels/ToolheadControls/MoveToControl.vue +++ b/src/components/panels/ToolheadControls/MoveToControl.vue @@ -8,7 +8,7 @@ }"> + + diff --git a/src/store/gui/index.ts b/src/store/gui/index.ts index 47512562c..806224056 100644 --- a/src/store/gui/index.ts +++ b/src/store/gui/index.ts @@ -252,6 +252,13 @@ export const getDefaultState = (): GuiState => { currentPath: 'timelapse', selectedFiles: [], }, + toolhead: { + showPosition: true, + showCoordinates: true, + showControl: true, + showZOffset: true, + showSpeedFactor: true, + }, webcam: { currentCam: { dashboard: 'all', diff --git a/src/store/gui/types.ts b/src/store/gui/types.ts index 7ad7e9124..a660abc20 100644 --- a/src/store/gui/types.ts +++ b/src/store/gui/types.ts @@ -178,6 +178,13 @@ export interface GuiState { currentPath: string selectedFiles: FileStateFile[] } + toolhead: { + showPosition: boolean + showCoordinates: boolean + showControl: boolean + showZOffset: boolean + showSpeedFactor: boolean + } webcam: { currentCam: { dashboard: string From 2264e4b8ee6128b414c46c78cead8487c12443f4 Mon Sep 17 00:00:00 2001 From: Stefan Dej Date: Wed, 25 Oct 2023 23:23:33 +0200 Subject: [PATCH 2/4] fix: display issues with different open sections Signed-off-by: Stefan Dej --- .../panels/ToolheadControlPanel.vue | 10 +++--- .../panels/ToolheadControls/MoveToControl.vue | 32 ++++++++++++------- 2 files changed, 25 insertions(+), 17 deletions(-) diff --git a/src/components/panels/ToolheadControlPanel.vue b/src/components/panels/ToolheadControlPanel.vue index ccb104dea..910063e30 100644 --- a/src/components/panels/ToolheadControlPanel.vue +++ b/src/components/panels/ToolheadControlPanel.vue @@ -85,13 +85,13 @@ - + - + @@ -174,15 +174,15 @@ export default class ToolheadControlPanel extends Mixins(BaseMixin, ControlMixin return this.existsBedScrews || this.existsBedTilt || this.existsDeltaCalibrate || this.existsScrewsTilt } - get showControl() { + get showControl(): boolean { return this.$store.state.gui.view.toolhead.showControl ?? true } - get showZOffset() { + get showZOffset(): boolean { return this.$store.state.gui.view.toolhead.showZOffset ?? true } - get showSpeedFactor() { + get showSpeedFactor(): boolean { return this.$store.state.gui.view.toolhead.showSpeedFactor ?? true } } diff --git a/src/components/panels/ToolheadControls/MoveToControl.vue b/src/components/panels/ToolheadControls/MoveToControl.vue index 8c4b539b8..7188be5c9 100644 --- a/src/components/panels/ToolheadControls/MoveToControl.vue +++ b/src/components/panels/ToolheadControls/MoveToControl.vue @@ -1,13 +1,13 @@