Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Commit 6a4e084

Browse files
committed
minor fixes
1 parent 0e8325b commit 6a4e084

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

frontend/src/discovery.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,12 +71,16 @@ function visualizeFrequency(data) {
7171
try {
7272
let style = mxgraph.mxUtils.setStyle(activityCurrentStyle, 'fillColor', myFrequencyScale(freqValue))
7373
mxGraph.getModel().setStyle(activityCell, style);
74-
activityCurrentStyle = mxGraph.getModel().getStyle(activityCell)
75-
74+
//different way of setting the style
75+
//mxGraph.setCellStyles("fillColor", myFrequencyScale(freqValue), [activityCell]);
76+
7677
//set label to white when the activity fillColor is above the scale average
7778
if (freqValue > avg){
79+
activityCurrentStyle = mxGraph.getModel().getStyle(activityCell)
7880
style = mxgraph.mxUtils.setStyle(activityCurrentStyle, 'fontColor', 'white')
7981
mxGraph.getModel().setStyle(activityCell, style);
82+
//different way of setting the style
83+
//mxGraph.setCellStyles("fontColor", "white", [activityCell]);
8084
}
8185
} finally {
8286
mxGraph.getModel().endUpdate();

0 commit comments

Comments
 (0)