1
1
"use strict" ;
2
+ var __extends = ( this && this . __extends ) || function ( d , b ) {
3
+ for ( var p in b ) if ( b . hasOwnProperty ( p ) ) d [ p ] = b [ p ] ;
4
+ function __ ( ) { this . constructor = d ; }
5
+ d . prototype = b === null ? Object . create ( b ) : ( __ . prototype = b . prototype , new __ ( ) ) ;
6
+ } ;
7
+ var __decorate = ( this && this . __decorate ) || function ( decorators , target , key , desc ) {
8
+ var c = arguments . length , r = c < 3 ? target : desc === null ? desc = Object . getOwnPropertyDescriptor ( target , key ) : desc , d ;
9
+ if ( typeof Reflect === "object" && typeof Reflect . decorate === "function" ) r = Reflect . decorate ( decorators , target , key , desc ) ;
10
+ else for ( var i = decorators . length - 1 ; i >= 0 ; i -- ) if ( d = decorators [ i ] ) r = ( c < 3 ? d ( r ) : c > 3 ? d ( target , key , r ) : d ( target , key ) ) || r ;
11
+ return c > 3 && r && Object . defineProperty ( target , key , r ) , r ;
12
+ } ;
13
+ var __metadata = ( this && this . __metadata ) || function ( k , v ) {
14
+ if ( typeof Reflect === "object" && typeof Reflect . metadata === "function" ) return Reflect . metadata ( k , v ) ;
15
+ } ;
2
16
var React = require ( 'react' ) ;
17
+ var react_redux_1 = require ( 'react-redux' ) ;
3
18
var SystemChecks_1 = require ( './SystemChecks' ) ;
4
19
var SetupChecks_1 = require ( './SetupChecks' ) ;
5
20
var InstallGuide_1 = require ( './InstallGuide' ) ;
@@ -8,16 +23,25 @@ var styles = {
8
23
margin : '5px' ,
9
24
padding : '10px' ,
10
25
} ;
11
- var Checks = function ( _a ) {
12
- var checks = _a . checks ;
13
- if ( ! checks ) {
14
- return React . createElement ( index_1 . ContentCard , { title : 'Error Loading Package.json' , content : '' } ) ;
26
+ var Checks = ( function ( _super ) {
27
+ __extends ( Checks , _super ) ;
28
+ function Checks ( ) {
29
+ _super . apply ( this , arguments ) ;
15
30
}
16
- return ( React . createElement ( "div" , { style : styles } , ! checks . system . passed
17
- ? React . createElement ( SystemChecks_1 . default , { checks : checks } )
18
- : null , ! checks . setup . passed
19
- ? React . createElement ( SetupChecks_1 . default , { checks : checks } )
20
- : null , React . createElement ( InstallGuide_1 . default , { checks : checks } ) ) ) ;
21
- } ;
31
+ Checks . prototype . render = function ( ) {
32
+ var checks = this . props . checks ;
33
+ if ( ! checks ) {
34
+ return React . createElement ( index_1 . ContentCard , { title : 'Error Loading Package.json' } ) ;
35
+ }
36
+ return ( React . createElement ( "div" , { style : styles } , ! checks . system . passed ? React . createElement ( SystemChecks_1 . default , { checks : checks } ) : null , ! checks . setup . passed ? React . createElement ( SetupChecks_1 . default , { checks : checks } ) : null , React . createElement ( InstallGuide_1 . default , { checks : checks } ) ) ) ;
37
+ } ;
38
+ Checks = __decorate ( [
39
+ react_redux_1 . connect ( function ( state ) { return ( {
40
+ checks : state . checks ,
41
+ } ) ; } ) ,
42
+ __metadata ( 'design:paramtypes' , [ ] )
43
+ ] , Checks ) ;
44
+ return Checks ;
45
+ } ( React . Component ) ) ;
22
46
Object . defineProperty ( exports , "__esModule" , { value : true } ) ;
23
47
exports . default = Checks ;
0 commit comments