Commit 15c0d92a authored by Téo Vasseur's avatar Téo Vasseur
Browse files

{list,segmenter}.js : empy before appending

parent 46a4d8bf
Pipeline #2834 passed with stages
in 2 minutes and 29 seconds
......@@ -493,6 +493,7 @@ List.prototype = {
var span_axis = div_elem.getElementsByClassName("axisBox")[0];
span_axis.style.color = clone.getColor();
var axis = this.selectedAxis;
span_axis.removeAllChildren();
span_axis.appendChild(axis.pretty ? axis.pretty(axis.fct(clone)) : document.createTextNode(axis.fct(clone)));
// span_axis.setAttribute('title', clone.getPrintableSize());
......
......@@ -627,6 +627,7 @@ Segment.prototype = {
for (var i in this.selectedAxis) {
var span = document.createElement('span');
var axis = this.selectedAxis[i];
span.removeAllChildren();
span.appendChild(axis.pretty ? axis.pretty(axis.fct(clone)) : document.createTextNode(axis.fct(clone)));
span.setAttribute('title', this.selectedAxis[i].label);
span.className = axOpts[i];
......
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