kaori пре 4 година
родитељ
комит
721f931f14
1 измењених фајлова са 7 додато и 2 уклоњено
  1. 7 2
      src/client/js/components/PasswordResetRequestForm.jsx

+ 7 - 2
src/client/js/components/PasswordResetRequestForm.jsx

@@ -1,4 +1,4 @@
-import React from 'react';
+import React, { useState } from 'react';
 import PropTypes from 'prop-types';
 import { withTranslation } from 'react-i18next';
 
@@ -6,12 +6,17 @@ import { withTranslation } from 'react-i18next';
 const PasswordResetRequestForm = (props) => {
   // TODO: apply i18n by GW-6861
   // const { t } = props;
+  const [email, setEmail] = useState();
+
+  const changeEmail = (inputValue) => {
+    setEmail(inputValue);
+  };
 
   return (
     <form role="form" className="form" method="post">
       <div className="form-group">
         <div className="input-group">
-          <input name="email" placeholder="E-mail Address" className="form-control" type="email" />
+          <input name="email" placeholder="E-mail Address" className="form-control" type="email" onChange={e => changeEmail(e.target.value)} />
         </div>
       </div>
       <div className="form-group">