Skip to content

Commit 0bd1313

Browse files
committed
Merge branch 'master' into barmode_relative_offsetgroup
2 parents bc2ea29 + ef721c4 commit 0bd1313

File tree

254 files changed

+5449
-21854
lines changed

Some content is hidden

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

254 files changed

+5449
-21854
lines changed

.circleci/config.yml

+1-7
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ jobs:
7575
environment:
7676
# Alaska time (arbitrary timezone to test date logic)
7777
TZ: "America/Anchorage"
78-
parallelism: 12
78+
parallelism: 4
7979
working_directory: ~/plotly.js
8080
steps:
8181
- run: sudo apt-get update
@@ -464,12 +464,6 @@ jobs:
464464
- run:
465465
name: Test plot-schema.json diff - If failed, after (npm start) you could run (npm run schema && git add test/plot-schema.json && git commit -m "update plot-schema diff")
466466
command: diff --unified --color dist/plot-schema.json test/plot-schema.json
467-
- run:
468-
name: Test plotly.min.js import using amdefine
469-
command: npm run test-amdefine
470-
- run:
471-
name: Test plotly.min.js import using requirejs
472-
command: npm run test-requirejs
473467

474468
test-stackgl-bundle:
475469
docker:

CHANGELOG.md

+7
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,13 @@ 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.35.2] -- 2024-09-10
13+
14+
### Fixed
15+
- Fix require path to maplibre-gl.css (regression introduced in 2.35.1) [[#7146](https://github.com/plotly/plotly.js/pull/7146)],
16+
with thanks to @birkskyum for the contribution!
17+
18+
1219
## [2.35.1] -- 2024-09-09
1320

1421
### Fixed

LICENSE

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
The MIT License (MIT)
1+
MIT License
22

3-
Copyright (c) 2021 Plotly, Inc
3+
Copyright (c) 2016-2024 Plotly Technologies Inc.
44

55
Permission is hereby granted, free of charge, to any person obtaining a copy
66
of this software and associated documentation files (the "Software"), to deal

README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ You may also consider using [`plotly.js-dist`](https://www.npmjs.com/package/plo
6262
6363
```html
6464
<head>
65-
<script src="https://cdn.plot.ly/plotly-2.35.1.min.js" charset="utf-8"></script>
65+
<script src="https://cdn.plot.ly/plotly-2.35.2.min.js" charset="utf-8"></script>
6666
</head>
6767
<body>
6868
<div id="gd"></div>
@@ -79,7 +79,7 @@ You may also consider using [`plotly.js-dist`](https://www.npmjs.com/package/plo
7979
Alternatively you may consider using [native ES6 import](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules) in the script tag.
8080
```html
8181
<script type="module">
82-
import "https://cdn.plot.ly/plotly-2.35.1.min.js"
82+
import "https://cdn.plot.ly/plotly-2.35.2.min.js"
8383
Plotly.newPlot("gd", [{ y: [1, 2, 3] }])
8484
</script>
8585
```
@@ -89,7 +89,7 @@ Fastly supports Plotly.js with free CDN service. Read more at <https://www.fastl
8989
### Un-minified versions are also available on CDN
9090
While non-minified source files may contain characters outside UTF-8, it is recommended that you specify the `charset` when loading those bundles.
9191
```html
92-
<script src="https://cdn.plot.ly/plotly-2.35.1.js" charset="utf-8"></script>
92+
<script src="https://cdn.plot.ly/plotly-2.35.2.js" charset="utf-8"></script>
9393
```
9494

9595
> 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.

devtools/regl_codegen/server.js renamed to devtools/regl_codegen/server.mjs

+23-67
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
1-
var fs = require('fs');
2-
var path = require('path');
3-
var http = require('http');
4-
var ecstatic = require('ecstatic');
5-
var open = require('open');
6-
var webpack = require('webpack');
7-
var minimist = require('minimist');
8-
9-
var constants = require('../../tasks/util/constants');
10-
var config = require('../../webpack.config.js');
11-
config.optimization = { minimize: false };
1+
import fs from 'fs';
2+
import path from 'path';
3+
import http from 'http';
4+
import ecstatic from 'ecstatic';
5+
import open from 'open';
6+
import minimist from 'minimist';
7+
8+
import constants from '../../tasks/util/constants.js';
9+
import { build } from 'esbuild';
10+
import config from '../../esbuild-config.js';
1211

1312
var args = minimist(process.argv.slice(2), {});
1413
var PORT = args.port || 3000;
@@ -21,6 +20,8 @@ var reglTraceList = [
2120
'splom'
2221
];
2322

23+
24+
2425
// Create server
2526
var _static = ecstatic({
2627
root: constants.pathToRoot,
@@ -57,55 +58,25 @@ var server = http.createServer(function(req, res) {
5758
}
5859
});
5960

60-
61-
// Start the server up!
62-
server.listen(PORT);
63-
64-
// open up browser window
65-
open('http://localhost:' + PORT + '/devtools/regl_codegen/index' + (strict ? '-strict' : '') + '.html');
66-
6761
// Build and bundle all the things!
68-
getMockFiles()
62+
await getMockFiles()
6963
.then(readFiles)
7064
.then(createMocksList)
7165
.then(saveMockListToFile)
7266
.then(saveReglTracesToFile.bind(null, reglTraceList));
7367

74-
// Devtools config
75-
var devtoolsConfig = {};
76-
77-
var devtoolsPath = path.join(constants.pathToRoot, 'devtools/regl_codegen');
78-
devtoolsConfig.entry = path.join(devtoolsPath, 'devtools.js');
79-
80-
devtoolsConfig.output = {
81-
path: config.output.path,
82-
filename: 'regl_codegen-bundle.js',
83-
library: {
84-
name: 'Tabs',
85-
type: 'umd'
86-
}
87-
};
88-
89-
devtoolsConfig.target = config.target;
90-
devtoolsConfig.plugins = config.plugins;
91-
devtoolsConfig.optimization = config.optimization;
92-
devtoolsConfig.mode = 'production';
93-
94-
var compiler;
95-
96-
compiler = webpack(devtoolsConfig);
97-
compiler.run(function(devtoolsErr, devtoolsStats) {
98-
if(devtoolsErr) {
99-
console.log('err:', devtoolsErr);
100-
} else if(devtoolsStats.errors && devtoolsStats.errors.length) {
101-
console.log('stats.errors:', devtoolsStats.errors);
102-
} else {
103-
console.log('success:', devtoolsConfig.output.path + '/' + devtoolsConfig.output.filename);
68+
// Start the server up!
69+
server.listen(PORT);
10470

105-
purgeGeneratedCode(reglTraceList);
106-
}
107-
});
71+
// open up browser window
72+
open('http://localhost:' + PORT + '/devtools/regl_codegen/index' + (strict ? '-strict' : '') + '.html');
10873

74+
var devtoolsPath = path.join(constants.pathToRoot, 'devtools/regl_codegen');
75+
config.entryPoints = [path.join(devtoolsPath, 'devtools.js')];
76+
config.outfile = './build/regl_codegen-bundle.js';
77+
config.sourcemap = false;
78+
config.minify = false;
79+
await build(config);
10980

11081
function getMockFiles() {
11182
return new Promise(function(resolve, reject) {
@@ -240,18 +211,3 @@ function handleCodegen(data) {
240211
var precompiled = header + imports + exports;
241212
fs.writeFileSync(pathToReglPrecompiledSrc, precompiled);
242213
}
243-
244-
245-
function purgeGeneratedCode(traces) {
246-
var pathToReglCodegenSrc = constants.pathToReglCodegenSrc;
247-
248-
var files = fs.readdirSync(pathToReglCodegenSrc);
249-
files.forEach(function(file) {
250-
fs.unlinkSync(path.join(pathToReglCodegenSrc, file));
251-
});
252-
253-
traces.forEach(function(trace) {
254-
var pathToReglPrecompiledSrc = path.join(constants.pathToSrc, 'traces', trace, 'regl_precompiled.js');
255-
fs.writeFileSync(pathToReglPrecompiledSrc, 'module.exports = {};\n');
256-
});
257-
}

devtools/test_dashboard/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<div id="snapshot"></div>
2323

2424
<script src="../../node_modules/mathjax-v2/MathJax.js?config=TeX-AMS-MML_SVG"></script>
25-
<script charset="utf-8" id="source" src="../../build/plotly.js" type="module"></script>
25+
<script charset="utf-8" id="source" src="../../build/plotly.js"></script>
2626
<script charset="utf-8" src="../../build/test_dashboard-bundle.js"></script>
2727
</body>
2828
</html>

devtools/test_dashboard/server.js

-190
This file was deleted.

0 commit comments

Comments
 (0)