File tree 4 files changed +42
-15
lines changed
4 files changed +42
-15
lines changed Original file line number Diff line number Diff line change
1
+ {
2
+ "extends" : " ibmresearch/html" ,
3
+ "globals" : {
4
+ "Polymer" : false
5
+ }
6
+ }
Original file line number Diff line number Diff line change 1
- sudo : required
2
- dist : trusty
3
1
language : node_js
4
- node_js :
5
- - ' 6'
2
+ dist : trusty
3
+ sudo : false
4
+ node_js : stable
5
+ cache :
6
+ directories :
7
+ - " node_modules"
6
8
addons :
7
- firefox : ' 46.0 '
9
+ firefox : latest
8
10
apt :
9
11
sources :
10
- - google-chrome
12
+ - google-chrome
11
13
packages :
12
- - google-chrome-stable
13
- cache :
14
- directories :
15
- - node_modules
14
+ - google-chrome-stable
16
15
install :
17
- - npm install -g web-component-tester
18
- - npm install -g bower
19
- - bower install
16
+ - npm install -g polymer-cli
17
+ - npm install -g eslint eslint-plugin-html eslint-config-ibmresearch
18
+ - polymer install --variants
19
+ before_script :
20
+ - eslint . --ext js,html --ignore-path .gitignore
20
21
script :
21
- - xvfb-run wct
22
+ - xvfb-run polymer test
Original file line number Diff line number Diff line change 43
43
</ template >
44
44
45
45
< script >
46
+ /* global WebFont:false */
47
+
46
48
Polymer ( {
47
49
is : 'gdg-logo' ,
48
50
118
120
}
119
121
} ,
120
122
123
+ // eslint-disable-next-line max-len
121
124
_computedResourcesLoaded : function ( _fontLoaded , _gdgIconLoaded , _gdgLogotypeLoaded ) {
122
125
if ( _fontLoaded && _gdgIconLoaded && _gdgLogotypeLoaded ) {
123
126
this . _drawImage ( ) ;
153
156
} ,
154
157
155
158
_drawImage : function ( ) {
159
+ var canvasWith ;
160
+
156
161
var ctx = this . _canvas . getContext ( '2d' ) ;
157
162
ctx . font = '128px "Product Sans"' ;
158
163
159
- var canvasWith = this . name ? ( ctx . measureText ( this . name ) . width + 460 + 128 ) : ( 532 + 15 ) ;
164
+ if ( this . name ) {
165
+ canvasWith = ctx . measureText ( this . name ) . width + 460 + 128 ;
166
+ } else {
167
+ canvasWith = 532 + 15 ;
168
+ }
169
+
160
170
this . _canvas . setAttribute ( 'width' , canvasWith * this . _scale ) ;
161
171
this . _canvas . setAttribute ( 'height' , 190 * this . _scale ) ;
162
172
Original file line number Diff line number Diff line change
1
+ {
2
+ "env" : {
3
+ "mocha" : true
4
+ },
5
+ "globals" : {
6
+ "assert" : false ,
7
+ "fixture" : false ,
8
+ "WCT" : false
9
+ }
10
+ }
You can’t perform that action at this time.
0 commit comments