mirror of
https://github.com/Karaka-Management/jsOMS.git
synced 2026-01-11 17:58:41 +00:00
cleanup and tests added for ci/cd
This commit is contained in:
parent
fd791cca05
commit
da4032f5d6
|
|
@ -57,6 +57,7 @@
|
|||
visible: true
|
||||
}
|
||||
};
|
||||
|
||||
this.chart.subtype = 'candlestick';
|
||||
};
|
||||
|
||||
|
|
@ -105,7 +106,7 @@
|
|||
.attr("y", function(d) { return y(Math.max(d.open, d.close)); })
|
||||
.attr("height", function(d) { return Math.max(1, y(Math.min(d.open, d.close)) - y(Math.max(d.open, d.close)));})
|
||||
.attr("width", function(d) { return 0.5 * mm; })
|
||||
.attr("fill",function(d) { return d.open > d.close ? "red" : "green" ;});
|
||||
.attr("fill",function(d) { return d.open > d.close ? "red" : "green"; });
|
||||
} else {
|
||||
let datapoint = svg.selectAll("rect")
|
||||
.data(this.chart.dataset[0].points)
|
||||
|
|
@ -116,14 +117,14 @@
|
|||
.attr("y", function(d) {return y(d.open);})
|
||||
.attr("height", function(d) { return 1;})
|
||||
.attr("width", function(d) { return 0.25 * mm / 2; })
|
||||
.attr("fill",function(d) { return d.open > d.close ? "red" : "green" ;});
|
||||
.attr("fill",function(d) { return d.open > d.close ? "red" : "green"; });
|
||||
|
||||
datapoint.append("svg:rect")
|
||||
.attr("x", function(d) { return x(d.x); })
|
||||
.attr("y", function(d) {return y(d.close);})
|
||||
.attr("height", function(d) { return 1;})
|
||||
.attr("width", function(d) { return 0.25 * mm / 2; })
|
||||
.attr("fill",function(d) { return d.open > d.close ? "red" : "green" ;});
|
||||
.attr("fill",function(d) { return d.open > d.close ? "red" : "green"; });
|
||||
}
|
||||
|
||||
svg.selectAll("line.stem")
|
||||
|
|
|
|||
|
|
@ -189,7 +189,7 @@
|
|||
{
|
||||
return x(d.x) + x.rangeBand() / self.chart.dataset.length * j;
|
||||
})
|
||||
.attr("width", x.rangeBand() /self.chart.dataset.length)
|
||||
.attr("width", x.rangeBand() / self.chart.dataset.length)
|
||||
.transition()
|
||||
.attr("y", function (d)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@
|
|||
- Math.max(this.chart.margin.right + this.chart.margin.left,
|
||||
this.chart.margin.top + this.chart.margin.bottom)
|
||||
),
|
||||
innerRadius = radius - radius*self.chart.dataSettings.style.strokewidth,
|
||||
innerRadius = radius - radius * self.chart.dataSettings.style.strokewidth,
|
||||
arc = d3.svg.arc()
|
||||
.outerRadius(function() { return radius; })
|
||||
.innerRadius(function() { return innerRadius; });
|
||||
|
|
|
|||
|
|
@ -53,6 +53,7 @@
|
|||
visible: true
|
||||
}
|
||||
};
|
||||
|
||||
this.chart.subtype = 'waterfall';
|
||||
};
|
||||
|
||||
|
|
@ -136,7 +137,7 @@
|
|||
.tickFormat("");
|
||||
|
||||
x.domain(this.chart.dataset[0].points.map(function(d) { return d.name; }));
|
||||
y.domain([0, d3.max(this.chart.dataset[0].points, function(d) { return d.y*1.05; })]);
|
||||
y.domain([0, d3.max(this.chart.dataset[0].points, function(d) { return d.y * 1.05; })]);
|
||||
|
||||
svg = this.chart.chartSelect.append("svg")
|
||||
.attr("width", this.chart.dimension.width)
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@
|
|||
visible: true
|
||||
}
|
||||
};
|
||||
|
||||
this.chart.subtype = 'scatterplot';
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ export class EventManager {
|
|||
{
|
||||
if (this.callbacks.hasOwnProperty(group)) {
|
||||
return this.triggerSingleEvent(group, id, data);
|
||||
}
|
||||
}p
|
||||
|
||||
const allGroups = Object.keys(this.callbacks),
|
||||
regex = new RegExp(group),
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@
|
|||
this.connection = null;
|
||||
this.messages = [];
|
||||
};
|
||||
|
||||
jsOMS.Client.prototype.setMessage = function(id, callback) {
|
||||
this.messages[id] = callback;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -38,8 +38,8 @@ export class Tab {
|
|||
this.bindElement(e);
|
||||
}
|
||||
} else {
|
||||
const tabs = document.getElementsByClassName('tabview'),
|
||||
length = !tabs ? 0 : tabs.length;
|
||||
const tabs = document.getElementsByClassName('tabview');
|
||||
const length = !tabs ? 0 : tabs.length;
|
||||
|
||||
for (let i = 0; i < length; ++i) {
|
||||
this.bindElement(tabs[i]);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user