Skip to content

Commit

Permalink
Fixed breadcrumbs after merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
vivek-harness committed Jan 11, 2025
1 parent 00f7c3a commit 840f490
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
4 changes: 2 additions & 2 deletions apps/gitness/src/components-v2/breadcrumbs/breadcrumbs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ function Breadcrumbs() {
<nav className="flex items-start gap-1">
{matches.map((match, index) => {
const { breadcrumb } = (match.handle || {}) as CustomHandle
const isFirst = index === 0
const isFirst = index === 1
const isLast = index === matches.length - 1

if (!breadcrumb) return null

return (
<div key={match.pathname} className="flex items-center">
{!isFirst ? <BreadcrumbSeparator className="mr-1">/</BreadcrumbSeparator> : null}
{!isFirst ? <BreadcrumbSeparator className="mr-1" /> : null}
<BreadcrumbItem>
<BreadcrumbItem>
{isLast ? (
Expand Down
4 changes: 1 addition & 3 deletions apps/gitness/src/routes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,7 @@ export const routes = (mfeProjectId = '', mfeRouteRenderer: ReactElement | null
{
path: ':spaceId',
handle: {
handle: {
breadcrumb: () => (mfeProjectId ? <span>{mfeProjectId}</span> : <ProjectDropdown />)
}
breadcrumb: () => (mfeProjectId ? <span>{mfeProjectId}</span> : <ProjectDropdown />)
},
children: [
{
Expand Down

0 comments on commit 840f490

Please sign in to comment.