Skip to content

Incorrect graph with all zero values #13

@juhamust

Description

@juhamust

The graph is shown incorrectly when all the values are zero:

  • Line graph: straight line above the graph, no labels
  • Bar graph: all full bars
  • Etc.

Expected outcome is have flat line/bars at level 0.

var placeholder = document.getElementById('graph');

// var values = [0, 1, 4, 3];  // <-- OK
var values = [0, 0, 0, 0];  // <-- NOK
new Ico.LineGraph(placeholder, values, 
{colour:'#ff0000', labels:['one', 'two', 'three', 'four'], height:300, width: 300}
);

Used versions:

  • Ico (latest from master): 15e69ac
  • Raphael.js: 2.0.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions