Commit 19b90de3 authored by flothoni's avatar flothoni
Browse files

graph.js; update tooltip content

Show date only if present
Ass number of reads
Link to #4370
parent f3a88137
......@@ -1473,6 +1473,7 @@ Graph.prototype = {
var time = d.time
var tooltip = self.getTooltip(time, true, true)
div.transition()
.delay(1000)
.duration(200)
.style("opacity", 1);
div .html(tooltip)
......@@ -1641,8 +1642,15 @@ Graph.prototype = {
}
var tooltip = "";
tooltip += this.m.getStrTime(time, "names")
tooltip += breakChar + this.m.getStrTime(time, "sampling_date")
tooltip += breakChar + this.m.getStrTime(time, "delta_date")
var sampling_date = this.m.getStrTime(time, "sampling_date")
var delta_date = this.m.getStrTime(time, "delta_date")
tooltip += ( (sampling_date != "-/-") ? (breakChar + sampling_date) : "" )
tooltip += ( (delta_date != "-/-") ? (breakChar + delta_date) : "" )
// duplicate from info; refactor
var read_number = this.m.reads.segmented
var percent = (read_number[this.m.t] / this.m.reads.total[this.m.t]) * 100;
var reads = this.m.toStringThousands(read_number[this.m.t]) + " (" + percent.toFixed(2) + "%)";
tooltip += breakChar + reads
return tooltip
},
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment