|
9 | 9 | 'use strict';
|
10 | 10 |
|
11 | 11 | var colorAttrs = require('../../../components/color/attributes');
|
| 12 | +var domainAttrs = require('../../domain_attributes'); |
12 | 13 | var constants = require('../constants');
|
13 | 14 | var overrideAll = require('../../../plot_api/edit_types').overrideAll;
|
14 | 15 |
|
@@ -65,40 +66,14 @@ var geoAxesAttrs = {
|
65 | 66 | };
|
66 | 67 |
|
67 | 68 | module.exports = overrideAll({
|
68 |
| - domain: { |
69 |
| - x: { |
70 |
| - valType: 'info_array', |
71 |
| - role: 'info', |
72 |
| - items: [ |
73 |
| - {valType: 'number', min: 0, max: 1}, |
74 |
| - {valType: 'number', min: 0, max: 1} |
75 |
| - ], |
76 |
| - dflt: [0, 1], |
77 |
| - description: [ |
78 |
| - 'Sets the maximum horizontal domain of this map', |
79 |
| - '(in plot fraction).', |
80 |
| - 'Note that geo subplots are constrained by domain.', |
81 |
| - 'In general, when `projection.scale` is set to 1.', |
82 |
| - 'a map will fit either its x or y domain, but not both. ' |
83 |
| - ].join(' ') |
84 |
| - }, |
85 |
| - y: { |
86 |
| - valType: 'info_array', |
87 |
| - role: 'info', |
88 |
| - items: [ |
89 |
| - {valType: 'number', min: 0, max: 1}, |
90 |
| - {valType: 'number', min: 0, max: 1} |
91 |
| - ], |
92 |
| - dflt: [0, 1], |
93 |
| - description: [ |
94 |
| - 'Sets the maximum vertical domain of this map', |
95 |
| - '(in plot fraction).', |
96 |
| - 'Note that geo subplots are constrained by domain.', |
97 |
| - 'In general, when `projection.scale` is set to 1.', |
98 |
| - 'a map will fit either its x or y domain, but not both. ' |
99 |
| - ].join(' ') |
100 |
| - } |
101 |
| - }, |
| 69 | + domain: domainAttrs({name: 'geo'}, { |
| 70 | + description: [ |
| 71 | + 'Note that geo subplots are constrained by domain.', |
| 72 | + 'In general, when `projection.scale` is set to 1.', |
| 73 | + 'a map will fit either its x or y domain, but not both. ' |
| 74 | + ].join(' ') |
| 75 | + }), |
| 76 | + |
102 | 77 | resolution: {
|
103 | 78 | valType: 'enumerated',
|
104 | 79 | values: [110, 50],
|
|
0 commit comments