From 510545bf82205d48ed0a9780d59a3f29e0ec28a7 Mon Sep 17 00:00:00 2001 From: Ebube Date: Tue, 9 Jan 2024 12:59:11 +0100 Subject: [PATCH] refactor: Your Page Code --- src/components/YourPage/UpdateButton.jsx | 14 ++++ src/components/YourPage/YourPageForm.jsx | 42 +++++++++++ src/components/YourPage/index.jsx | 90 ++++++++++++++---------- 3 files changed, 107 insertions(+), 39 deletions(-) create mode 100644 src/components/YourPage/UpdateButton.jsx create mode 100644 src/components/YourPage/YourPageForm.jsx diff --git a/src/components/YourPage/UpdateButton.jsx b/src/components/YourPage/UpdateButton.jsx new file mode 100644 index 0000000..52ee39b --- /dev/null +++ b/src/components/YourPage/UpdateButton.jsx @@ -0,0 +1,14 @@ +import LoadingSpinner from "../Spinners/LoadingSpinner"; + +const UpdateButton = ({ onClick, loading }) => ( + +); + +export default UpdateButton; diff --git a/src/components/YourPage/YourPageForm.jsx b/src/components/YourPage/YourPageForm.jsx new file mode 100644 index 0000000..0074c17 --- /dev/null +++ b/src/components/YourPage/YourPageForm.jsx @@ -0,0 +1,42 @@ +import InputCom from "../Helpers/Inputs/InputCom/index"; +import UpdateButton from "./UpdateButton"; + +const YourPageForm = ({ values, onChange, onSubmit, loading }) => ( +
+
+ +
+ +
+ +