Skip to content

Commit

Permalink
Fix layout issues
Browse files Browse the repository at this point in the history
  • Loading branch information
zahrabayatt committed Oct 16, 2024
1 parent a237450 commit bcf563d
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/components/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const Sidebar = () => {
return (
<aside
className={cn(
"bg-dark-purple h-screen p-5 absolute duration-300 transition-width sm:relative",
"flex flex-col bg-dark-purple h-full p-5 absolute duration-300 transition-width sm:relative",
isExtend ? "w-72" : "w-20 "
)}
>
Expand Down
2 changes: 1 addition & 1 deletion src/components/category/CategorySelector.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const CategorySelector = () => {
const categories = useCategoryStore((s) => s.categories);

return (
<div className="flex flex-col space-y-2">
<div className="flex flex-col space-y-2 h-full mb-14 overflow-x-hidden overflow-y-auto scrollbar-light dark:scrollbar-dark scroll-smooth">
{categories.map((cat) => (
<NavigationLink
key={cat.id}
Expand Down
6 changes: 6 additions & 0 deletions src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
@tailwind components;
@tailwind utilities;

html,
body,
#root {
height: 100%;
}

@layer base {
.scrollbar-light::-webkit-scrollbar {
width: 3px;
Expand Down
4 changes: 2 additions & 2 deletions src/pages/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ import Sidebar from "../components/Sidebar";

const Layout = () => {
return (
<div className="min-h-screen w-full flex bg-gray-100 dark:bg-gray-800">
<div className="w-full h-full flex bg-gray-100 dark:bg-gray-800">
<Sidebar />
<main className="flex-grow w-full h-full max-sm:pl-20">
<main className="w-full h-full max-sm:pl-20">
<Outlet />
</main>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/pages/TasksPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const TasksPage = () => {
useSelectCategory(categoryId ?? null);

return (
<div className="min-h-screen w-full md:px-5 md:py-4">
<div className="w-full md:px-5 md:py-4">
<div className="container mx-auto flex flex-col gap-2 h-full w-full p-4">
<TaskFilter />
<TaskList />
Expand Down

0 comments on commit bcf563d

Please sign in to comment.