|
@@ -0,0 +1,34 @@
|
|
|
+import React from "react";
|
|
|
+import { reduxForm, Field } from "redux-form";
|
|
|
+import authValidate from "../../utils/validate";
|
|
|
+import Auth from './index'
|
|
|
+const Form = props => {
|
|
|
+ const { handleSubmit,submitting } = props
|
|
|
+ return (
|
|
|
+ <div>
|
|
|
+ <Auth />
|
|
|
+ <form className="auth__form" onSubmit={handleSubmit}>
|
|
|
+ <div>
|
|
|
+ <Field
|
|
|
+ name="email"
|
|
|
+ component="input"
|
|
|
+ type="email"
|
|
|
+ placeholder="Email@example.com"
|
|
|
+
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <div>
|
|
|
+ <Field
|
|
|
+ name="password"
|
|
|
+ component="input"
|
|
|
+ type="password"
|
|
|
+ placeholder ="Password"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <button className="auth__submit-button">Submit</button>
|
|
|
+ </form>
|
|
|
+ </div>
|
|
|
+ );
|
|
|
+}
|
|
|
+
|
|
|
+export default reduxForm({ form: "authForm", validate: authValidate })(Form);
|