File tree Expand file tree Collapse file tree 5 files changed +38
-28
lines changed
Expand file tree Collapse file tree 5 files changed +38
-28
lines changed Original file line number Diff line number Diff line change 3838 "react-image-crop" : " ^11.0.10" ,
3939 "sonner" : " ^2.0.7" ,
4040 "tailwind-merge" : " ^3.4.0" ,
41+ "tailwind-scrollbar-hide" : " ^4.0.0" ,
4142 "tw-animate-css" : " ^1.4.0" ,
4243 "zod" : " ^4.1.12"
4344 },
Original file line number Diff line number Diff line change @@ -41,28 +41,10 @@ export const GET = async (request: NextRequest) => {
4141 } ) ;
4242 }
4343 } else {
44- if ( filter === null ) {
45- const filter2 = JSON . parse ( JSON . stringify ( filter ) ) ;
46- if ( filter2 . by === "tag" ) {
47- query = dorm . and (
48- dorm . eq ( main_schema . userPosts . status , "public" ) ,
49- dorm . and (
50- dorm . eq ( main_schema . userPosts . byUser , pullFromUserId ) ,
51- dorm . inArray ( main_schema . userPosts . tags , filter2 . filter ) ,
52- ) ,
53- ) ;
54- } else {
55- query = dorm . and (
56- dorm . eq ( main_schema . userPosts . status , "public" ) ,
57- dorm . eq ( main_schema . userPosts . byUser , pullFromUserId ) ,
58- ) ;
59- }
60- } else {
61- query = dorm . and (
62- dorm . eq ( main_schema . userPosts . status , "public" ) ,
63- dorm . eq ( main_schema . userPosts . byUser , pullFromUserId ) ,
64- ) ;
65- }
44+ query = dorm . and (
45+ dorm . eq ( main_schema . userPosts . status , "public" ) ,
46+ dorm . eq ( main_schema . userPosts . byUser , pullFromUserId ) ,
47+ ) ;
6648 }
6749 const dbResult = await db
6850 . select ( )
Original file line number Diff line number Diff line change @@ -4,12 +4,12 @@ import {
44 LogOutIcon ,
55 PanelTopIcon ,
66 PlusCircleIcon ,
7- SquareChartGantt ,
87 UsersIcon ,
98 Sun ,
109 Moon ,
1110 SettingsIcon ,
1211 InfoIcon ,
12+ CircleArrowLeftIcon ,
1313} from "lucide-react" ;
1414import { Button } from "@/components/ui/button" ;
1515import Image from "next/image" ;
@@ -94,9 +94,9 @@ export default function DashboardSidebar({
9494 } ;
9595
9696 return (
97- < Sidebar className = "border-r" >
98- < SidebarHeader className = "border-b p-4" >
99- < div className = "flex flex-row justify-between" >
97+ < Sidebar className = "border-r scrollbar-hide overflow-y-hidden overscroll-y-none no-scrollbar " >
98+ < SidebarHeader className = "border-b p-4 scrollbar-hide overflow-y-hidden overscroll-y-none no-scrollbar " >
99+ < div className = "flex flex-row justify-between scrollbar-hide " >
100100 < div className = "flex items-center gap-3" >
101101 < div className = "h-8 w-8 bg-primary rounded-full flex items-center justify-center" >
102102 < Image
@@ -118,7 +118,7 @@ export default function DashboardSidebar({
118118 </ div >
119119 </ SidebarHeader >
120120
121- < SidebarContent className = "flex flex-col" >
121+ < SidebarContent className = "flex flex-col overflow-y-hidden overscroll-y-none no-scrollbar " >
122122 < SidebarGroup >
123123 < SidebarGroupLabel > </ SidebarGroupLabel >
124124 < SidebarGroupContent >
@@ -159,7 +159,18 @@ export default function DashboardSidebar({
159159 </ SidebarContent >
160160
161161 < SidebarFooter >
162- < SidebarMenu >
162+ < SidebarMenu className = "space-y-1" >
163+ < SidebarMenuItem >
164+ < Link href = "/" >
165+ < Button
166+ variant = "outline"
167+ className = "w-full justify-start hover:text-outline hover:bg-outline/10 cursor-pointer"
168+ >
169+ < CircleArrowLeftIcon className = "h-4 w-4" />
170+ < span > Back Home</ span >
171+ </ Button >
172+ </ Link >
173+ </ SidebarMenuItem >
163174 < SidebarMenuItem >
164175 < Button
165176 variant = "outline"
Original file line number Diff line number Diff line change 11@import "tailwindcss" ;
22@import "tw-animate-css" ;
3+ @import "tailwind-scrollbar-hide/v4" ;
34
45@custom-variant dark (& : where (.dark , .dark * ));
56
@@ -155,3 +156,15 @@ body {
155156 @apply bg-background text-foreground;
156157 }
157158}
159+
160+ @layer utilities {
161+ /* Hide scrollbar for Chrome, Safari, and Opera */
162+ .no-scrollbar ::-webkit-scrollbar {
163+ display : none;
164+ }
165+ /* Hide scrollbar for IE, Edge, and Firefox */
166+ .no-scrollbar {
167+ -ms-overflow-style : none; /* IE and Edge */
168+ scrollbar-width : none; /* Firefox */
169+ }
170+ }
You can’t perform that action at this time.
0 commit comments