Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions draftlogs/7843_change.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Change `splom.axis.matches` default from `false` to `true` [[#7843](https://github.com/plotly/plotly.js/pull/7843)]
3 changes: 1 addition & 2 deletions src/traces/splom/attributes.js
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,9 @@ module.exports = {
].join(' ')
},

// TODO make 'true' the default in v3?
matches: {
valType: 'boolean',
dflt: false,
dflt: true,
editType: 'calc',
description: [
'Determines whether or not the x & y axes generated by this',
Expand Down
2 changes: 1 addition & 1 deletion src/types/generated/schema.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10038,7 +10038,7 @@ export interface SplomData {
axis?: {
/**
* Determines whether or not the x & y axes generated by this dimension match. Equivalent to setting the `matches` axis attribute in the layout with the correct axis id.
* @default false
* @default true
*/
matches?: boolean;
/** Sets the axis type for this dimension's generated x and y axes. Note that the axis `type` values set in layout take precedence over this attribute. */
Expand Down
Binary file modified test/image/baselines/splom_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_array-styles.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_dates.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_iris.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_large.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_log.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_lower-nodiag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_lower.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_mismatched-axis-types.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_multi-axis-type.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_nodiag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_ragged-via-axes.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_ragged-via-visible-false.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_symbol_numbers.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_upper-nodiag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_upper.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified test/image/baselines/splom_with-cartesian.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 10 additions & 10 deletions test/jasmine/tests/splom_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -695,26 +695,26 @@ describe('Test splom interactions:', function() {
}

_newPlot(gd, fig).then(function() {
_assert([1198, 16558, 3358, 118]);
_assert([1198, 16798, 3358, 118]);
return Plotly.restyle(gd, 'showupperhalf', false);
})
.then(function() {
_assert([1198, 8476, 1768, 4]);
_assert([1198, 8704, 1768, 4]);
return Plotly.restyle(gd, 'diagonal.visible', false);
})
.then(function() {
_assert([1138, 7534, 1600]);
_assert([1138, 7864, 1600]);
return Plotly.restyle(gd, {
showupperhalf: true,
showlowerhalf: false
});
})
.then(function() {
_assert([7966, 112, 1588]);
_assert([7978, 112, 1588]);
return Plotly.restyle(gd, 'diagonal.visible', true);
})
.then(function() {
_assert([58, 8908, 1756, 118]);
_assert([58, 8932, 1756, 118]);
return Plotly.relayout(gd, {
'xaxis.gridcolor': null,
'xaxis.gridwidth': null,
Expand All @@ -725,7 +725,7 @@ describe('Test splom interactions:', function() {
.then(function() {
// one batch for all 'grid' lines
// and another for all 'zeroline' lines
_assert([8968, 1876]);
_assert([8992, 1876]);
})
.then(done, done.fail);
});
Expand Down Expand Up @@ -1237,7 +1237,7 @@ describe('Test splom update switchboard:', function() {

expect(scene.matrixOptions.size).toBe(20, msg);
expect(gd._fullLayout.xaxis.range)
.toBeCloseToArray([0.753, 3.246], 1, 'xrng ' + msg);
.toBeCloseToArray([0.58, 3.42], 1, 'xrng ' + msg);

return Plotly.restyle(gd, 'marker.size', [[4, 10, 20]]);
})
Expand All @@ -1255,7 +1255,7 @@ describe('Test splom update switchboard:', function() {

expect(scene.matrixOptions.sizes).toBeCloseToArray([4, 10, 20], 1, msg);
expect(gd._fullLayout.xaxis.range)
.toBeCloseToArray([0.853, 3.235], 1, 'xrng ' + msg);
.toBeCloseToArray([0.81, 3.38], 1, 'xrng ' + msg);

return Plotly.restyle(gd, 'marker.symbol', 'square');
})
Expand Down Expand Up @@ -1484,11 +1484,11 @@ describe('Test splom drag:', function() {
expect(scene.matrix.draw).toHaveBeenCalledTimes(3);

_assertRanges('after drag', [
[2.9, 7.3],
[4.0, 8.5],
[1.7, 4.7],
[0.3, 7.6]
], [
[5.1, 9.6],
[4.0, 8.5],
[1.7, 4.7],
[0.3, 7.6]
]);
Expand Down
2 changes: 1 addition & 1 deletion test/plot-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -75855,7 +75855,7 @@
"editType": "calc+clearAxisTypes",
"matches": {
"description": "Determines whether or not the x & y axes generated by this dimension match. Equivalent to setting the `matches` axis attribute in the layout with the correct axis id.",
"dflt": false,
"dflt": true,
"editType": "calc",
"valType": "boolean"
},
Expand Down