some change
This commit is contained in:
parent
d4a1492d56
commit
313f1def49
38 changed files with 475 additions and 401 deletions
|
@ -1,4 +1,4 @@
|
|||
import { useUser } from '../store/userStore'
|
||||
import { useUser } from '../app/user/userStore'
|
||||
import NavLinkButton from './NavLinkButton'
|
||||
|
||||
export default function NavBar() {
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { PropsWithChildren } from 'react'
|
||||
import { Link } from 'react-router'
|
||||
import { Link } from 'react-router-dom'
|
||||
interface NavLinkButtonProps {
|
||||
to: string
|
||||
}
|
||||
|
|
|
@ -18,11 +18,7 @@ export default function SecondaryButton({
|
|||
type={type}
|
||||
disabled={disabled}
|
||||
onClick={onClick}
|
||||
className={`
|
||||
px-4 p-2 rounded-md
|
||||
text-primary-500 hover:text-primary-700
|
||||
cursor-pointer disabled:cursor-default
|
||||
${extraClasses}
|
||||
className={`secondary-button ${extraClasses}
|
||||
`}
|
||||
>
|
||||
{children}
|
||||
|
|
18
src/components/SecondaryLinkButton.tsx
Normal file
18
src/components/SecondaryLinkButton.tsx
Normal file
|
@ -0,0 +1,18 @@
|
|||
import { PropsWithChildren } from 'react'
|
||||
|
||||
interface SecondaryLinkButtonProps {
|
||||
href: string
|
||||
className?: string
|
||||
}
|
||||
|
||||
export default function SecondaryLinkButton({
|
||||
href,
|
||||
className: extraClasses = '',
|
||||
children,
|
||||
}: PropsWithChildren<SecondaryLinkButtonProps>) {
|
||||
return (
|
||||
<a href={href} className={`secondary-button text-center ${extraClasses}`}>
|
||||
{children}
|
||||
</a>
|
||||
)
|
||||
}
|
19
src/components/SecondaryNavButton.tsx
Normal file
19
src/components/SecondaryNavButton.tsx
Normal file
|
@ -0,0 +1,19 @@
|
|||
import { PropsWithChildren } from 'react'
|
||||
import { Link } from 'react-router-dom'
|
||||
|
||||
interface SecondaryNavButtonProps {
|
||||
to: string
|
||||
className?: string
|
||||
}
|
||||
|
||||
export default function SecondaryNavButton({
|
||||
to,
|
||||
className: extraClasses = '',
|
||||
children,
|
||||
}: PropsWithChildren<SecondaryNavButtonProps>) {
|
||||
return (
|
||||
<Link to={to} className={`secondary-button text-center ${extraClasses}`}>
|
||||
{children}
|
||||
</Link>
|
||||
)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue