chore: Clean up some console warnings (#11061)

* Upgrade a few packages

* Update some prop types

* Update HTML

* Moar warning fixes

* Remove wrapper div
This commit is contained in:
Kamil Gabryjelski
2020-09-28 18:43:21 +02:00
committed by GitHub
parent f01b8a30f7
commit 2fd8fca207
15 changed files with 326 additions and 229 deletions

View File

@@ -40,7 +40,7 @@ export type AddSliceContainerState = {
visType: string;
};
const styleSelectWidth = { width: 600 };
const styleSelectContainer = { width: 600, marginBottom: '10px' };
export default class AddSliceContainer extends React.PureComponent<
AddSliceContainerProps,
@@ -96,27 +96,24 @@ export default class AddSliceContainer extends React.PureComponent<
<Panel.Body>
<div>
<p>{t('Choose a datasource')}</p>
<p>
<div style={styleSelectWidth}>
<Select
clearable={false}
ignoreAccents={false}
name="select-datasource"
onChange={this.changeDatasource}
options={this.props.datasources}
placeholder={t('Choose a datasource')}
style={styleSelectWidth}
value={
this.state.datasourceValue
? {
value: this.state.datasourceValue,
}
: undefined
}
width={600}
/>
</div>
</p>
<div style={styleSelectContainer}>
<Select
clearable={false}
ignoreAccents={false}
name="select-datasource"
onChange={this.changeDatasource}
options={this.props.datasources}
placeholder={t('Choose a datasource')}
value={
this.state.datasourceValue
? {
value: this.state.datasourceValue,
}
: undefined
}
width={600}
/>
</div>
<span className="text-muted">
{t(
'If the datasource you are looking for is not available in the list, follow the instructions on how to add it in the Superset tutorial.',