If you don't set width, bullet chart gets container's.. height is static but can be changed manually

master-patched
Bob Monteverde 12 years ago
parent c5dad2c36a
commit 94d44b7cec

@ -977,8 +977,8 @@ nv.models.bulletChart = function() {
ranges = function(d) { return d.ranges },
markers = function(d) { return d.markers },
measures = function(d) { return d.measures },
width = 380,
height = 55,
width = null,
height = 80,
tickFormat = null,
tooltips = true,
tooltip = function(key, x, y, e, graph) {
@ -1006,7 +1006,8 @@ nv.models.bulletChart = function() {
// For each small multiple…
function chart(g) {
g.each(function(d, i) {
var availableWidth = width - margin.left - margin.right,
var availableWidth = (width || parseInt(container.style('width')) || 960)
- margin.left - margin.right,
availableHeight = height - margin.top - margin.bottom,
that = this;

6
nv.d3.min.js vendored

File diff suppressed because one or more lines are too long

@ -9,8 +9,8 @@ nv.models.bulletChart = function() {
ranges = function(d) { return d.ranges },
markers = function(d) { return d.markers },
measures = function(d) { return d.measures },
width = 380,
height = 55,
width = null,
height = 80,
tickFormat = null,
tooltips = true,
tooltip = function(key, x, y, e, graph) {
@ -38,7 +38,8 @@ nv.models.bulletChart = function() {
// For each small multiple…
function chart(g) {
g.each(function(d, i) {
var availableWidth = width - margin.left - margin.right,
var availableWidth = (width || parseInt(container.style('width')) || 960)
- margin.left - margin.right,
availableHeight = height - margin.top - margin.bottom,
that = this;

Loading…
Cancel
Save