Showing 149 of 317 total issues
Function d3_rgb_parse
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function d3_rgb_parse(format, rgb, hsl) {
var r = 0, g = 0, b = 0, m1, m2, name;
m1 = /([a-z]+)\((.*)\)/i.exec(format);
if (m1) {
m2 = m1[2].split(",");
Function d3_geom_voronoiRemoveBeach
has 34 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function d3_geom_voronoiRemoveBeach(beach) {
var circle = beach.circle, x = circle.x, y = circle.cy, vertex = {
x: x,
y: y
}, previous = beach.P, next = beach.N, disappearing = [ beach ];
Function init
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
init = function() {
$(".close-bar").click(function() {
$($(this).attr('data-target')).hide();
});
Function setupSprintPlanning
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function setupSprintPlanning(project_id, sprint_id) {
$('#estimated').sortable({
items: 'div.backlog-item',
connectWith: '#committed',
receive: function(event, ui) {
Function d3_scale_quantile
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function d3_scale_quantile(domain, range) {
var thresholds;
function rescale() {
var k = 0, q = range.length;
thresholds = [];
Function stream
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
albersUsa.stream = function(stream) {
var lower48Stream = lower48.stream(stream), alaskaStream = alaska.stream(stream), hawaiiStream = hawaii.stream(stream);
return {
point: function(x, y) {
lower48Stream.point(x, y);
Function init
has 33 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
init = function() {
$(".close-bar").click(function() {
$($(this).attr('data-target')).hide();
});
Function adjust
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function adjust() {
var height, original;
if (mirrored !== ta) {
initMirror();
Function d3_scale_pow
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function d3_scale_pow(linear, exponent, domain) {
var powp = d3_scale_powPow(exponent), powb = d3_scale_powPow(1 / exponent);
function scale(x) {
return linear(powp(x));
}
Function arc
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
d3.svg.arc = function() {
var innerRadius = d3_svg_arcInnerRadius, outerRadius = d3_svg_arcOuterRadius, startAngle = d3_svg_arcStartAngle, endAngle = d3_svg_arcEndAngle;
function arc() {
var r0 = innerRadius.apply(this, arguments), r1 = outerRadius.apply(this, arguments), a0 = startAngle.apply(this, arguments) + d3_svg_arcOffset, a1 = endAngle.apply(this, arguments) + d3_svg_arcOffset, da = (a1 < a0 && (da = a0,
a0 = a1, a1 = da), a1 - a0), df = da < π ? "0" : "1", c0 = Math.cos(a0), s0 = Math.sin(a0), c1 = Math.cos(a1), s1 = Math.sin(a1);
Function dragstart
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function dragstart(id, position, move, end) {
return function() {
var target = this, parent = target.parentNode, event_ = event.of(target, arguments), eventTarget = d3.event.target, eventId = id(), drag = eventId == null ? "drag" : "drag-" + eventId, origin_ = position(parent, eventId), dragged = 0, offset, w = d3.select(d3_window).on(move + "." + drag, moved).on(end + "." + drag, ended), dragRestore = d3_event_dragSuppress();
if (origin) {
offset = origin.apply(target, arguments);
Function event
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
zoom.event = function(g) {
g.each(function() {
var event_ = event.of(this, arguments), view1 = view;
if (d3_transitionInheritId) {
d3.select(this).transition().each("start.zoom", function() {
Function d3_geom_voronoiAttachCircle
has 31 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function d3_geom_voronoiAttachCircle(arc) {
var lArc = arc.P, rArc = arc.N;
if (!lArc || !rArc) return;
var lSite = lArc.site, cSite = arc.site, rSite = rArc.site;
if (lSite === rSite) return;
Function circle
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
d3.geo.circle = function() {
var origin = [ 0, 0 ], angle, precision = 6, interpolate;
function circle() {
var center = typeof origin === "function" ? origin.apply(this, arguments) : origin, rotate = d3_geo_rotation(-center[0] * d3_radians, -center[1] * d3_radians, 0).invert, ring = [];
interpolate(null, null, 1, {
Function brush
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function brush(g) {
g.each(function() {
var g = d3.select(this).style("pointer-events", "all").style("-webkit-tap-highlight-color", "rgba(0,0,0,0)").on("mousedown.brush", brushstart).on("touchstart.brush", brushstart);
var background = g.selectAll(".background").data([ 0 ]);
background.enter().append("rect").attr("class", "background").style("visibility", "hidden").style("cursor", "crosshair");
Function token
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function token() {
if (I >= N) return EOF;
if (eol) return eol = false, EOL;
var j = I;
if (text.charCodeAt(j) === 34) {
Function d3_scale_quantize
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function d3_scale_quantize(x0, x1, range) {
var kx, i;
function scale(x) {
return range[Math.max(0, Math.min(i, Math.floor(kx * (x - x0))))];
}
Function apportion
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function apportion(node, previousSibling, ancestor) {
if (previousSibling) {
var vip = node, vop = node, vim = previousSibling, vom = node.parent.children[0], sip = vip._tree.mod, sop = vop._tree.mod, sim = vim._tree.mod, som = vom._tree.mod, shift;
while (vim = d3_layout_treeRight(vim), vip = d3_layout_treeLeft(vip), vim && vip) {
vom = d3_layout_treeLeft(vom);
Function position
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function position(row, u, rect, flush) {
var i = -1, n = row.length, x = rect.x, y = rect.y, v = u ? round(row.area / u) : 0, o;
if (u == rect.dx) {
if (flush || v > rect.dy) v = rect.dy;
while (++i < n) {
Function attr
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
d3_transitionPrototype.attr = function(nameNS, value) {
if (arguments.length < 2) {
for (value in nameNS) this.attr(value, nameNS[value]);
return this;
}