diff --git a/CHANGELOG.md b/CHANGELOG.md index 5fe51242e..3252048b9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ * *BREAKING* bump `react` to `v18`, and dev-deps accordingly. Refs STCOR-729. * Added `consortiaServices` utils to hold common consortia helpers. Refs STCOR-733. * Bump `@formatjs/cli` to `^6.1.3`. +* Forgot password and Forgot username : add placeholder to input box. Refs STCOR-728. ## [9.0.0](https://github.com/folio-org/stripes-core/tree/v9.0.0) (2023-01-30) [Full Changelog](https://github.com/folio-org/stripes-core/compare/v8.3.0...v9.0.0) diff --git a/src/components/ForgotPassword/ForgotPasswordForm.js b/src/components/ForgotPassword/ForgotPasswordForm.js index 87379b05d..c31a96581 100644 --- a/src/components/ForgotPassword/ForgotPasswordForm.js +++ b/src/components/ForgotPassword/ForgotPasswordForm.js @@ -1,7 +1,7 @@ import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { Field, Form } from 'react-final-form'; -import { FormattedMessage } from 'react-intl'; +import { FormattedMessage, injectIntl } from 'react-intl'; import { TextField, @@ -20,6 +20,9 @@ class ForgotPasswordForm extends Component { static propTypes = { onSubmit: PropTypes.func.isRequired, errors: PropTypes.arrayOf(PropTypes.object), + intl: PropTypes.shape({ + formatMessage: PropTypes.func.isRequired, + }), }; static defaultProps = { @@ -29,7 +32,8 @@ class ForgotPasswordForm extends Component { render() { const { errors, - onSubmit + onSubmit, + intl: { formatMessage } } = this.props; return ( @@ -74,6 +78,7 @@ class ForgotPasswordForm extends Component { autoComplete="on" autoCapitalize="none" autoFocus + placeholder={formatMessage({ id: 'stripes-core.placeholder.forgotPassword' })} />