-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
58 additions
and
40 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
import Header from "../../layouts/userLayout/Header"; | ||
|
||
export interface UserLayoutProps { | ||
title?: string; | ||
children?: React.ReactNode; | ||
} | ||
|
||
const UserLayout: React.FC<UserLayoutProps> = (props) => { | ||
return ( | ||
<div className="relative flex h-[100vh] flex-col"> | ||
<Header /> | ||
{props.title && ( | ||
<header className="h-auto bg-white shadow"> | ||
<div className="mx-auto max-w-7xl px-4 py-6 sm:px-6 lg:px-8"> | ||
<h1 className="text-3xl font-bold tracking-tight text-gray-900"> | ||
{props.title} | ||
</h1> | ||
</div> | ||
</header> | ||
)} | ||
<main className="flex w-full max-w-7xl flex-auto flex-col self-center py-6 sm:px-6 lg:px-8"> | ||
{props.children} | ||
</main> | ||
</div> | ||
); | ||
}; | ||
|
||
export default UserLayout; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters