Closed
Description
Description
When drawing multiple data in a chart, some of tooltips are not shown normally as below.
In this screenshot, the text undefineddownload300
is the tooltip...
I found that <table><tr><th></th></tr>
tag is missing in the tooltip element. I think that It occurred when some of fields in the data is undefined
or null
.
{name: "data1", upload: 200 }, // "download" field is undefined
{name: "data2", upload: 100, download: 300}, // OK
{name: "data3", upload: null, download: 300} // "upload" field is null
Should I modify my data not to have null
or undefined
?
Or Could I or someone make a patch for fixing it?
Steps to check or reproduce
var chart = bb.generate({
data: {
columns: [
["data1", 30, 200, null, 400, 150, 250],
["data2", 50, 20, 10, 40, null, 25]
]
},
bindto: "#chart"
});
in case of JSON
data
var chart = bb.generate({
bindto: "#chart",
data: {
json: [{
name: "data1",
upload: 200
},
{
name: "data2",
upload: 100,
download: 300
},
{
name: "data3",
download: 300
}
],
keys: {
x: "name",
value: ["upload", "download"],
}
},
axis: {
x: {
type: "category"
}
}
});