fix(admin): add profile breadcrumb and fix badge dark mode styling
This commit is contained in:
@@ -44,6 +44,12 @@ const AdminTop = ({ isMobileMenuOpen, setIsMobileMenuOpen, user, onLogout, appNa
|
||||
if (!segments.length || (segments[0] === 'dashboard' && segments.length === 1)) return crumbs;
|
||||
|
||||
const [first, second] = segments;
|
||||
|
||||
if (first === 'profile') {
|
||||
crumbs.push({ label: 'Mon profil' });
|
||||
return crumbs;
|
||||
}
|
||||
|
||||
const allItems = navigationSections.flatMap(s => s.items);
|
||||
const navItem = allItems.find(item => item.href.replace('/admin/', '').split('/')[0] === first);
|
||||
const hasSubPage = segments.length > 1;
|
||||
@@ -85,7 +91,7 @@ const AdminTop = ({ isMobileMenuOpen, setIsMobileMenuOpen, user, onLogout, appNa
|
||||
|
||||
{/* Desktop breadcrumb — always rendered to keep user menu pinned right */}
|
||||
<div className="hidden lg:flex items-center gap-1.5 text-[13px]">
|
||||
{breadcrumbs.length > 1 && breadcrumbs.map((crumb, i) => (
|
||||
{breadcrumbs.length > 0 && breadcrumbs.map((crumb, i) => (
|
||||
<Fragment key={i}>
|
||||
{i > 0 && (
|
||||
<svg width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round" className="text-neutral-400 dark:text-neutral-600 flex-shrink-0">
|
||||
|
||||
Reference in New Issue
Block a user