Merge pull request 'UI: fix overflow behavior sidebar' (#2475) from hsjobeki/clan-core:hsjobeki-main into main
This commit is contained in:
@@ -6,6 +6,15 @@
|
|||||||
@import "./sidebar-profile";
|
@import "./sidebar-profile";
|
||||||
|
|
||||||
/* Sidebar Structure */
|
/* Sidebar Structure */
|
||||||
|
|
||||||
|
.sidebar {
|
||||||
|
min-width: theme(width.72);
|
||||||
|
height: 100%;
|
||||||
|
background-color: var(--clr-bg-inv-2);
|
||||||
|
border: 1px solid var(--clr-border-inv-2);
|
||||||
|
border-radius: theme(borderRadius.xl);
|
||||||
|
}
|
||||||
|
|
||||||
.sidebar__body {
|
.sidebar__body {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|||||||
@@ -56,14 +56,14 @@ export const Sidebar = (props: RouteSectionProps) => {
|
|||||||
}));
|
}));
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<div class="sidebar opacity-95">
|
||||||
<Show
|
<Show
|
||||||
when={query.data}
|
when={query.data}
|
||||||
fallback={<SidebarHeader clanName={"Untitled"} />}
|
fallback={<SidebarHeader clanName={"Untitled"} />}
|
||||||
>
|
>
|
||||||
{(meta) => <SidebarHeader clanName={meta().name} />}
|
{(meta) => <SidebarHeader clanName={meta().name} />}
|
||||||
</Show>
|
</Show>
|
||||||
<div class="sidebar__body overflow-y-scroll">
|
<div class="sidebar__body max-h-[calc(100vh-4rem)] overflow-scroll">
|
||||||
<For each={routes.filter((r) => !r.hidden && r.path != "/clans")}>
|
<For each={routes.filter((r) => !r.hidden && r.path != "/clans")}>
|
||||||
{(route: AppRoute) => (
|
{(route: AppRoute) => (
|
||||||
<Show
|
<Show
|
||||||
@@ -90,6 +90,6 @@ export const Sidebar = (props: RouteSectionProps) => {
|
|||||||
)}
|
)}
|
||||||
</For>
|
</For>
|
||||||
</div>
|
</div>
|
||||||
</>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ export const Layout: Component<RouteSectionProps> = (props) => {
|
|||||||
{props.children}
|
{props.children}
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
class="drawer-side z-40 h-full min-w-72 rounded-xl border opacity-95 bg-inv-2 border-inv-2"
|
class="drawer-side z-40 h-full !overflow-hidden"
|
||||||
classList={{
|
classList={{
|
||||||
"!hidden":
|
"!hidden":
|
||||||
props.location.pathname === "welcome" || clanList().length === 0,
|
props.location.pathname === "welcome" || clanList().length === 0,
|
||||||
@@ -41,7 +41,7 @@ export const Layout: Component<RouteSectionProps> = (props) => {
|
|||||||
<label
|
<label
|
||||||
for="toplevel-drawer"
|
for="toplevel-drawer"
|
||||||
aria-label="close sidebar"
|
aria-label="close sidebar"
|
||||||
class="drawer-overlay"
|
class="drawer-overlay !h-full !overflow-hidden "
|
||||||
></label>
|
></label>
|
||||||
<Sidebar {...props} />
|
<Sidebar {...props} />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user