Merge pull request #4230 from influxdata/wizard-bug/password-fields
Add password input text field to WizardTextInputpull/4225/head
commit
b4c3b7ce63
|
@ -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<Props, State> {
|
|||
}),
|
||||
valueModifier: x => x,
|
||||
autoFocus: false,
|
||||
type: 'text',
|
||||
}
|
||||
|
||||
constructor(props) {
|
||||
|
@ -50,6 +52,7 @@ class WizardTextInput extends PureComponent<Props, State> {
|
|||
value,
|
||||
autoFocus,
|
||||
label,
|
||||
type,
|
||||
} = this.props
|
||||
|
||||
let inputClass = ''
|
||||
|
@ -64,7 +67,7 @@ class WizardTextInput extends PureComponent<Props, State> {
|
|||
<div className="form-group col-xs-6">
|
||||
<label htmlFor={label}>{label}</label>
|
||||
<input
|
||||
type="text"
|
||||
type={type}
|
||||
id={label}
|
||||
className={`form-control input-sm ${inputClass}`}
|
||||
value={value}
|
||||
|
|
|
@ -46,6 +46,7 @@ class KapacitorForm extends PureComponent<Props> {
|
|||
<WizardTextInput
|
||||
value={kapacitor.password}
|
||||
label="Password"
|
||||
type="password"
|
||||
onChange={onChangeInput('password')}
|
||||
/>
|
||||
{this.isHTTPS && (
|
||||
|
|
|
@ -122,6 +122,7 @@ class SourceStep extends PureComponent<Props, State> {
|
|||
value={source.password}
|
||||
label="Password"
|
||||
placeholder={this.passwordPlaceholder}
|
||||
type="password"
|
||||
onChange={this.onChangeInput('password')}
|
||||
/>
|
||||
<WizardTextInput
|
||||
|
|
Loading…
Reference in New Issue