diff --git a/src/components/FieldError.jsx b/src/components/FieldError.jsx new file mode 100644 index 0000000..af6089f --- /dev/null +++ b/src/components/FieldError.jsx @@ -0,0 +1,21 @@ +import PropTypes from "prop-types"; +import { motion } from "motion/react"; + +function FieldError({ text }) { + return ( + + {text} + + ); +} + +FieldError.propTypes = { + text: PropTypes.string.isRequired, +}; + +export default FieldError; diff --git a/src/components/FormField.jsx b/src/components/FormField.jsx index 1b228ee..4a7a84d 100644 --- a/src/components/FormField.jsx +++ b/src/components/FormField.jsx @@ -2,13 +2,16 @@ import PropTypes from "prop-types"; import { motion } from "motion/react"; import clsx from "clsx"; -function FormField({ label, children, icon }) { +function FormField({ label, children, icon, variant }) { return ( -
-