Skip to content

Commit

Permalink
feat/search: Added search bar and other minor ui fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ItsFlash10 committed Sep 10, 2024
1 parent 881b135 commit 18ce148
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion src/app/courses/[courseId]/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { QueryParams } from '@/actions/types';
import SearchBar from '@/components/search/SearchBar';
import { Sidebar } from '@/components/Sidebar';
import { getFullCourseContent } from '@/db/course';
import { authOptions } from '@/lib/auth';
Expand Down Expand Up @@ -49,7 +50,10 @@ const Layout = async ({

return (
<div className="relative flex min-h-screen flex-col py-24">
<Sidebar fullCourseContent={fullCourseContent} courseId={courseId} />
<div className="flex justify-between gap-8">
<SearchBar />
<Sidebar fullCourseContent={fullCourseContent} courseId={courseId} />
</div>
{children}
</div>
);
Expand Down
2 changes: 1 addition & 1 deletion src/components/Sidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ export function Sidebar({
variants={sidebarVariants}
className="fixed right-0 top-0 z-[99999] flex h-screen w-full flex-col gap-4 overflow-y-auto rounded-r-lg border-l border-primary/10 bg-neutral-50 dark:bg-neutral-900 md:max-w-[30vw]"
>
<div className="sticky top-0 z-10 flex items-center justify-between border-b border-primary/10 p-5">
<div className="sticky top-0 z-10 flex items-center justify-between border-b border-primary/10 bg-neutral-50 p-5 dark:bg-neutral-900">
<h4 className="text-xl font-bold tracking-tighter text-primary lg:text-2xl">
Course Content
</h4>
Expand Down

0 comments on commit 18ce148

Please sign in to comment.