@@ -155,10 +155,12 @@ module.exports = function plot(gd, calcData) {
155155 var hoverCenterX = boundingBox . left + boundingBox . width / 2 ;
156156 var hoverCenterY = boundingBox . top + boundingBox . height / 2 ;
157157
158+ var hovertemplateLabels = { valueLabel : d3 . format ( d . valueFormat ) ( d . link . value ) + d . valueSuffix } ;
159+
158160 var tooltip = Fx . loneHover ( {
159161 x : hoverCenterX - rootBBox . left ,
160162 y : hoverCenterY - rootBBox . top ,
161- name : d3 . format ( d . valueFormat ) ( d . link . value ) + d . valueSuffix ,
163+ name : hovertemplateLabels . valueLabel ,
162164 text : [
163165 d . link . label || '' ,
164166 sourceLabel + d . link . source . label ,
@@ -169,7 +171,11 @@ module.exports = function plot(gd, calcData) {
169171 fontFamily : castHoverOption ( obj , 'font.family' ) ,
170172 fontSize : castHoverOption ( obj , 'font.size' ) ,
171173 fontColor : castHoverOption ( obj , 'font.color' ) ,
172- idealAlign : d3 . event . x < hoverCenterX ? 'right' : 'left'
174+ idealAlign : d3 . event . x < hoverCenterX ? 'right' : 'left' ,
175+
176+ hovertemplate : obj . hovertemplate ,
177+ hovertemplateLabels : hovertemplateLabels ,
178+ eventData : [ d . link ]
173179 } , {
174180 container : fullLayout . _hoverlayer . node ( ) ,
175181 outerContainer : fullLayout . _paper . node ( ) ,
@@ -224,6 +230,8 @@ module.exports = function plot(gd, calcData) {
224230 var hoverCenterX1 = boundingBox . right + 2 - rootBBox . left ;
225231 var hoverCenterY = boundingBox . top + boundingBox . height / 4 - rootBBox . top ;
226232
233+ var hovertemplateLabels = { valueLabel : d3 . format ( d . valueFormat ) ( d . node . value ) + d . valueSuffix } ;
234+
227235 var tooltip = Fx . loneHover ( {
228236 x0 : hoverCenterX0 ,
229237 x1 : hoverCenterX1 ,
@@ -239,7 +247,11 @@ module.exports = function plot(gd, calcData) {
239247 fontFamily : castHoverOption ( obj , 'font.family' ) ,
240248 fontSize : castHoverOption ( obj , 'font.size' ) ,
241249 fontColor : castHoverOption ( obj , 'font.color' ) ,
242- idealAlign : 'left'
250+ idealAlign : 'left' ,
251+
252+ hovertemplate : obj . hovertemplate ,
253+ hovertemplateLabels : hovertemplateLabels ,
254+ eventData : [ d . node ]
243255 } , {
244256 container : fullLayout . _hoverlayer . node ( ) ,
245257 outerContainer : fullLayout . _paper . node ( ) ,
0 commit comments