@@ -2,6 +2,7 @@ var Plotly = require('@lib/index');
2
2
var Lib = require ( '@src/lib' ) ;
3
3
var Plots = require ( '@src/plots/plots' ) ;
4
4
var Table = require ( '@src/traces/table' ) ;
5
+ var attributes = require ( '@src/traces/table/attributes' ) ;
5
6
var cn = require ( '@src/traces/table/constants' ) . cn ;
6
7
7
8
var createGraphDiv = require ( '../assets/create_graph_div' ) ;
@@ -76,8 +77,8 @@ describe('table initialization tests', function() {
76
77
77
78
it ( '\'line\' specification should yield a default color' , function ( ) {
78
79
var fullTrace = _supply ( { } ) ;
79
- expect ( fullTrace . header . fill . color ) . toEqual ( '#777' ) ;
80
- expect ( fullTrace . cells . fill . color ) . toEqual ( '#777' ) ;
80
+ expect ( fullTrace . header . fill . color ) . toEqual ( attributes . header . fill . color . dflt ) ;
81
+ expect ( fullTrace . cells . fill . color ) . toEqual ( attributes . cells . fill . color . dflt ) ;
81
82
} ) ;
82
83
83
84
it ( '\'domain\' specification should have a default' , function ( ) {
@@ -108,17 +109,17 @@ describe('table initialization tests', function() {
108
109
align : 'center' ,
109
110
height : 28 ,
110
111
line : { width : 1 , color : 'grey' } ,
111
- fill : { color : '#777' } ,
112
+ fill : { color : attributes . header . fill . color . dflt } ,
112
113
font : { family : '"Open Sans", verdana, arial, sans-serif' , size : 12 , color : '#444' }
113
114
} ) ;
114
115
115
116
expect ( fullTrace . cells ) . toEqual ( {
116
117
values : [ 1 , 2 ] ,
117
118
format : [ ] ,
118
119
align : 'center' ,
119
- height : 28 ,
120
+ height : 20 ,
120
121
line : { width : 1 , color : 'grey' } ,
121
- fill : { color : '#777' } ,
122
+ fill : { color : attributes . cells . fill . color . dflt } ,
122
123
font : { family : '"Open Sans", verdana, arial, sans-serif' , size : 12 , color : '#444' }
123
124
} ) ;
124
125
} ) ;
0 commit comments