File tree Expand file tree Collapse file tree 1 file changed +12
-7
lines changed Expand file tree Collapse file tree 1 file changed +12
-7
lines changed Original file line number Diff line number Diff line change @@ -317,6 +317,7 @@ Now you can update the **GraphConsumer** React component under the *src/webparts
317
317
318
318
``` typescript
319
319
public render (): React .ReactElement < IGraphConsumerProps > {
320
+ const { clientMode } = this.props;
320
321
return (
321
322
<div className = { styles.graphConsumer }>
322
323
<div className = { styles.container }>
@@ -332,13 +333,17 @@ Now you can update the **GraphConsumer** React component under the *src/webparts
332
333
onGetErrorMessage = { this._getSearchForErrorMessage }
333
334
/>
334
335
</p >
335
- <p className = { styles.form }>
336
- <PrimaryButton
337
- text = ' Search'
338
- title = ' Search'
339
- onClick = { this._search }
340
- />
341
- </p >
336
+ {
337
+ (clientMode === ClientMode .aad || clientMode === ClientMode .graph ) ?
338
+ <p className = {styles.form }>
339
+ <PrimaryButton
340
+ text = ' Search'
341
+ title = ' Search'
342
+ onClick = {this._search }
343
+ />
344
+ </p >
345
+ : <p >Configure client mode by editing web part properties .</p >
346
+ }
342
347
{
343
348
(this .state .users != null && this .state .users .length > 0) ?
344
349
<p className = { styles.form }>
You can’t perform that action at this time.
0 commit comments