File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -164,11 +164,12 @@ const CloseIcon = require('../icon/Close').default
164
164
Loading state
165
165
166
166
``` js
167
- initialState = { isLoading1: false , isLoading2: true };
167
+ initialState = { isLoading1: true , isLoading2: true , isLoading3 : true };
168
168
< div>
169
169
< div>
170
170
< Button
171
- variation= " primary"
171
+ variation= " danger"
172
+ size= " small"
172
173
onClick= {() => setState ({ isLoading1: ! state .isLoading1 })}
173
174
isLoading= {state .isLoading1 }
174
175
>
@@ -184,5 +185,15 @@ initialState = { isLoading1: false, isLoading2: true };
184
185
Toggle loading state
185
186
< / Button>
186
187
< / div>
188
+ < div className= " mt4" >
189
+ < Button
190
+ variation= " secondary"
191
+ size= " large"
192
+ onClick= {() => setState ({ isLoading3: ! state .isLoading3 })}
193
+ isLoading= {state .isLoading3 }
194
+ >
195
+ Toggle loading state
196
+ < / Button>
197
+ < / div>
187
198
< / div>
188
199
```
You can’t perform that action at this time.
0 commit comments