[ABANDONED] React/Redux front end for the Flexor social network.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

24 lines
683 B

import { Dispatch } from 'redux'
import { connect } from 'react-redux'
import { setFieldValue } from 'src/actions/forms'
import { getFieldValue, getFieldNotification } from 'src/selectors/forms'
import { AppState } from 'src/types'
import PasswordField from './password-field'
const mapStateToProps = (state: AppState) => ({
value: getFieldValue<string>(state, 'password', ''),
notification: getFieldNotification(state, 'password'),
})
const mapDispatchToProps = (dispatch: Dispatch) => ({
setValue: (value: string) => {
dispatch(setFieldValue('password', value))
}
})
export default connect(
mapStateToProps,
mapDispatchToProps
)(PasswordField)