Feat: Adjust the page header to breadcrumbs #3221 (#8971)

### What problem does this PR solve?

Feat: Adjust the page header to breadcrumbs #3221
### Type of change


- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
balibabu
2025-07-22 18:27:01 +08:00
committed by GitHub
parent 131fc10af5
commit e992bc5307
11 changed files with 161 additions and 138 deletions

View File

@ -1,25 +1,8 @@
import { ArrowLeft } from 'lucide-react';
import { PropsWithChildren, ReactNode } from 'react';
import { Button } from './ui/button';
import { PropsWithChildren } from 'react';
interface IPageHeaderProps extends PropsWithChildren {
back(): void;
title: ReactNode;
}
export function PageHeader({ back, title, children }: IPageHeaderProps) {
export function PageHeader({ children }: PropsWithChildren) {
return (
<header className="flex justify-between items-center border-b pr-9">
<div className="flex items-center ">
<div className="flex items-center border-r p-1.5">
<Button variant="ghost" size="icon" onClick={back}>
<ArrowLeft className="w-5 h-5" />
</Button>
</div>
<div className="p-4">
<h1 className="text-2xl font-semibold tracking-tight">{title}</h1>
</div>
</div>
<header className="flex justify-between items-center border-b bg-background-header-bar p-5">
{children}
</header>
);