diff --git a/gui/src/components/dynamic_components.vue b/gui/src/components/dynamic_components.vue index 4ab3f491..b5507f38 100644 --- a/gui/src/components/dynamic_components.vue +++ b/gui/src/components/dynamic_components.vue @@ -38,6 +38,7 @@ import { Scatter } from "vue-chartjs"; let count = ref(0); let grid = null; // DO NOT use ref(null) as proxies GS will break all logic when comparing structures... see https://github.com/gridstack/gridstack.js/issues/2115 let items = ref([]); +let gridEnabledLocal = ref(true); class gridWidget { //Contains the vue component component2; @@ -431,7 +432,13 @@ function remove(widget) { grid.removeWidget(selector, false); saveGridLayout(); } - +function disableGrid() { + gridEnabledLocal.value = !gridEnabledLocal.value + if (gridEnabledLocal.value) + grid.enable(); + else + grid.disable(); +} function clearAllItems() { grid.removeAll(false); count.value = 0; @@ -480,6 +487,7 @@ function quickfill() { @@ -497,7 +505,14 @@ function quickfill() { >
- Manage grid widgets + Manage grid widgets   
-
-   +
  +