File tree Expand file tree Collapse file tree 3 files changed +35
-8
lines changed
Expand file tree Collapse file tree 3 files changed +35
-8
lines changed Original file line number Diff line number Diff line change 11import { Link , useLocation } from 'react-router-dom' ;
22import Logo from './Logo' ;
33import SourceList from './SourceList' ;
4+ import HelpIcon from '../icons/HelpIcon' ;
5+ import HomeIcon from '../icons/HomeIcon' ;
46import { cn } from '../../lib/utils' ;
57import type { DataSource } from '../../types/datasource' ;
68
@@ -9,14 +11,6 @@ interface SidebarProps {
911 isLoading : boolean ;
1012}
1113
12- function HomeIcon ( ) {
13- return (
14- < svg className = "w-5 h-5" fill = "none" viewBox = "0 0 24 24" stroke = "currentColor" >
15- < path strokeLinecap = "round" strokeLinejoin = "round" strokeWidth = { 2 } d = "M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6" />
16- </ svg >
17- ) ;
18- }
19-
2014export default function Sidebar ( { sources, isLoading } : SidebarProps ) {
2115 const location = useLocation ( ) ;
2216 const isHomeActive = location . pathname === '/' ;
@@ -38,6 +32,17 @@ export default function Sidebar({ sources, isLoading }: SidebarProps) {
3832 </ Link >
3933 < SourceList sources = { sources } isLoading = { isLoading } />
4034 </ nav >
35+ < div className = "border-t border-border px-4 py-2" >
36+ < a
37+ href = "https://dbhub.ai"
38+ target = "_blank"
39+ rel = "noopener noreferrer"
40+ className = "flex items-center gap-3 px-2 py-1 text-sm text-muted-foreground transition-colors hover:text-foreground cursor-pointer"
41+ >
42+ < HelpIcon />
43+ < span > Help</ span >
44+ </ a >
45+ </ div >
4146 </ aside >
4247 ) ;
4348}
Original file line number Diff line number Diff line change 1+ interface HelpIconProps {
2+ className ?: string ;
3+ }
4+
5+ export default function HelpIcon ( { className = 'w-5 h-5' } : HelpIconProps ) {
6+ return (
7+ < svg className = { className } fill = "none" viewBox = "0 0 24 24" stroke = "currentColor" >
8+ < path strokeLinecap = "round" strokeLinejoin = "round" strokeWidth = { 2 } d = "M8.228 9c.549-1.165 2.03-2 3.772-2 2.21 0 4 1.343 4 3 0 1.4-1.278 2.575-3.006 2.907-.542.104-.994.54-.994 1.093m0 3h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
9+ </ svg >
10+ ) ;
11+ }
Original file line number Diff line number Diff line change 1+ interface HomeIconProps {
2+ className ?: string ;
3+ }
4+
5+ export default function HomeIcon ( { className = 'w-5 h-5' } : HomeIconProps ) {
6+ return (
7+ < svg className = { className } fill = "none" viewBox = "0 0 24 24" stroke = "currentColor" >
8+ < path strokeLinecap = "round" strokeLinejoin = "round" strokeWidth = { 2 } d = "M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6" />
9+ </ svg >
10+ ) ;
11+ }
You can’t perform that action at this time.
0 commit comments