mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
### What problem does this PR solve? Feat: Add Sessions component #3221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
26
web/src/components/page-header.tsx
Normal file
26
web/src/components/page-header.tsx
Normal file
@ -0,0 +1,26 @@
|
||||
import { ArrowLeft } from 'lucide-react';
|
||||
import { PropsWithChildren, ReactNode } from 'react';
|
||||
import { Button } from './ui/button';
|
||||
|
||||
interface IPageHeaderProps extends PropsWithChildren {
|
||||
back(): void;
|
||||
title: ReactNode;
|
||||
}
|
||||
|
||||
export function PageHeader({ back, title, children }: IPageHeaderProps) {
|
||||
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>
|
||||
{children}
|
||||
</header>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user