From 452e5b8db7ed15767e621b0fcf959ed66f675ca8 Mon Sep 17 00:00:00 2001 From: Deniz Kusefoglu Date: Wed, 15 Aug 2018 15:43:26 -0700 Subject: [PATCH] Add password input text field to WizardTextInput --- ui/src/reusable_ui/components/wizard/WizardTextInput.tsx | 5 ++++- ui/src/sources/components/KapacitorForm.tsx | 1 + ui/src/sources/components/SourceStep.tsx | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ui/src/reusable_ui/components/wizard/WizardTextInput.tsx b/ui/src/reusable_ui/components/wizard/WizardTextInput.tsx index 7fa4dc790..e32af695d 100644 --- a/ui/src/reusable_ui/components/wizard/WizardTextInput.tsx +++ b/ui/src/reusable_ui/components/wizard/WizardTextInput.tsx @@ -15,6 +15,7 @@ interface Props { valueModifier?: (value: string) => string placeholder?: string autoFocus?: boolean + type?: string } interface State { @@ -32,6 +33,7 @@ class WizardTextInput extends PureComponent { }), valueModifier: x => x, autoFocus: false, + type: 'text', } constructor(props) { @@ -50,6 +52,7 @@ class WizardTextInput extends PureComponent { value, autoFocus, label, + type, } = this.props let inputClass = '' @@ -64,7 +67,7 @@ class WizardTextInput extends PureComponent {
{ {this.isHTTPS && ( diff --git a/ui/src/sources/components/SourceStep.tsx b/ui/src/sources/components/SourceStep.tsx index 8572f9e59..8416da19f 100644 --- a/ui/src/sources/components/SourceStep.tsx +++ b/ui/src/sources/components/SourceStep.tsx @@ -122,6 +122,7 @@ class SourceStep extends PureComponent { value={source.password} label="Password" placeholder={this.passwordPlaceholder} + type="password" onChange={this.onChangeInput('password')} />