plotly.js 2.8.2 → 2.8.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * plotly.js v2.8.2
2
+ * plotly.js v2.8.3
3
3
  * Copyright 2012-2021, Plotly, Inc.
4
4
  * All rights reserved.
5
5
  * Licensed under the MIT license
@@ -176118,6 +176118,7 @@ function calcTexttemplate(fullLayout, cd, index, xa, ya) {
176118
176118
  var trace = cd[0].trace;
176119
176119
  var texttemplate = Lib.castOption(trace, index, 'texttemplate');
176120
176120
  if(!texttemplate) return '';
176121
+ var isHistogram = (trace.type === 'histogram');
176121
176122
  var isWaterfall = (trace.type === 'waterfall');
176122
176123
  var isFunnel = (trace.type === 'funnel');
176123
176124
  var isHorizontal = trace.orientation === 'h';
@@ -176159,10 +176160,10 @@ function calcTexttemplate(fullLayout, cd, index, xa, ya) {
176159
176160
  var pt = {};
176160
176161
  appendArrayPointValue(pt, trace, cdi.i);
176161
176162
 
176162
- if(pt.x === undefined) pt.x = isHorizontal ? obj.value : obj.label;
176163
- if(pt.y === undefined) pt.y = isHorizontal ? obj.label : obj.value;
176164
- if(pt.xLabel === undefined) pt.xLabel = isHorizontal ? obj.valueLabel : obj.labelLabel;
176165
- if(pt.yLabel === undefined) pt.yLabel = isHorizontal ? obj.labelLabel : obj.valueLabel;
176163
+ if(isHistogram || pt.x === undefined) pt.x = isHorizontal ? obj.value : obj.label;
176164
+ if(isHistogram || pt.y === undefined) pt.y = isHorizontal ? obj.label : obj.value;
176165
+ if(isHistogram || pt.xLabel === undefined) pt.xLabel = isHorizontal ? obj.valueLabel : obj.labelLabel;
176166
+ if(isHistogram || pt.yLabel === undefined) pt.yLabel = isHorizontal ? obj.labelLabel : obj.valueLabel;
176166
176167
 
176167
176168
  if(isWaterfall) {
176168
176169
  obj.delta = +cdi.rawS || cdi.s;
@@ -230519,7 +230520,7 @@ function getSortFunc(opts, d2c) {
230519
230520
  'use strict';
230520
230521
 
230521
230522
  // package version injected by `npm run preprocess`
230522
- exports.version = '2.8.2';
230523
+ exports.version = '2.8.3';
230523
230524
 
230524
230525
  },{}],1120:[function(_dereq_,module,exports){
230525
230526
  (function (global){(function (){
package/dist/plotly.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * plotly.js v2.8.2
2
+ * plotly.js v2.8.3
3
3
  * Copyright 2012-2021, Plotly, Inc.
4
4
  * All rights reserved.
5
5
  * Licensed under the MIT license
@@ -173021,6 +173021,7 @@ function calcTexttemplate(fullLayout, cd, index, xa, ya) {
173021
173021
  var trace = cd[0].trace;
173022
173022
  var texttemplate = Lib.castOption(trace, index, 'texttemplate');
173023
173023
  if(!texttemplate) return '';
173024
+ var isHistogram = (trace.type === 'histogram');
173024
173025
  var isWaterfall = (trace.type === 'waterfall');
173025
173026
  var isFunnel = (trace.type === 'funnel');
173026
173027
  var isHorizontal = trace.orientation === 'h';
@@ -173062,10 +173063,10 @@ function calcTexttemplate(fullLayout, cd, index, xa, ya) {
173062
173063
  var pt = {};
173063
173064
  appendArrayPointValue(pt, trace, cdi.i);
173064
173065
 
173065
- if(pt.x === undefined) pt.x = isHorizontal ? obj.value : obj.label;
173066
- if(pt.y === undefined) pt.y = isHorizontal ? obj.label : obj.value;
173067
- if(pt.xLabel === undefined) pt.xLabel = isHorizontal ? obj.valueLabel : obj.labelLabel;
173068
- if(pt.yLabel === undefined) pt.yLabel = isHorizontal ? obj.labelLabel : obj.valueLabel;
173066
+ if(isHistogram || pt.x === undefined) pt.x = isHorizontal ? obj.value : obj.label;
173067
+ if(isHistogram || pt.y === undefined) pt.y = isHorizontal ? obj.label : obj.value;
173068
+ if(isHistogram || pt.xLabel === undefined) pt.xLabel = isHorizontal ? obj.valueLabel : obj.labelLabel;
173069
+ if(isHistogram || pt.yLabel === undefined) pt.yLabel = isHorizontal ? obj.labelLabel : obj.valueLabel;
173069
173070
 
173070
173071
  if(isWaterfall) {
173071
173072
  obj.delta = +cdi.rawS || cdi.s;
@@ -224090,7 +224091,7 @@ function getSortFunc(opts, d2c) {
224090
224091
  'use strict';
224091
224092
 
224092
224093
  // package version injected by `npm run preprocess`
224093
- exports.version = '2.8.2';
224094
+ exports.version = '2.8.3';
224094
224095
 
224095
224096
  },{}],1120:[function(_dereq_,module,exports){
224096
224097
  (function (global){(function (){