Skip to content

Commit b62be42

Browse files
committed
Merge remote-tracking branch 'origin/master' into how-to-clone-your-fork
2 parents 113c996 + bb42376 commit b62be42

File tree

153 files changed

+17214
-585
lines changed

Some content is hidden

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

153 files changed

+17214
-585
lines changed

.circleci/config.yml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,18 +185,34 @@ jobs:
185185
command: .circleci/env_build.sh
186186
- run:
187187
name: Preview CHANGELOG for next release (only on master)
188-
command: if [ $CIRCLE_BRANCH == "master" ]; then npm run use-draftlogs && git --no-pager diff --color-words CHANGELOG.md || true; fi
188+
command: |
189+
if [ $CIRCLE_BRANCH == "master" ]
190+
then npm run use-draftlogs && git --no-pager diff --color-words CHANGELOG.md || true
191+
fi
192+
- run:
193+
name: Set draft version in package.json
194+
command: |
195+
node --eval "var fs = require('fs'); var inOut = './package.json'; var data = JSON.parse(fs.readFileSync(inOut)); var a = process.argv; data.version = a[a.length - 1].replace('v', ''); fs.writeFileSync(inOut, JSON.stringify(data, null, 2) + '\n');" `git describe`
196+
- run:
197+
name: View package.json diff between previous and next releases (including above draft version change)
198+
command: git --no-pager diff --color-words tags/$(git describe --tags --abbrev=0) package.json || true
189199
- run:
190200
name: Build dist/
191201
command: npm run build
192202
- store_artifacts:
193203
path: dist
194204
destination: dist
205+
- run:
206+
name: Preview plot-schema diff between previous and next releases (only on master)
207+
command: |
208+
if [ $CIRCLE_BRANCH == "master" ]
209+
then git --no-pager diff tags/$(git describe --tags --abbrev=0) dist/plot-schema.json || true
210+
fi
195211
- run:
196212
name: Pack tarball
197213
command: |
198214
npm pack
199-
version=$(node -e "console.log(require('./package.json').version)")
215+
version=$(node --eval "console.log(require('./package.json').version)")
200216
mv plotly.js-$version.tgz plotly.js.tgz
201217
- store_artifacts:
202218
path: plotly.js.tgz

draftlogs/5500_fix.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Improve rendering of scattergl, splom and parcoords by implementing plotGlPixelRatio for those traces [[#5500](https://github.com/plotly/plotly.js/pull/5500)]

draftlogs/5801_add.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Add satellite and various projection types to geo subplots [[#5801](https://github.com/plotly/plotly.js/pull/5801)]

draftlogs/5814_add.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Preview plot-schema changes between previous and next release when building dist on master [[#5814](https://github.com/plotly/plotly.js/pull/5814)]

draftlogs/5815_change.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Label draft bundles and show package.json diff between versions when publishing dist artifacts on CircleCI [[#5815](https://github.com/plotly/plotly.js/pull/5815)]

draftlogs/5818_fix.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
- Adjust links to time format options so that they point to the d3-time-format v2.2.3 applied not the latest [[#5818](https://github.com/plotly/plotly.js/pull/5818)]

src/constants/docs.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22

33
module.exports = {
44
FORMAT_LINK: 'https://github.com/d3/d3-3.x-api-reference/blob/master/Formatting.md#d3_format',
5-
DATE_FORMAT_LINK: 'https://github.com/d3/d3-time-format#locale_format'
5+
DATE_FORMAT_LINK: 'https://github.com/d3/d3-time-format/tree/v2.2.3#locale_format'
66
};

src/lib/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@ var MAX_SAFE = numConstants.FP_SAFE;
99
var MIN_SAFE = -MAX_SAFE;
1010
var BADNUM = numConstants.BADNUM;
1111

12-
var lib = module.exports = {};
12+
var lib = module.exports = {
13+
_numberFormat: d3.format // simply to test d3.format before switching to d3-format
14+
};
1315

1416
lib.nestedProperty = require('./nested_property');
1517
lib.keyedContainer = require('./keyed_container');

src/plot_api/plot_api.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -222,17 +222,20 @@ function _doPlot(gd, data, layout, config) {
222222
});
223223
}
224224

225+
var plotGlPixelRatio = gd._context.plotGlPixelRatio;
225226
if(fullLayout._glcanvas) {
226227
fullLayout._glcanvas
227-
.attr('width', fullLayout.width)
228-
.attr('height', fullLayout.height);
228+
.attr('width', fullLayout.width * plotGlPixelRatio)
229+
.attr('height', fullLayout.height * plotGlPixelRatio)
230+
.style('width', fullLayout.width + 'px')
231+
.style('height', fullLayout.height + 'px');
229232

230233
var regl = fullLayout._glcanvas.data()[0].regl;
231234
if(regl) {
232235
// Unfortunately, this can happen when relayouting to large
233236
// width/height on some browsers.
234-
if(Math.floor(fullLayout.width) !== regl._gl.drawingBufferWidth ||
235-
Math.floor(fullLayout.height) !== regl._gl.drawingBufferHeight
237+
if(Math.floor(fullLayout.width * plotGlPixelRatio) !== regl._gl.drawingBufferWidth ||
238+
Math.floor(fullLayout.height * plotGlPixelRatio) !== regl._gl.drawingBufferHeight
236239
) {
237240
var msg = 'WebGL context buffer and canvas dimensions do not match due to browser/WebGL bug.';
238241
if(drawFrameworkCalls) {

src/plots/cartesian/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -596,8 +596,8 @@ exports.toSVG = function(gd) {
596596
preserveAspectRatio: 'none',
597597
x: 0,
598598
y: 0,
599-
width: canvas.width,
600-
height: canvas.height
599+
width: canvas.style.width,
600+
height: canvas.style.height
601601
});
602602
}
603603

0 commit comments

Comments
 (0)