diff --git a/web/frontend/src/Job.root.svelte b/web/frontend/src/Job.root.svelte index b4913e6..cb537ec 100644 --- a/web/frontend/src/Job.root.svelte +++ b/web/frontend/src/Job.root.svelte @@ -1,5 +1,5 @@
diff --git a/web/frontend/src/PlotTable.svelte b/web/frontend/src/PlotTable.svelte index 24b851b..eda3fd3 100644 --- a/web/frontend/src/PlotTable.svelte +++ b/web/frontend/src/PlotTable.svelte @@ -24,14 +24,13 @@ else row.push({ _is_placeholder: true, ri, ci }) } - rows.push(row) } return rows } - $: rows = tile(items, itemsPerRow) + $: rows = tile(items.filter(item => item.disabled === false), itemsPerRow) $: plotWidth = (tableWidth / itemsPerRow) - (padding * itemsPerRow) diff --git a/web/frontend/src/utils.js b/web/frontend/src/utils.js index 2112d21..296b587 100644 --- a/web/frontend/src/utils.js +++ b/web/frontend/src/utils.js @@ -296,3 +296,20 @@ export function stickyHeader(datatableHeaderSelector, updatePading) { document.addEventListener("scroll", onscroll); onDestroy(() => document.removeEventListener("scroll", onscroll)); } + +export function checkMetricDisabled(m, c, s) { //[m]etric, [c]luster, [s]ubcluster + const mc = getContext("metrics"); + const thisConfig = mc(c, m); + let thisSCIndex = -1; + if (thisConfig) { + thisSCIndex = thisConfig.subClusters.findIndex( + (subcluster) => subcluster.name == s + ); + }; + if (thisSCIndex >= 0) { + if (thisConfig.subClusters[thisSCIndex].remove == true) { + return true; + } + } + return false; +}