Skip to content

Commit fdfca3b

Browse files
committed
make geo.(lon|lat)axis.tick0 dflt=0
- so that it matches the current behavior (i.e. where tick0 didn't do a thing)
1 parent d3270c3 commit fdfca3b

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

src/plots/geo/layout/defaults.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ function handleGeoDefaults(geoLayoutIn, geoLayoutOut, coerce) {
6060

6161
var range = coerce(axisName + '.range', rangeDflt);
6262

63-
coerce(axisName + '.tick0', range[0]);
63+
coerce(axisName + '.tick0');
6464
coerce(axisName + '.dtick', dtickDflt);
6565

6666
show = coerce(axisName + '.showgrid');

src/plots/geo/layout/layout_attributes.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ var geoAxesAttrs = {
3535
tick0: {
3636
valType: 'number',
3737
role: 'info',
38+
dflt: 0,
3839
description: [
3940
'Sets the graticule\'s starting tick longitude/latitude.'
4041
].join(' ')
-1.27 KB
Loading

test/image/mocks/geo_kavrayskiy7.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@
7373
"lataxis": {
7474
"showgrid": true,
7575
"range": [ -75, 85 ],
76-
"tick0": 0,
7776
"gridwidth": 2,
7877
"gridcolor": "black"
7978
}

test/jasmine/tests/geo_test.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -268,8 +268,8 @@ describe('Test Geo layout defaults', function() {
268268

269269
expect(layoutOut.geo.lonaxis.range).toEqual(dfltLonaxisRange);
270270
expect(layoutOut.geo.lataxis.range).toEqual(dfltLataxisRange);
271-
expect(layoutOut.geo.lonaxis.tick0).toEqual(dfltLonaxisRange[0]);
272-
expect(layoutOut.geo.lataxis.tick0).toEqual(dfltLataxisRange[0]);
271+
expect(layoutOut.geo.lonaxis.tick0).toEqual(0);
272+
expect(layoutOut.geo.lataxis.tick0).toEqual(0);
273273
});
274274

275275
it('custom case for ' + s, function() {
@@ -284,8 +284,8 @@ describe('Test Geo layout defaults', function() {
284284

285285
expect(layoutOut.geo.lonaxis.range).toEqual(customLonaxisRange);
286286
expect(layoutOut.geo.lataxis.range).toEqual(customLataxisRange);
287-
expect(layoutOut.geo.lonaxis.tick0).toEqual(customLonaxisRange[0]);
288-
expect(layoutOut.geo.lataxis.tick0).toEqual(customLataxisRange[0]);
287+
expect(layoutOut.geo.lonaxis.tick0).toEqual(0);
288+
expect(layoutOut.geo.lataxis.tick0).toEqual(0);
289289
});
290290
});
291291
});

0 commit comments

Comments
 (0)