Skip to content

Commit fa66d7e

Browse files
committed
src/plots/plots.js 2
1 parent 02a0322 commit fa66d7e

File tree

1 file changed

+11
-19
lines changed

1 file changed

+11
-19
lines changed

src/plots/plots.js

Lines changed: 11 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1281,28 +1281,20 @@ plots.supplyTraceDefaults = function(traceIn, traceOut, colorIndex, layout, trac
12811281
var subplots = layout._subplots;
12821282
var subplotId = '';
12831283

1284-
if(
1285-
visible ||
1286-
basePlotModule.name !== 'gl2d' // for now just drop empty gl2d subplots
1287-
// TODO - currently if we draw an empty gl2d subplot, it draws
1288-
// nothing then gets stuck and you can't get it back without newPlot
1289-
// sort this out in the regl refactor?
1290-
) {
1291-
if(Array.isArray(subplotAttr)) {
1292-
for(i = 0; i < subplotAttr.length; i++) {
1293-
var attri = subplotAttr[i];
1294-
var vali = Lib.coerce(traceIn, traceOut, subplotAttrs, attri);
1284+
if(Array.isArray(subplotAttr)) {
1285+
for(i = 0; i < subplotAttr.length; i++) {
1286+
var attri = subplotAttr[i];
1287+
var vali = Lib.coerce(traceIn, traceOut, subplotAttrs, attri);
12951288

1296-
if(subplots[attri]) Lib.pushUnique(subplots[attri], vali);
1297-
subplotId += vali;
1298-
}
1299-
} else {
1300-
subplotId = Lib.coerce(traceIn, traceOut, subplotAttrs, subplotAttr);
1289+
if(subplots[attri]) Lib.pushUnique(subplots[attri], vali);
1290+
subplotId += vali;
13011291
}
1292+
} else {
1293+
subplotId = Lib.coerce(traceIn, traceOut, subplotAttrs, subplotAttr);
1294+
}
13021295

1303-
if(subplots[basePlotModule.name]) {
1304-
Lib.pushUnique(subplots[basePlotModule.name], subplotId);
1305-
}
1296+
if(subplots[basePlotModule.name]) {
1297+
Lib.pushUnique(subplots[basePlotModule.name], subplotId);
13061298
}
13071299
}
13081300
}

0 commit comments

Comments
 (0)