Default multiTooltipTemplate now shows the dataset label + updated built files. Fixes #612

This commit is contained in:
Evert Timberg
2016-02-15 14:43:34 -05:00
parent 4f4f804a71
commit 4aa274d5b2
3 changed files with 6 additions and 6 deletions

8
Chart.js vendored
View File

@@ -168,7 +168,7 @@
tooltipTemplate: "<%if (label){%><%=label%>: <%}%><%= value %>",
// String - Template string for single tooltips
multiTooltipTemplate: "<%= value %>",
multiTooltipTemplate: "<%= datasetLabel %>: <%= value %>",
// String - Colour behind the legend colour block
multiTooltipKeyBackground: '#fff',
@@ -839,13 +839,13 @@
var container = domNode.parentNode,
padding = parseInt(getStyle(container, 'padding-left')) + parseInt(getStyle(container, 'padding-right'));
// TODO = check cross browser stuff with this.
return container.clientWidth - padding;
return container ? container.clientWidth - padding : 0;
},
getMaximumHeight = helpers.getMaximumHeight = function(domNode){
var container = domNode.parentNode,
padding = parseInt(getStyle(container, 'padding-bottom')) + parseInt(getStyle(container, 'padding-top'));
// TODO = check cross browser stuff with this.
return container.clientHeight - padding;
return container ? container.clientHeight - padding : 0;
},
getStyle = helpers.getStyle = function (el, property) {
return el.currentStyle ?
@@ -2233,7 +2233,7 @@
if (amd) {
define(function(){
define('Chart', [], function(){
return Chart;
});
} else if (typeof module === 'object' && module.exports) {

2
Chart.min.js vendored

File diff suppressed because one or more lines are too long

View File

@@ -168,7 +168,7 @@
tooltipTemplate: "<%if (label){%><%=label%>: <%}%><%= value %>",
// String - Template string for single tooltips
multiTooltipTemplate: "<%= value %>",
multiTooltipTemplate: "<%= datasetLabel %>: <%= value %>",
// String - Colour behind the legend colour block
multiTooltipKeyBackground: '#fff',