Skip to content

Commit 1e1458b

Browse files
authored
cast to numbers in scattermapbox angle arrays
1 parent f725425 commit 1e1458b

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/traces/scattermapbox/convert.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ function makeSymbolGeoJSON(calcTrace, gd) {
259259
blankFillFunc;
260260

261261
var fillAngle = (angle) ?
262-
getFillFunc(angle) :
262+
getFillFunc(angle, true) :
263263
blankFillFunc;
264264

265265
var fillText = subTypes.hasText(trace) ?
@@ -312,8 +312,11 @@ function makeSymbolGeoJSON(calcTrace, gd) {
312312
};
313313
}
314314

315-
function getFillFunc(attr) {
315+
function getFillFunc(attr, numeric) {
316316
if(Lib.isArrayOrTypedArray(attr)) {
317+
if(numeric) {
318+
return function(i) { return isNumeric(attr[i]) ? +attr[i] : 0; };
319+
}
317320
return function(i) { return attr[i]; };
318321
} else if(attr) {
319322
return function() { return attr; };

0 commit comments

Comments
 (0)