Skip to content

Commit a646575

Browse files
committed
Merge branch 'master' into mapbox-v1
2 parents eb04b4c + b882de9 commit a646575

File tree

97 files changed

+8385
-819
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

97 files changed

+8385
-819
lines changed

lib/index-finance.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ Plotly.register([
1818
require('./ohlc'),
1919
require('./candlestick'),
2020
require('./funnel'),
21-
require('./waterfall')
21+
require('./waterfall'),
22+
require('./indicator')
2223
]);
2324

2425
module.exports = Plotly;

lib/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ Plotly.register([
5454
require('./densitymapbox'),
5555

5656
require('./sankey'),
57+
require('./indicator'),
5758

5859
require('./table'),
5960

lib/indicator.js

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/**
2+
* Copyright 2012-2019, Plotly, Inc.
3+
* All rights reserved.
4+
*
5+
* This source code is licensed under the MIT license found in the
6+
* LICENSE file in the root directory of this source tree.
7+
*/
8+
9+
'use strict';
10+
11+
module.exports = require('../src/traces/indicator');

package-lock.json

+119-63
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+6-6
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
"@turf/centroid": "^6.0.2",
6363
"alpha-shape": "^1.0.0",
6464
"canvas-fit": "^1.5.0",
65-
"color-normalize": "^1.3.0",
65+
"color-normalize": "^1.5.0",
6666
"convex-hull": "^1.0.3",
6767
"country-regex": "^1.1.0",
6868
"d3": "^3.5.12",
@@ -87,7 +87,7 @@
8787
"gl-spikes2d": "^1.0.2",
8888
"gl-streamtube3d": "^1.2.1",
8989
"gl-surface3d": "^1.4.6",
90-
"gl-text": "^1.1.6",
90+
"gl-text": "^1.1.8",
9191
"glslify": "^7.0.0",
9292
"has-hover": "^1.0.1",
9393
"has-passive-events": "^1.0.0",
@@ -102,10 +102,10 @@
102102
"point-cluster": "^3.1.4",
103103
"polybooljs": "^1.2.0",
104104
"regl": "^1.3.11",
105-
"regl-error2d": "^2.0.7",
106-
"regl-line2d": "3.0.13",
107-
"regl-scatter2d": "^3.1.4",
108-
"regl-splom": "^1.0.6",
105+
"regl-error2d": "^2.0.8",
106+
"regl-line2d": "^3.0.14",
107+
"regl-scatter2d": "^3.1.5",
108+
"regl-splom": "^1.0.7",
109109
"right-now": "^1.0.0",
110110
"robust-orientation": "^1.1.3",
111111
"sane-topojson": "^3.0.1",

src/components/modebar/manage.js

+11
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,9 @@ function getButtonGroups(gd, buttonsToRemove, buttonsToAdd, showSendToCloud) {
146146
if(hasCartesian) {
147147
hoverGroup = ['toggleSpikelines', 'hoverClosestCartesian', 'hoverCompareCartesian'];
148148
}
149+
if(hasNoHover(fullData)) {
150+
hoverGroup = [];
151+
}
149152

150153
if((hasCartesian || hasGL2D) && !allAxesFixed) {
151154
zoomGroup = ['zoomIn2d', 'zoomOut2d', 'autoScale2d'];
@@ -216,6 +219,14 @@ function isSelectable(fullData) {
216219
return selectable;
217220
}
218221

222+
// check whether all trace are 'noHover'
223+
function hasNoHover(fullData) {
224+
for(var i = 0; i < fullData.length; i++) {
225+
if(!Registry.traceIs(fullData[i], 'noHover')) return false;
226+
}
227+
return true;
228+
}
229+
219230
function appendButtonsToGroups(groups, buttons) {
220231
if(buttons.length) {
221232
if(Array.isArray(buttons[0])) {

0 commit comments

Comments
 (0)