mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Change to newer <Switch/> component
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
5c3035cd51
commit
c69d0d1577
@ -15,7 +15,7 @@ const {
|
|||||||
forCluster, StatefulSet, DaemonSet, Deployment,
|
forCluster, StatefulSet, DaemonSet, Deployment,
|
||||||
},
|
},
|
||||||
Component: {
|
Component: {
|
||||||
SubTitle, FormSwitch, Switcher, Button,
|
SubTitle, Switch, Button,
|
||||||
},
|
},
|
||||||
} = Renderer;
|
} = Renderer;
|
||||||
|
|
||||||
@ -207,17 +207,14 @@ export class MetricsSettings extends React.Component<MetricsSettingsProps> {
|
|||||||
)}
|
)}
|
||||||
<section>
|
<section>
|
||||||
<SubTitle title="Prometheus" />
|
<SubTitle title="Prometheus" />
|
||||||
<FormSwitch
|
<Switch
|
||||||
control={(
|
|
||||||
<Switcher
|
|
||||||
disabled={this.featureStates.kubeStateMetrics === undefined || !this.isTogglable}
|
disabled={this.featureStates.kubeStateMetrics === undefined || !this.isTogglable}
|
||||||
checked={!!this.featureStates.prometheus && this.props.cluster.status.phase == "connected"}
|
checked={!!this.featureStates.prometheus && this.props.cluster.status.phase == "connected"}
|
||||||
onChange={v => this.togglePrometheus(v.target.checked)}
|
onChange={checked => this.togglePrometheus(checked)}
|
||||||
name="prometheus"
|
name="prometheus"
|
||||||
/>
|
>
|
||||||
)}
|
Enable bundled Prometheus metrics stack
|
||||||
label="Enable bundled Prometheus metrics stack"
|
</Switch>
|
||||||
/>
|
|
||||||
<small className="hint">
|
<small className="hint">
|
||||||
Enable timeseries data visualization (Prometheus stack) for your cluster.
|
Enable timeseries data visualization (Prometheus stack) for your cluster.
|
||||||
</small>
|
</small>
|
||||||
@ -225,17 +222,14 @@ export class MetricsSettings extends React.Component<MetricsSettingsProps> {
|
|||||||
|
|
||||||
<section>
|
<section>
|
||||||
<SubTitle title="Kube State Metrics" />
|
<SubTitle title="Kube State Metrics" />
|
||||||
<FormSwitch
|
<Switch
|
||||||
control={(
|
|
||||||
<Switcher
|
|
||||||
disabled={this.featureStates.kubeStateMetrics === undefined || !this.isTogglable}
|
disabled={this.featureStates.kubeStateMetrics === undefined || !this.isTogglable}
|
||||||
checked={!!this.featureStates.kubeStateMetrics && this.props.cluster.status.phase == "connected"}
|
checked={!!this.featureStates.kubeStateMetrics && this.props.cluster.status.phase == "connected"}
|
||||||
onChange={v => this.toggleKubeStateMetrics(v.target.checked)}
|
onChange={checked => this.toggleKubeStateMetrics(checked)}
|
||||||
name="node-exporter"
|
name="kube-state-metrics"
|
||||||
/>
|
>
|
||||||
)}
|
Enable bundled kube-state-metrics stack
|
||||||
label="Enable bundled kube-state-metrics stack"
|
</Switch>
|
||||||
/>
|
|
||||||
<small className="hint">
|
<small className="hint">
|
||||||
Enable Kubernetes API object metrics for your cluster.
|
Enable Kubernetes API object metrics for your cluster.
|
||||||
Enable this only if you don't have existing kube-state-metrics stack installed.
|
Enable this only if you don't have existing kube-state-metrics stack installed.
|
||||||
@ -244,17 +238,14 @@ export class MetricsSettings extends React.Component<MetricsSettingsProps> {
|
|||||||
|
|
||||||
<section>
|
<section>
|
||||||
<SubTitle title="Node Exporter" />
|
<SubTitle title="Node Exporter" />
|
||||||
<FormSwitch
|
<Switch
|
||||||
control={(
|
|
||||||
<Switcher
|
|
||||||
disabled={this.featureStates.nodeExporter === undefined || !this.isTogglable}
|
disabled={this.featureStates.nodeExporter === undefined || !this.isTogglable}
|
||||||
checked={!!this.featureStates.nodeExporter && this.props.cluster.status.phase == "connected"}
|
checked={!!this.featureStates.nodeExporter && this.props.cluster.status.phase == "connected"}
|
||||||
onChange={v => this.toggleNodeExporter(v.target.checked)}
|
onChange={checked => this.toggleNodeExporter(checked)}
|
||||||
name="node-exporter"
|
name="node-exporter"
|
||||||
/>
|
>
|
||||||
)}
|
Enable bundled node-exporter stack
|
||||||
label="Enable bundled node-exporter stack"
|
</Switch>
|
||||||
/>
|
|
||||||
<small className="hint">
|
<small className="hint">
|
||||||
Enable node level metrics for your cluster.
|
Enable node level metrics for your cluster.
|
||||||
Enable this only if you don't have existing node-exporter stack installed.
|
Enable this only if you don't have existing node-exporter stack installed.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user