Skip to content

Commit e4909bf

Browse files
Merge remote-tracking branch 'origin/master' into first_poc_tickmode_sync
2 parents 3fb6996 + 3516391 commit e4909bf

33 files changed

+1174
-102
lines changed

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,19 @@ To see all merged commits on the master branch that will be part of the next plo
99

1010
where X.Y.Z is the semver of most recent plotly.js release.
1111

12+
## [2.16.3] -- 2022-11-16
13+
14+
### Fixed
15+
- Fixed hover on multicategory axes [[#6360](https://github.com/plotly/plotly.js/pull/6360)],
16+
with thanks to @filipesantiagoAM for the contribution!
17+
18+
19+
## [2.16.2] -- 2022-11-11
20+
21+
### Fixed
22+
- Fix mapbox clearOutline calls (regression introduced in 2.13.0) [[#6367](https://github.com/plotly/plotly.js/pull/6367)]
23+
24+
1225
## [2.16.1] -- 2022-10-21
1326

1427
### Fixed

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ You may also consider using [`plotly.js-dist`](https://www.npmjs.com/package/plo
5555
5656
```html
5757
<head>
58-
<script src="https://cdn.plot.ly/plotly-2.16.1.min.js"></script>
58+
<script src="https://cdn.plot.ly/plotly-2.16.3.min.js"></script>
5959
</head>
6060
<body>
6161
<div id="gd"></div>
@@ -72,7 +72,7 @@ You may also consider using [`plotly.js-dist`](https://www.npmjs.com/package/plo
7272
Alternatively you may consider using [native ES6 import](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules) in the script tag.
7373
```html
7474
<script type="module">
75-
import "https://cdn.plot.ly/plotly-2.16.1.min.js"
75+
import "https://cdn.plot.ly/plotly-2.16.3.min.js"
7676
Plotly.newPlot("gd", [{ y: [1, 2, 3] }])
7777
</script>
7878
```
@@ -82,7 +82,7 @@ Fastly supports Plotly.js with free CDN service. Read more at <https://www.fastl
8282
### Un-minified versions are also available on CDN
8383
While non-minified source files may contain characters outside UTF-8, it is recommended that you specify the `charset` when loading those bundles.
8484
```html
85-
<script src="https://cdn.plot.ly/plotly-2.16.1.js" charset="utf-8"></script>
85+
<script src="https://cdn.plot.ly/plotly-2.16.3.js" charset="utf-8"></script>
8686
```
8787

8888
> Please note that as of v2 the "plotly-latest" outputs (e.g. https://cdn.plot.ly/plotly-latest.min.js) will no longer be updated on the CDN, and will stay at the last v1 patch v1.58.5. Therefore, to use the CDN with plotly.js v2 and higher, you must specify an exact plotly.js version.

dist/README.md

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ The main plotly.js bundles weight in at:
4646
| 8.4 MB | 3.5 MB | 1 MB | 8.7 MB |
4747

4848
#### CDN links
49-
> https://cdn.plot.ly/plotly-2.16.1.js
49+
> https://cdn.plot.ly/plotly-2.16.3.js
5050
51-
> https://cdn.plot.ly/plotly-2.16.1.min.js
51+
> https://cdn.plot.ly/plotly-2.16.3.min.js
5252
5353

5454
#### npm packages
@@ -91,12 +91,12 @@ The `basic` partial bundle contains trace modules `bar`, `pie` and `scatter`.
9191

9292
| Raw size | Minified size | Minified + gzip size |
9393
|------|-----------------|------------------------|
94-
| 2.8 MB | 1004.5 kB | 326.8 kB |
94+
| 2.8 MB | 1004.6 kB | 326.8 kB |
9595

9696
#### CDN links
97-
> https://cdn.plot.ly/plotly-basic-2.16.1.js
97+
> https://cdn.plot.ly/plotly-basic-2.16.3.js
9898
99-
> https://cdn.plot.ly/plotly-basic-2.16.1.min.js
99+
> https://cdn.plot.ly/plotly-basic-2.16.3.min.js
100100
101101

102102
#### npm packages
@@ -117,9 +117,9 @@ The `cartesian` partial bundle contains trace modules `bar`, `box`, `contour`, `
117117
| 3.4 MB | 1.2 MB | 400.1 kB |
118118

119119
#### CDN links
120-
> https://cdn.plot.ly/plotly-cartesian-2.16.1.js
120+
> https://cdn.plot.ly/plotly-cartesian-2.16.3.js
121121
122-
> https://cdn.plot.ly/plotly-cartesian-2.16.1.min.js
122+
> https://cdn.plot.ly/plotly-cartesian-2.16.3.min.js
123123
124124

125125
#### npm packages
@@ -137,12 +137,12 @@ The `geo` partial bundle contains trace modules `choropleth`, `scatter` and `sca
137137

138138
| Raw size | Minified size | Minified + gzip size |
139139
|------|-----------------|------------------------|
140-
| 3.1 MB | 1.1 MB | 369.6 kB |
140+
| 3.1 MB | 1.1 MB | 369.7 kB |
141141

142142
#### CDN links
143-
> https://cdn.plot.ly/plotly-geo-2.16.1.js
143+
> https://cdn.plot.ly/plotly-geo-2.16.3.js
144144
145-
> https://cdn.plot.ly/plotly-geo-2.16.1.min.js
145+
> https://cdn.plot.ly/plotly-geo-2.16.3.min.js
146146
147147

148148
#### npm packages
@@ -160,12 +160,12 @@ The `gl3d` partial bundle contains trace modules `cone`, `isosurface`, `mesh3d`,
160160

161161
| Raw size | Minified size | Minified + gzip size |
162162
|------|-----------------|------------------------|
163-
| 3.9 MB | 1.6 MB | 490.5 kB |
163+
| 3.9 MB | 1.6 MB | 490.6 kB |
164164

165165
#### CDN links
166-
> https://cdn.plot.ly/plotly-gl3d-2.16.1.js
166+
> https://cdn.plot.ly/plotly-gl3d-2.16.3.js
167167
168-
> https://cdn.plot.ly/plotly-gl3d-2.16.1.min.js
168+
> https://cdn.plot.ly/plotly-gl3d-2.16.3.min.js
169169
170170

171171
#### npm packages
@@ -186,9 +186,9 @@ The `gl2d` partial bundle contains trace modules `heatmapgl`, `parcoords`, `poin
186186
| 4.5 MB | 1.8 MB | 583 kB |
187187

188188
#### CDN links
189-
> https://cdn.plot.ly/plotly-gl2d-2.16.1.js
189+
> https://cdn.plot.ly/plotly-gl2d-2.16.3.js
190190
191-
> https://cdn.plot.ly/plotly-gl2d-2.16.1.min.js
191+
> https://cdn.plot.ly/plotly-gl2d-2.16.3.min.js
192192
193193

194194
#### npm packages
@@ -209,9 +209,9 @@ The `mapbox` partial bundle contains trace modules `choroplethmapbox`, `densitym
209209
| 4.4 MB | 1.8 MB | 524.7 kB |
210210

211211
#### CDN links
212-
> https://cdn.plot.ly/plotly-mapbox-2.16.1.js
212+
> https://cdn.plot.ly/plotly-mapbox-2.16.3.js
213213
214-
> https://cdn.plot.ly/plotly-mapbox-2.16.1.min.js
214+
> https://cdn.plot.ly/plotly-mapbox-2.16.3.min.js
215215
216216

217217
#### npm packages
@@ -229,12 +229,12 @@ The `finance` partial bundle contains trace modules `bar`, `candlestick`, `funne
229229

230230
| Raw size | Minified size | Minified + gzip size |
231231
|------|-----------------|------------------------|
232-
| 3 MB | 1.1 MB | 359.5 kB |
232+
| 3 MB | 1.1 MB | 359.6 kB |
233233

234234
#### CDN links
235-
> https://cdn.plot.ly/plotly-finance-2.16.1.js
235+
> https://cdn.plot.ly/plotly-finance-2.16.3.js
236236
237-
> https://cdn.plot.ly/plotly-finance-2.16.1.min.js
237+
> https://cdn.plot.ly/plotly-finance-2.16.3.min.js
238238
239239

240240
#### npm packages
@@ -255,9 +255,9 @@ The `strict` partial bundle contains trace modules `bar`, `barpolar`, `box`, `ca
255255
| 8.8 MB | 3.9 MB | 1.1 MB |
256256

257257
#### CDN links
258-
> https://cdn.plot.ly/plotly-strict-2.16.1.js
258+
> https://cdn.plot.ly/plotly-strict-2.16.3.js
259259
260-
> https://cdn.plot.ly/plotly-strict-2.16.1.min.js
260+
> https://cdn.plot.ly/plotly-strict-2.16.3.min.js
261261
262262

263263
#### npm packages

dist/plotly-basic.js

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* plotly.js (basic) v2.16.1
2+
* plotly.js (basic) v2.16.3
33
* Copyright 2012-2022, Plotly, Inc.
44
* All rights reserved.
55
* Licensed under the MIT license
@@ -28719,7 +28719,17 @@ function createHoverText(hoverData, opts) {
2871928719
var xa = c0.xa;
2872028720
var ya = c0.ya;
2872128721
var axLetter = hovermode.charAt(0);
28722-
var t0 = c0[axLetter + 'Label'];
28722+
var axLabel = axLetter + 'Label';
28723+
var t0 = c0[axLabel];
28724+
28725+
// search in array for the label
28726+
if(t0 === undefined && xa.type === 'multicategory') {
28727+
for(var q = 0; q < hoverData.length; q++) {
28728+
t0 = hoverData[q][axLabel];
28729+
if(t0 !== undefined) break;
28730+
}
28731+
}
28732+
2872328733
var outerContainerBB = getBoundingClientRect(gd, outerContainer);
2872428734
var outerTop = outerContainerBB.top;
2872528735
var outerWidth = outerContainerBB.width;
@@ -29898,7 +29908,7 @@ function getCoord(axLetter, winningPoint, fullLayout) {
2989829908

2989929909
var cd0 = winningPoint.cd[0];
2990029910

29901-
if(ax.type === 'category') val = ax._categoriesMap[val];
29911+
if(ax.type === 'category' || ax.type === 'multicategory') val = ax._categoriesMap[val];
2990229912
else if(ax.type === 'date') {
2990329913
var periodalignment = winningPoint.trace[axLetter + 'periodalignment'];
2990429914
if(periodalignment) {
@@ -85405,7 +85415,7 @@ function getSortFunc(opts, d2c) {
8540585415
'use strict';
8540685416

8540785417
// package version injected by `npm run preprocess`
85408-
exports.version = '2.16.1';
85418+
exports.version = '2.16.3';
8540985419

8541085420
},{}]},{},[8])(8)
8541185421
});

dist/plotly-basic.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plotly-cartesian.js

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* plotly.js (cartesian) v2.16.1
2+
* plotly.js (cartesian) v2.16.3
33
* Copyright 2012-2022, Plotly, Inc.
44
* All rights reserved.
55
* Licensed under the MIT license
@@ -37889,7 +37889,17 @@ function createHoverText(hoverData, opts) {
3788937889
var xa = c0.xa;
3789037890
var ya = c0.ya;
3789137891
var axLetter = hovermode.charAt(0);
37892-
var t0 = c0[axLetter + 'Label'];
37892+
var axLabel = axLetter + 'Label';
37893+
var t0 = c0[axLabel];
37894+
37895+
// search in array for the label
37896+
if(t0 === undefined && xa.type === 'multicategory') {
37897+
for(var q = 0; q < hoverData.length; q++) {
37898+
t0 = hoverData[q][axLabel];
37899+
if(t0 !== undefined) break;
37900+
}
37901+
}
37902+
3789337903
var outerContainerBB = getBoundingClientRect(gd, outerContainer);
3789437904
var outerTop = outerContainerBB.top;
3789537905
var outerWidth = outerContainerBB.width;
@@ -39068,7 +39078,7 @@ function getCoord(axLetter, winningPoint, fullLayout) {
3906839078

3906939079
var cd0 = winningPoint.cd[0];
3907039080

39071-
if(ax.type === 'category') val = ax._categoriesMap[val];
39081+
if(ax.type === 'category' || ax.type === 'multicategory') val = ax._categoriesMap[val];
3907239082
else if(ax.type === 'date') {
3907339083
var periodalignment = winningPoint.trace[axLetter + 'periodalignment'];
3907439084
if(periodalignment) {
@@ -105651,7 +105661,7 @@ function getSortFunc(opts, d2c) {
105651105661
'use strict';
105652105662

105653105663
// package version injected by `npm run preprocess`
105654-
exports.version = '2.16.1';
105664+
exports.version = '2.16.3';
105655105665

105656105666
},{}]},{},[15])(15)
105657105667
});

dist/plotly-cartesian.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plotly-finance.js

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* plotly.js (finance) v2.16.1
2+
* plotly.js (finance) v2.16.3
33
* Copyright 2012-2022, Plotly, Inc.
44
* All rights reserved.
55
* Licensed under the MIT license
@@ -29939,7 +29939,17 @@ function createHoverText(hoverData, opts) {
2993929939
var xa = c0.xa;
2994029940
var ya = c0.ya;
2994129941
var axLetter = hovermode.charAt(0);
29942-
var t0 = c0[axLetter + 'Label'];
29942+
var axLabel = axLetter + 'Label';
29943+
var t0 = c0[axLabel];
29944+
29945+
// search in array for the label
29946+
if(t0 === undefined && xa.type === 'multicategory') {
29947+
for(var q = 0; q < hoverData.length; q++) {
29948+
t0 = hoverData[q][axLabel];
29949+
if(t0 !== undefined) break;
29950+
}
29951+
}
29952+
2994329953
var outerContainerBB = getBoundingClientRect(gd, outerContainer);
2994429954
var outerTop = outerContainerBB.top;
2994529955
var outerWidth = outerContainerBB.width;
@@ -31118,7 +31128,7 @@ function getCoord(axLetter, winningPoint, fullLayout) {
3111831128

3111931129
var cd0 = winningPoint.cd[0];
3112031130

31121-
if(ax.type === 'category') val = ax._categoriesMap[val];
31131+
if(ax.type === 'category' || ax.type === 'multicategory') val = ax._categoriesMap[val];
3112231132
else if(ax.type === 'date') {
3112331133
var periodalignment = winningPoint.trace[axLetter + 'periodalignment'];
3112431134
if(periodalignment) {
@@ -93412,7 +93422,7 @@ function getSortFunc(opts, d2c) {
9341293422
'use strict';
9341393423

9341493424
// package version injected by `npm run preprocess`
93415-
exports.version = '2.16.1';
93425+
exports.version = '2.16.3';
9341693426

9341793427
},{}]},{},[12])(12)
9341893428
});

dist/plotly-finance.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/plotly-geo-assets.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)