12
12
var Loggers = require ( './lib/loggers' ) ;
13
13
var noop = require ( './lib/noop' ) ;
14
14
var pushUnique = require ( './lib/push_unique' ) ;
15
+ var ExtendModule = require ( './lib/extend' ) ;
16
+ var extendFlat = ExtendModule . extendFlat ;
17
+ var extendDeep = ExtendModule . extendDeep ;
18
+
15
19
var basePlotAttributes = require ( './plots/attributes' ) ;
16
20
var baseLayoutAttributes = require ( './plots/layout_attributes' ) ;
17
- var Lib = require ( './lib' ) ;
18
21
19
22
exports . modules = { } ;
20
23
exports . allCategories = { } ;
@@ -68,7 +71,7 @@ exports.register = function(_module, thisType, categoriesIn, meta) {
68
71
* (at least after https://github.com/plotly/documentation/issues/202 gets done!)
69
72
*/
70
73
if ( _module . layoutAttributes ) {
71
- Lib . extendFlat ( exports . traceLayoutAttributes , _module . layoutAttributes ) ;
74
+ extendFlat ( exports . traceLayoutAttributes , _module . layoutAttributes ) ;
72
75
}
73
76
} ;
74
77
@@ -137,7 +140,7 @@ exports.registerComponent = function(_module) {
137
140
}
138
141
139
142
if ( _module . schema && _module . schema . layout ) {
140
- Lib . extendDeep ( baseLayoutAttributes , _module . schema . layout ) ;
143
+ extendDeep ( baseLayoutAttributes , _module . schema . layout ) ;
141
144
}
142
145
} ;
143
146
@@ -166,7 +169,7 @@ function mergeComponentAttrsToTrace(componentName, traceType) {
166
169
167
170
var traceAttrs = componentSchema . traces [ traceType ] ;
168
171
if ( traceAttrs ) {
169
- Lib . extendDeep ( exports . modules [ traceType ] . _module . attributes , traceAttrs ) ;
172
+ extendDeep ( exports . modules [ traceType ] . _module . attributes , traceAttrs ) ;
170
173
}
171
174
}
172
175
@@ -176,7 +179,7 @@ function mergeComponentAttrsToTransform(componentName, transformType) {
176
179
177
180
var transformAttrs = componentSchema . transforms [ transformType ] ;
178
181
if ( transformAttrs ) {
179
- Lib . extendDeep ( exports . transformsRegistry [ transformType ] . attributes , transformAttrs ) ;
182
+ extendDeep ( exports . transformsRegistry [ transformType ] . attributes , transformAttrs ) ;
180
183
}
181
184
}
182
185
@@ -191,7 +194,7 @@ function mergeComponentAttrsToSubplot(componentName, subplotName) {
191
194
192
195
var componentLayoutAttrs = componentSchema . subplots [ subplotAttr ] ;
193
196
if ( subplotAttrs && componentLayoutAttrs ) {
194
- Lib . extendDeep ( subplotAttrs , componentLayoutAttrs ) ;
197
+ extendDeep ( subplotAttrs , componentLayoutAttrs ) ;
195
198
}
196
199
}
197
200
0 commit comments