diff --git a/package-lock.json b/package-lock.json index 686bada9a20..a17da6327a5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5172,9 +5172,9 @@ } }, "glslify": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/glslify/-/glslify-6.3.0.tgz", - "integrity": "sha512-9VWypdkvL907Jn37QcCZXIHpLbmqs+fjnmjNszSFc+5ztmsGFzcknjCgeF887+xxfx32oGrgN7xfkSwa1D0khA==", + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/glslify/-/glslify-6.3.1.tgz", + "integrity": "sha512-3Hy85N8NmpDprwAxZaOC9k+DBXEwblVZ+yHIyt1QYg5dIrYaiGorz2WWBRxdUzapjDsxdhQ1ad9GSlIebxeBmA==", "requires": { "bl": "^1.0.0", "concat-stream": "^1.5.2", @@ -8861,9 +8861,9 @@ } }, "regl-line2d": { - "version": "3.0.9", - "resolved": "https://registry.npmjs.org/regl-line2d/-/regl-line2d-3.0.9.tgz", - "integrity": "sha512-D3ASXgofHVcdxi6qfQRJ7YsAVHkK0i7rkKx9qwDLYoZ96eRyyFMDb1zA3ulrmarPnb/U2G7EfsYQDU3V96EP4Q==", + "version": "3.0.11", + "resolved": "https://registry.npmjs.org/regl-line2d/-/regl-line2d-3.0.11.tgz", + "integrity": "sha512-nf0Ftpf6boR0oJ24Gs77J8pQE0wet59T1TkrK1f0TWKJgWgRXByxRHDD92m/KZ2dpl+XTvCORk2NRqitSJGwWw==", "requires": { "array-bounds": "^1.0.0", "array-normalize": "^1.1.3", @@ -8872,7 +8872,7 @@ "earcut": "^2.1.1", "es6-weak-map": "^2.0.2", "flatten-vertex-data": "^1.0.0", - "glslify": "^6.1.0", + "glslify": "^6.3.1", "object-assign": "^4.1.1", "parse-rect": "^1.2.0", "pick-by-alias": "^1.1.0", diff --git a/package.json b/package.json index 7b1a6d52425..2a6a8902994 100644 --- a/package.json +++ b/package.json @@ -85,7 +85,7 @@ "gl-streamtube3d": "^1.0.0", "gl-surface3d": "^1.3.5", "gl-text": "^1.1.6", - "glslify": "^6.2.1", + "glslify": "^6.3.1", "has-hover": "^1.0.1", "has-passive-events": "^1.0.0", "mapbox-gl": "0.45.0", @@ -101,7 +101,7 @@ "polybooljs": "^1.2.0", "regl": "^1.3.7", "regl-error2d": "^2.0.5", - "regl-line2d": "^3.0.9", + "regl-line2d": "^3.0.11", "regl-scatter2d": "^3.0.6", "regl-splom": "^1.0.4", "right-now": "^1.0.0", diff --git a/src/traces/scattergl/index.js b/src/traces/scattergl/index.js index 8b2b8b047dd..b7431d48648 100644 --- a/src/traces/scattergl/index.js +++ b/src/traces/scattergl/index.js @@ -431,7 +431,7 @@ function plot(gd, subplot, cdata) { if(scene.fill2d) { scene.fillOptions = scene.fillOptions.map(function(fillOptions, i) { var cdscatter = cdata[i]; - if(!fillOptions || !cdscatter || !cdscatter[0] || !cdscatter[0].trace) return null; + if(!fillOptions || !cdscatter || !cdscatter[0] || !cdscatter[0].trace) return; var cd = cdscatter[0]; var trace = cd.trace; var stash = cd.t; diff --git a/test/image/baselines/gl2d_fill-ordering.png b/test/image/baselines/gl2d_fill-ordering.png new file mode 100644 index 00000000000..7b71d7d2dcb Binary files /dev/null and b/test/image/baselines/gl2d_fill-ordering.png differ diff --git a/test/image/baselines/gl2d_text_chart_basic.png b/test/image/baselines/gl2d_text_chart_basic.png index 93488811117..afece63c14c 100644 Binary files a/test/image/baselines/gl2d_text_chart_basic.png and b/test/image/baselines/gl2d_text_chart_basic.png differ diff --git a/test/image/baselines/gl2d_text_chart_single-string.png b/test/image/baselines/gl2d_text_chart_single-string.png index 733e3584811..bebed9f57f3 100644 Binary files a/test/image/baselines/gl2d_text_chart_single-string.png and b/test/image/baselines/gl2d_text_chart_single-string.png differ diff --git a/test/image/mocks/gl2d_fill-ordering.json b/test/image/mocks/gl2d_fill-ordering.json new file mode 100644 index 00000000000..49d491f95f8 --- /dev/null +++ b/test/image/mocks/gl2d_fill-ordering.json @@ -0,0 +1,40 @@ +{ + "data": [ + { + "x": [1, 2, 3, 4, 5, 6], + "y": [100, 100, 0, 0, 0, 0], + "fill": "tozeroy", + "type": "scattergl" + }, + { + "x": [1, 2, 3, 4, 5, 6], + "y": [0, 0, 0, 100, 100, 0], + "fill": "tozeroy", + "type": "scattergl", + "mode": "none" + }, + { + "x": [1, 2, 3, 4, 5, 6], + "y": [99, 99, 99, 100, 100, 100], + "type": "scattergl", + "mode": "lines+markers" + }, + { + "x": [1, 2, 3, 4, 5, 6], + "y": [0, 0, 0, null, 50, 50], + "fill": "tozeroy", + "type": "scattergl", + "mode": "none" + }, + { + "x": [1, 2, 3, 4, 5, 6], + "y": [100, 0, 0, 0, 0, 100], + "type": "scattergl", + "mode": "lines+markers" + } + ], + "layout": { + "margin": {"l": 40, "r": 50, "b": 80, "t": 40}, + "legend": {"orientation": "h", "x": "0.5", "xanchor": "center"} + } +}