Add active setting to SUI <Tab> (#821)
This commit is contained in:
parent
b2b21cf744
commit
74479ab1df
@ -99,7 +99,8 @@ class General extends React.PureComponent<Props, State> {
|
||||
|
||||
private renderEndpoint = () => {
|
||||
const { t } = this.props;
|
||||
const { isUrlValid, settings: { apiUrl } } = this.state;
|
||||
const { isCustomNode, isUrlValid, settings: { apiUrl } } = this.state;
|
||||
const activeIndex = isCustomNode ? 1 : 0;
|
||||
|
||||
const preset = (
|
||||
<Dropdown
|
||||
@ -125,7 +126,7 @@ class General extends React.PureComponent<Props, State> {
|
||||
];
|
||||
|
||||
return (
|
||||
<Tab menu={{ secondary: true }} onTabChange={this.toggleCustomNode} panes={panes} />
|
||||
<Tab menu={{ secondary: true }} activeIndex={activeIndex} onTabChange={this.toggleCustomNode} panes={panes} />
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user