mirror of
https://github.com/nicotsx/ironmount.git
synced 2025-12-10 12:10:51 +01:00
feat: snapshot files list frontend
This commit is contained in:
@@ -23,10 +23,20 @@ export function generateBreadcrumbs(pathname: string, params: Record<string, str
|
||||
});
|
||||
|
||||
if (pathname.startsWith("/repositories/") && params.name) {
|
||||
const isSnapshotPage = !!params.snapshotId;
|
||||
|
||||
breadcrumbs.push({
|
||||
label: params.name,
|
||||
isCurrentPage: true,
|
||||
href: isSnapshotPage ? `/repositories/${params.name}` : undefined,
|
||||
isCurrentPage: !isSnapshotPage,
|
||||
});
|
||||
|
||||
if (isSnapshotPage && params.snapshotId) {
|
||||
breadcrumbs.push({
|
||||
label: params.snapshotId,
|
||||
isCurrentPage: true,
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
return breadcrumbs;
|
||||
|
||||
Reference in New Issue
Block a user