diff --git a/Dockerfile b/Dockerfile index d191c41ecf..09458f0c80 100644 --- a/Dockerfile +++ b/Dockerfile @@ -33,7 +33,10 @@ COPY package.json package.json COPY yarn.lock yarn.lock COPY packages packages +ARG NODE_OPTIONS=--max-old-space-size=4096 + # Build the client bundles +RUN echo "Building with NODE_OPTIONS=$NODE_OPTIONS" RUN yarn \ && yarn nx bundle:npm @veupathdb/clinepi-site \ && yarn nx bundle:npm @veupathdb/genomics-site \ diff --git a/docker-compose.yml b/docker-compose.yml index fe0b0d19d6..13c97ce4c9 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,7 +1,5 @@ version: "3.5" -name: "web-client" - networks: traefik: external: true diff --git a/packages/libs/components/src/plots/VolcanoPlot.tsx b/packages/libs/components/src/plots/VolcanoPlot.tsx index 68288f233c..c117697b2e 100755 --- a/packages/libs/components/src/plots/VolcanoPlot.tsx +++ b/packages/libs/components/src/plots/VolcanoPlot.tsx @@ -363,11 +363,17 @@ function VolcanoPlot(props: VolcanoPlotProps, ref: Ref) { }} >
; diff --git a/packages/libs/eda/src/lib/core/components/visualizations/implementations/VolcanoPlotVisualization.tsx b/packages/libs/eda/src/lib/core/components/visualizations/implementations/VolcanoPlotVisualization.tsx index db2e229fd6..808de911b2 100755 --- a/packages/libs/eda/src/lib/core/components/visualizations/implementations/VolcanoPlotVisualization.tsx +++ b/packages/libs/eda/src/lib/core/components/visualizations/implementations/VolcanoPlotVisualization.tsx @@ -52,6 +52,7 @@ import SliderWidget, { } from '@veupathdb/components/lib/components/widgets/Slider'; import { ResetButtonCoreUI } from '../../ResetButton'; import AxisRangeControl from '@veupathdb/components/lib/components/plotControls/AxisRangeControl'; +import { fixVarIdLabel } from '../../../utils/visualization'; // end imports const DEFAULT_SIG_THRESHOLD = 0.05; @@ -270,9 +271,18 @@ function VolcanoPlotViz(props: VisualizationProps) { */ .map((d) => { const { pointID, ...remainingProperties } = d; + // Try to find a user-friendly label for the point. Note that pointIDs are in entityID.variableID format. + const displayLabel = + pointID && + fixVarIdLabel( + pointID.split('.')[1], + pointID.split('.')[0], + entities + ); return { ...remainingProperties, pointIDs: pointID ? [pointID] : undefined, + displayLabels: displayLabel ? [displayLabel] : undefined, significanceColor: assignSignificanceColor( Number(d.log2foldChange), Number(d.pValue), @@ -299,7 +309,7 @@ function VolcanoPlotViz(props: VisualizationProps) { if (foundIndex === -1) { aggregatedData.push(entry); } else { - const { pointIDs } = aggregatedData[foundIndex]; + const { pointIDs, displayLabels } = aggregatedData[foundIndex]; if (pointIDs) { aggregatedData[foundIndex] = { ...aggregatedData[foundIndex], @@ -307,11 +317,16 @@ function VolcanoPlotViz(props: VisualizationProps) { ...pointIDs, ...(entry.pointIDs ? entry.pointIDs : []), ], + displayLabels: displayLabels && [ + ...displayLabels, + ...(entry.displayLabels ? entry.displayLabels : []), + ], }; } else { aggregatedData[foundIndex] = { ...aggregatedData[foundIndex], pointIDs: entry.pointIDs, + displayLabels: entry.displayLabels, }; } } diff --git a/packages/libs/wdk-client/src/Utils/UserPreferencesUtils.ts b/packages/libs/wdk-client/src/Utils/UserPreferencesUtils.ts index 996425c9c3..77a3baf996 100644 --- a/packages/libs/wdk-client/src/Utils/UserPreferencesUtils.ts +++ b/packages/libs/wdk-client/src/Utils/UserPreferencesUtils.ts @@ -65,7 +65,9 @@ export async function getResultTableColumnsPref( const [knownColumns, unknownColumns] = partition( columns, - (columnName) => columnName in recordClass.attributesMap + (columnName) => + recordClass.attributes.some((a) => a.name === columnName) || + question.dynamicAttributes.some((a) => a.name === columnName) ); if (unknownColumns.length > 0) {