Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e0ba0a5

Browse files
committed
use background color for contrast text on cells with missing data
1 parent 0a23355 commit e0ba0a5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/traces/heatmap/plot.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -535,6 +535,7 @@ module.exports = function(gd, plotinfo, cdheatmaps, heatmapLayer) {
535535
var fontColor = font.color;
536536
if(!fontColor || fontColor === 'auto') {
537537
fontColor = Color.contrast(
538+
d.z === undefined ? gd._fullLayout.plot_bgcolor :
538539
'rgba(' +
539540
sclFunc(d.z).join() +
540541
')'

0 commit comments

Comments
 (0)