Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@ export { default as ClanAddSubPage } from './ui/ClanAddSubPage/ClanAddSubPage';
export { default as MyClanPage } from './ui/MyClanPage/MyClanPage';

export { default as ClanLeaderBoardPage } from './ui/ClanLeaderBoardPage/ClanLeaderBoardPage';

export { default as ClanLayout } from './ui/ClanLayout/ClanLayout';
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
/* Base styles */
.layoutContainer {
display: flex;
height: 100vh;
max-width: 1400px;
margin: 0 auto;
}

.headerSidebarContainer {
display: flex;
flex-direction: column;
width: 25%;
margin: 0.5rem;
}

.header {
flex-shrink: 0;
padding: 1rem;
text-align: center;
}

/* Sidebar styles */
.sidebar {
flex: 1;
padding: 1rem;
display: none;
}

.content {
flex: 1;
padding: 1rem;
margin: 0.5rem;
}

/* Desktop */
@media (min-width: breakpoint(lg)) {
.sidebar {
display: block;
/* Visible on desktop */
}
.header {
text-align: left;
padding: 1rem 2rem;
margin-bottom: 1rem;
}
.mobileNav {
display: none;
}
}

@media (max-width: breakpoint(lg)) {
.layoutContainer {
flex-direction: column;
}
.headerSidebarContainer {
width: 100%;
margin: 0;
}
.header {
text-align: center;
height: 50px;
padding: 0.5rem;
}
.mobileNav {
display: block;
/* Visible on mobile */
margin-top: 0.5rem;
height: 50px;
}
.sidebar {
display: none;
/* Hidden on mobile */
}
.content {
margin: 0rem;
margin-top: 0.5rem;
margin-bottom: 0.5rem;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import cls from './ClanLayout.module.scss';

type LayoutProps = {
children: React.ReactNode;
};

const ClanMainPageLayout: React.FC<LayoutProps> = ({ children }) => {
return (
<div className={cls.container}>
<div className={cls.layoutContainer}>
<div className={cls.headerSidebarContainer}>
<header className={cls.header}>
<h1>Clans</h1>
</header>
<nav className={cls.mobileNav}>Mobile Dropdown</nav>
<aside className={cls.sidebar}>Sidebar</aside>
</div>
<main className={cls.content}>{children}</main>
</div>
</div>
);
};

export default ClanMainPageLayout;
Loading