1
+ /* eslint no-console: 'off' */
1
2
import { React , render } from '../src/imports' ;
2
3
import { WSHeader , WSDropdown , WSNotification , WSDatePicker , WSInlineEdit , WSWeekPicker , WSTilesChart } from '../src/index' ;
3
- import { dashboardMockData } from './mockdata'
4
+ import { dashboardMockData } from './mockdata' ;
4
5
import './index.scss' ;
5
6
6
7
// Used to enable React Developer Tools
@@ -12,7 +13,7 @@ render(
12
13
appName = "Demo Page"
13
14
clientId = "stups_abba-frontend-release_180e00be-2b66-4e44-ac95-37f10068c015"
14
15
links = { [
15
- { label : 'Link' , href : '#LinkValue' , onClick : ( value ) => console . log ( value ) } ,
16
+ { label : 'Link' , href : '#LinkValue' , onClick : value => console . log ( value ) } ,
16
17
{
17
18
label : 'Link2' ,
18
19
href : '#2222' ,
@@ -40,94 +41,100 @@ render(
40
41
/>
41
42
< div className = "container" >
42
43
< br />
43
- < WSDatePicker onChange = { ( date ) => console . log ( 'New Date:' , date ) } value = { Date . now ( ) } />
44
+ < WSDatePicker onChange = { date => console . log ( 'New Date:' , date ) } value = { Date . now ( ) } />
44
45
< br />
45
46
< br />
46
- < WSWeekPicker onChange = { ( { year , week} ) => console . log ( 'New week selected:' , week ) } />
47
+ < WSWeekPicker onChange = { ( { week} ) => console . log ( 'New week selected:' , week ) } />
47
48
< br />
48
49
< br />
49
- < WSDropdown text = "Multiple" type = "button" width = "500px" placeholder = "Filter values.." filterable multiple items = { [
50
- 'New' ,
51
- 'New From Template' ,
52
- 'Open' ,
53
- 'Test value 1' ,
54
- 'Open Recent' ,
55
- 'Save'
56
- ] } />
50
+ < WSDropdown
51
+ text = "Multiple" type = "button" width = "500px" placeholder = "Filter values.." filterable multiple items = { [
52
+ 'New' ,
53
+ 'New From Template' ,
54
+ 'Open' ,
55
+ 'Test value 1' ,
56
+ 'Open Recent' ,
57
+ 'Save'
58
+ ] }
59
+ />
57
60
< br />
58
- < WSDropdown text = "Simple Wide" type = "select" items = { [
59
- 'New' ,
60
- {
61
- label : 'New From Template' ,
62
- children : [
63
- 'item 2.1' ,
64
- {
65
- label : 'item 2.2' ,
66
- children : [
67
- 'item 2.3.1' ,
68
- 'item 2.3.2' ,
69
- 'item 2.3.3' ,
70
- 'item 2.3.4'
71
- ]
72
- }
73
- ]
74
- } ,
75
- 'Open' ,
76
- 'Open Recent' ,
77
- 'Save'
78
- ] } />
79
- < br />
80
- < WSDropdown text = "Simple Wide" type = "select" filterable items = { [
81
- 'New' ,
82
- {
83
- label : 'New From Template' ,
84
- children : [
85
- 'item 2.1' ,
86
- {
87
- label : 'item 2.2' ,
88
- children : [
89
- 'item 2.3.1' ,
90
- 'item 2.3.2' ,
91
- 'item 2.3.3' ,
92
- 'item 2.3.4'
93
- ]
94
- }
95
- ]
96
- } ,
97
- 'Open' ,
98
- 'Open Recent' ,
99
- 'Save'
100
- ] } />
61
+ < WSDropdown
62
+ text = "Simple Wide" type = "select" items = { [
63
+ 'New' ,
64
+ {
65
+ label : 'New From Template' ,
66
+ children : [
67
+ 'item 2.1' ,
68
+ {
69
+ label : 'item 2.2' ,
70
+ children : [
71
+ 'item 2.3.1' ,
72
+ 'item 2.3.2' ,
73
+ 'item 2.3.3' ,
74
+ 'item 2.3.4'
75
+ ]
76
+ }
77
+ ]
78
+ } ,
79
+ 'Open' ,
80
+ 'Open Recent' ,
81
+ 'Save'
82
+ ] }
83
+ />
84
+ < br />
85
+ < WSDropdown
86
+ text = "Simple Wide" type = "select" filterable items = { [
87
+ 'New' ,
88
+ {
89
+ label : 'New From Template' ,
90
+ children : [
91
+ 'item 2.1' ,
92
+ {
93
+ label : 'item 2.2' ,
94
+ children : [
95
+ 'item 2.3.1' ,
96
+ 'item 2.3.2' ,
97
+ 'item 2.3.3' ,
98
+ 'item 2.3.4'
99
+ ]
100
+ }
101
+ ]
102
+ } ,
103
+ 'Open' ,
104
+ 'Open Recent' ,
105
+ 'Save'
106
+ ] }
107
+ />
101
108
< br />
102
- < WSDropdown text = "Input" type = "select" width = "50%" placeholder = "tasd" value = "222" inputOnly />
109
+ < WSDropdown text = "Input" type = "select" width = "50%" placeholder = "tasd" value = "222" inputOnly />
103
110
< br />
104
111
< WSNotification />
105
112
< br />
106
113
< div style = { { width : '60%' } } >
107
- < WSInlineEdit text = "Some text to check" />
114
+ < WSInlineEdit text = "Some text to check" />
108
115
</ div >
109
116
< br />
110
117
< table style = { { width : '50%' } } >
111
118
< tbody >
112
119
< tr >
113
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
114
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
115
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
116
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
120
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
121
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
122
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
123
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
117
124
</ tr >
118
125
< tr >
119
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
120
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
121
- < td colSpan = "2" > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
126
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
127
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
128
+ < td colSpan = "2" > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
122
129
</ tr >
123
130
< tr >
124
- < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
125
- < td colSpan = "3" > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
131
+ < td > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
132
+ < td colSpan = "3" > < WSInlineEdit text = "Some text to check" onUpdate = { text => console . log ( text ) } /> </ td >
126
133
</ tr >
127
134
</ tbody >
128
135
</ table >
129
136
< br />
130
- < WSTilesChart title = "Chart title" data = { dashboardMockData . data } width = { 100 } height = { 100 } />
137
+ < WSTilesChart title = "Chart title" data = { dashboardMockData . data } width = { 100 } height = { 100 } />
131
138
</ div >
132
139
</ div >
133
140
, document . querySelector ( '#app-holder' ) ) ;
0 commit comments