Initial commit: Craft2Prints with Stages 1-3
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
import Link from 'next/link';
|
||||
|
||||
const TABS = [
|
||||
{ href: '/admin/accounts', label: 'Ledger' },
|
||||
{ href: '/admin/accounts/stock', label: 'Stock' },
|
||||
{ href: '/admin/accounts/purchases', label: 'Purchases' },
|
||||
] as const;
|
||||
|
||||
export default function AccountsNav({ active }: { active: (typeof TABS)[number]['href'] }) {
|
||||
return (
|
||||
<div className="mt-4 inline-flex border border-line">
|
||||
{TABS.map((tab) => (
|
||||
<Link
|
||||
key={tab.href}
|
||||
href={tab.href}
|
||||
className={`px-4 py-1.5 text-sm ${active === tab.href ? 'bg-ink text-paper' : 'hover:text-clay'}`}
|
||||
>
|
||||
{tab.label}
|
||||
</Link>
|
||||
))}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user