Cpmpleted register form 📗

This commit is contained in:
Manik Maity
2024-11-07 23:45:34 +05:30
parent 8741f40304
commit edfce3edaa
9 changed files with 417 additions and 16 deletions

View File

@@ -0,0 +1,11 @@
import React from 'react'
function InlineTextError({mutation}) {
return (
<p className="text-red-500 text-sm md:text-base">
😵 {mutation?.error?.response?.data?.errors?.[0]?.message || mutation?.error?.response?.data?.message || "An unexpected error occurred"}
</p>
)
}
export default InlineTextError

View File

@@ -6,7 +6,7 @@ function Header() {
return (
<div className="navbar bg-base-100">
<div className="flex-1">
<Link to={"/"}><a className="btn btn-ghost text-xl">LivePoll</a></Link>
<Link to={"/"} className="btn btn-ghost text-xl">LivePoll</Link>
</div>
<div className="flex-none">
<ul className="menu menu-horizontal px-1">
@@ -27,10 +27,10 @@ function Header() {
tabIndex={0}
className="menu menu-sm dropdown-content bg-base-100 rounded-box z-[1] mt-3 w-52 p-2 shadow">
<li>
<Link to={'/dashboard'}><a className="justify-between" >
<Link to={'/dashboard'} className="justify-between" >
Profile
<span className="badge">New</span>
</a></Link>
</Link>
</li>
<li><a>Logout</a></li>
</ul>

View File

@@ -0,0 +1,9 @@
import React from 'react'
function SpinnerLoader({size = "sm"}) {
return (
<span className={`loading loading-spinner loading-${size}`}></span>
)
}
export default SpinnerLoader