Skip to content

Commit c27c986

Browse files
authored
Merge pull request #5639 from plotly/update-plotlyjs-3.7.0
chore: Update plotly.js to v3.7.0
2 parents 5cdb606 + 3d63d05 commit c27c986

16 files changed

Lines changed: 1782 additions & 1769 deletions

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,13 @@ This project adheres to [Semantic Versioning](http://semver.org/).
88
- Raise a clear `ValueError` when an unsupported marginal plot type is passed to Plotly Express, instead of failing later with a cryptic `'NoneType' object has no attribute 'constructor'` message [[#5625](https://github.com/plotly/plotly.py/pull/5625)], with thanks to @eugen-goebel for the contribution!
99

1010

11+
### Updated
12+
- Update plotly.js from version 3.6.0 to version 3.7.0. See the plotly.js [release notes](https://github.com/plotly/plotly.js/releases/tag/v3.7.0) for more information [[#5639](https://github.com/plotly/plotly.py/pull/5639)]. Notable changes include:
13+
- Rename `sendDataToCloud` modebar button to `sendChartToCloud`, and update to upload chart to Plotly Cloud [[#7802](https://github.com/plotly/plotly.js/pull/7802), [#7852](https://github.com/plotly/plotly.js/pull/7852), [#7854](https://github.com/plotly/plotly.js/pull/7854)]. NOTE: The Plotly Cloud endpoint for receiving charts is not yet functional, so this button won't complete the upload.
14+
- Fix stale `scattergl` error bars after toggling traces with mixed error bar visibility [[#7773](https://github.com/plotly/plotly.js/issues/7773)], with thanks to @JulienIcon for the contribution!
15+
- Fix geo `fitbounds` to choose a compact longitude range when point data straddles the antimeridian [[#7837](https://github.com/plotly/plotly.js/pull/7837)], with thanks to @SharadhNaidu for the contribution!
16+
17+
1118
## [6.8.0] - 2026-06-03
1219

1320
### Added

CONTRIBUTING.md

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -273,22 +273,30 @@ python commands.py updateplotlyjs
273273
```
274274

275275
This downloads new versions of `plot-schema.json` and `plotly.min.js` from the `plotly/plotly.js` GitHub repository
276-
and places them in `plotly/package_data`.
277-
It then regenerates all of the `graph_objs` classes based on the new schema,
278-
and finally runs `npm install` in `js/` to refresh `js/package-lock.json` against the new `plotly.js`.
279-
Commit the updated `js/package-lock.json` along with the regenerated files.
280-
281-
The JupyterLab extension and FigureWidget bundles in `plotly/labextension` and `plotly/package_data/widgetbundle.js`
282-
are rebuilt as part of the release flow (see [RELEASE.md](RELEASE.md)) rather than on every plotly.js bump.
283-
284-
If you need to skip the `npm install` step entirely (e.g. `npm` isn't available),
276+
and places them in `codegen/resources/` and `plotly/package_data/`, respectively.
277+
278+
It then does the following:
279+
- Regenerates all of the `graph_objs` classes based on the new schema
280+
- Runs `npm install` in `js/` to refresh `js/package-lock.json` against the new `plotly.js`
281+
- Runs `npm run build` to rebuild the JupyterLab extension and FigureWidget bundles in `plotly/labextension` and `plotly/package_data/widgetbundle.js`.
282+
283+
Commit the updated files under:
284+
- `codegen/resources/`
285+
- `js/`
286+
- `plotly/graph_objs/`
287+
- `plotly/labextension/`
288+
- `plotly/offline/`
289+
- `plotly/package_data/`
290+
291+
If you need to skip the `npm` steps entirely (e.g. `npm` isn't available),
285292
set the `SKIP_NPM=1` environment variable:
286293

287294
```bash
288295
SKIP_NPM=1 python commands.py updateplotlyjs
289296
```
290297

291-
If you do skip it, you'll need to run `npm install` in `js/` yourself before committing so the lockfile stays in sync.
298+
If you do skip it, you'll need to find a way to manually run `npm install && npm run build` in `js/` before committing,
299+
so that the lockfile and build artifacts stay in sync with `js/package.json`.
292300

293301
### Using a Development Branch of Plotly.js
294302

codegen/resources/plot-schema.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@
279279
"valType": "number"
280280
},
281281
"plotlyServerURL": {
282-
"description": "When set it determines base URL for the 'Edit in Chart Studio' `showEditInChartStudio`/`showSendToCloud` mode bar button and the showLink/sendData on-graph link. To enable sending your data to Chart Studio Cloud, you need to set both `plotlyServerURL` to 'https://chart-studio.plotly.com' and also set `showSendToCloud` to true.",
282+
"description": "Sets the URL for the `sendChartToCloud` modebar button. When clicked, the button will send the chart data to this URL.",
283283
"dflt": "",
284284
"valType": "string"
285285
},
@@ -331,7 +331,7 @@
331331
"valType": "boolean"
332332
},
333333
"showEditInChartStudio": {
334-
"description": "Same as `showSendToCloud`, but use a pencil icon instead of a floppy-disk. Note that if both `showSendToCloud` and `showEditInChartStudio` are turned, only `showEditInChartStudio` will be honored.",
334+
"description": "Deprecated. Use `showSendToCloud` instead.",
335335
"dflt": false,
336336
"valType": "boolean"
337337
},
@@ -341,7 +341,7 @@
341341
"valType": "boolean"
342342
},
343343
"showSendToCloud": {
344-
"description": "Should we include a ModeBar button, labeled \"Edit in Chart Studio\", that sends this chart to chart-studio.plotly.com (formerly plot.ly) or another plotly server as specified by `plotlyServerURL` for editing, export, etc? Prior to version 1.43.0 this button was included by default, now it is opt-in using this flag. Note that this button can (depending on `plotlyServerURL` being set) send your data to an external server. However that server does not persist your data until you arrive at the Chart Studio and explicitly click \"Save\".",
344+
"description": "Should we include a modebar button that sends this chart to a URL specified by `plotlyServerURL`, for sharing the chart with others? Note that this button will (after a confirmation step) send chart data to an external server.",
345345
"dflt": false,
346346
"valType": "boolean"
347347
},
@@ -4639,7 +4639,7 @@
46394639
},
46404640
"remove": {
46414641
"arrayOk": true,
4642-
"description": "Determines which predefined modebar buttons to remove. Similar to `config.modeBarButtonsToRemove` option. This may include *autoScale2d*, *autoscale*, *editInChartStudio*, *editinchartstudio*, *hoverCompareCartesian*, *hovercompare*, *lasso*, *lasso2d*, *orbitRotation*, *orbitrotation*, *pan*, *pan2d*, *pan3d*, *reset*, *resetCameraDefault3d*, *resetCameraLastSave3d*, *resetGeo*, *resetSankeyGroup*, *resetScale2d*, *resetViewMap*, *resetViewMapbox*, *resetViews*, *resetcameradefault*, *resetcameralastsave*, *resetsankeygroup*, *resetscale*, *resetview*, *resetviews*, *select*, *select2d*, *sendDataToCloud*, *senddatatocloud*, *tableRotation*, *tablerotation*, *toImage*, *toggleHover*, *toggleSpikelines*, *togglehover*, *togglespikelines*, *toimage*, *zoom*, *zoom2d*, *zoom3d*, *zoomIn2d*, *zoomInGeo*, *zoomInMap*, *zoomInMapbox*, *zoomOut2d*, *zoomOutGeo*, *zoomOutMap*, *zoomOutMapbox*, *zoomin*, *zoomout*.",
4642+
"description": "Determines which predefined modebar buttons to remove. Similar to `config.modeBarButtonsToRemove` option. This may include *autoScale2d*, *autoscale*, *hoverCompareCartesian*, *hovercompare*, *lasso*, *lasso2d*, *orbitRotation*, *orbitrotation*, *pan*, *pan2d*, *pan3d*, *reset*, *resetCameraDefault3d*, *resetCameraLastSave3d*, *resetGeo*, *resetSankeyGroup*, *resetScale2d*, *resetViewMap*, *resetViewMapbox*, *resetViews*, *resetcameradefault*, *resetcameralastsave*, *resetsankeygroup*, *resetscale*, *resetview*, *resetviews*, *select*, *select2d*, *sendChartToCloud*, *sendcharttocloud*, *tableRotation*, *tablerotation*, *toImage*, *toggleHover*, *toggleSpikelines*, *togglehover*, *togglespikelines*, *toimage*, *zoom*, *zoom2d*, *zoom3d*, *zoomIn2d*, *zoomInGeo*, *zoomInMap*, *zoomInMapbox*, *zoomOut2d*, *zoomOutGeo*, *zoomOutMap*, *zoomOutMapbox*, *zoomin*, *zoomout*.",
46434643
"dflt": "",
46444644
"editType": "modebar",
46454645
"valType": "string"

commands.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ def install_js_deps(local, build=True):
5050
When ``build`` is True (the default), also runs ``npm run build`` to
5151
rebuild the JupyterLab extension and FigureWidget bundles and verifies
5252
that the widget bundle exists. Pass ``build=False`` when you only need
53-
to refresh ``node_modules`` / ``package-lock.json`` (e.g. after a
54-
plotly.js version bump) and don't need the bundles rebuilt.
53+
to refresh ``node_modules`` / ``package-lock.json`` but don't
54+
need the bundles rebuilt.
5555
"""
5656

5757
npmName = "npm"
@@ -224,7 +224,7 @@ def update_plotlyjs(plotly_js_version, outdir):
224224
update_bundle(plotly_js_version)
225225
update_schema(plotly_js_version)
226226
perform_codegen(outdir)
227-
install_js_deps(local=None, build=False)
227+
install_js_deps(local=None, build=True)
228228

229229

230230
# FIXME: switch to argparse

js/lib/mimeExtension.js

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

js/package-lock.json

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

js/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
"dependencies": {
2121
"lodash-es": "^4.17.21",
22-
"plotly.js": "3.6.0",
22+
"plotly.js": "3.7.0",
2323
"@lumino/widgets": "~2.4.0"
2424
},
2525
"devDependencies": {

plotly/graph_objs/layout/_modebar.py

Lines changed: 16 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -155,20 +155,20 @@ def remove(self):
155155
"""
156156
Determines which predefined modebar buttons to remove. Similar
157157
to `config.modeBarButtonsToRemove` option. This may include
158-
"autoScale2d", "autoscale", "editInChartStudio",
159-
"editinchartstudio", "hoverCompareCartesian", "hovercompare",
160-
"lasso", "lasso2d", "orbitRotation", "orbitrotation", "pan",
161-
"pan2d", "pan3d", "reset", "resetCameraDefault3d",
162-
"resetCameraLastSave3d", "resetGeo", "resetSankeyGroup",
163-
"resetScale2d", "resetViewMap", "resetViewMapbox",
164-
"resetViews", "resetcameradefault", "resetcameralastsave",
165-
"resetsankeygroup", "resetscale", "resetview", "resetviews",
166-
"select", "select2d", "sendDataToCloud", "senddatatocloud",
167-
"tableRotation", "tablerotation", "toImage", "toggleHover",
168-
"toggleSpikelines", "togglehover", "togglespikelines",
169-
"toimage", "zoom", "zoom2d", "zoom3d", "zoomIn2d", "zoomInGeo",
170-
"zoomInMap", "zoomInMapbox", "zoomOut2d", "zoomOutGeo",
171-
"zoomOutMap", "zoomOutMapbox", "zoomin", "zoomout".
158+
"autoScale2d", "autoscale", "hoverCompareCartesian",
159+
"hovercompare", "lasso", "lasso2d", "orbitRotation",
160+
"orbitrotation", "pan", "pan2d", "pan3d", "reset",
161+
"resetCameraDefault3d", "resetCameraLastSave3d", "resetGeo",
162+
"resetSankeyGroup", "resetScale2d", "resetViewMap",
163+
"resetViewMapbox", "resetViews", "resetcameradefault",
164+
"resetcameralastsave", "resetsankeygroup", "resetscale",
165+
"resetview", "resetviews", "select", "select2d",
166+
"sendChartToCloud", "sendcharttocloud", "tableRotation",
167+
"tablerotation", "toImage", "toggleHover", "toggleSpikelines",
168+
"togglehover", "togglespikelines", "toimage", "zoom", "zoom2d",
169+
"zoom3d", "zoomIn2d", "zoomInGeo", "zoomInMap", "zoomInMapbox",
170+
"zoomOut2d", "zoomOutGeo", "zoomOutMap", "zoomOutMapbox",
171+
"zoomin", "zoomout".
172172
173173
The 'remove' property is a string and must be specified as:
174174
- A string
@@ -251,7 +251,6 @@ def _prop_descriptions(self):
251251
Determines which predefined modebar buttons to remove.
252252
Similar to `config.modeBarButtonsToRemove` option. This
253253
may include "autoScale2d", "autoscale",
254-
"editInChartStudio", "editinchartstudio",
255254
"hoverCompareCartesian", "hovercompare", "lasso",
256255
"lasso2d", "orbitRotation", "orbitrotation", "pan",
257256
"pan2d", "pan3d", "reset", "resetCameraDefault3d",
@@ -260,7 +259,7 @@ def _prop_descriptions(self):
260259
"resetViewMapbox", "resetViews", "resetcameradefault",
261260
"resetcameralastsave", "resetsankeygroup",
262261
"resetscale", "resetview", "resetviews", "select",
263-
"select2d", "sendDataToCloud", "senddatatocloud",
262+
"select2d", "sendChartToCloud", "sendcharttocloud",
264263
"tableRotation", "tablerotation", "toImage",
265264
"toggleHover", "toggleSpikelines", "togglehover",
266265
"togglespikelines", "toimage", "zoom", "zoom2d",
@@ -325,7 +324,6 @@ def __init__(
325324
Determines which predefined modebar buttons to remove.
326325
Similar to `config.modeBarButtonsToRemove` option. This
327326
may include "autoScale2d", "autoscale",
328-
"editInChartStudio", "editinchartstudio",
329327
"hoverCompareCartesian", "hovercompare", "lasso",
330328
"lasso2d", "orbitRotation", "orbitrotation", "pan",
331329
"pan2d", "pan3d", "reset", "resetCameraDefault3d",
@@ -334,7 +332,7 @@ def __init__(
334332
"resetViewMapbox", "resetViews", "resetcameradefault",
335333
"resetcameralastsave", "resetsankeygroup",
336334
"resetscale", "resetview", "resetviews", "select",
337-
"select2d", "sendDataToCloud", "senddatatocloud",
335+
"select2d", "sendChartToCloud", "sendcharttocloud",
338336
"tableRotation", "tablerotation", "toImage",
339337
"toggleHover", "toggleSpikelines", "togglehover",
340338
"togglespikelines", "toimage", "zoom", "zoom2d",

plotly/labextension/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
},
2020
"dependencies": {
2121
"lodash-es": "^4.17.21",
22-
"plotly.js": "3.6.0",
22+
"plotly.js": "3.7.0",
2323
"@lumino/widgets": "~2.4.0"
2424
},
2525
"devDependencies": {
@@ -33,7 +33,7 @@
3333
"outputDir": "../plotly/labextension",
3434
"webpackConfig": "./webpack.config.js",
3535
"_build": {
36-
"load": "static/remoteEntry.2a6392a40c19ad8383a0.js",
36+
"load": "static/remoteEntry.2c524f5a18b54c442f5d.js",
3737
"mimeExtension": "./mimeExtension"
3838
}
3939
}

plotly/labextension/static/1.3ad216e94ff8bdcd7b73.js

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

0 commit comments

Comments
 (0)