mirror of
https://github.com/MODSetter/SurfSense.git
synced 2025-09-02 02:29:08 +00:00
Merge pull request #201 from Swapnilpatil03/main
Add back button to settings page to navigate to /dashboard
This commit is contained in:
commit
abd06560a5
1 changed files with 14 additions and 2 deletions
|
@ -1,13 +1,16 @@
|
||||||
"use client";
|
"use client";
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { useRouter } from 'next/navigation'; // Add this import
|
||||||
import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs';
|
import { Tabs, TabsContent, TabsList, TabsTrigger } from '@/components/ui/tabs';
|
||||||
import { Separator } from '@/components/ui/separator';
|
import { Separator } from '@/components/ui/separator';
|
||||||
import { Bot, Settings, Brain } from 'lucide-react';
|
import { Bot, Settings, Brain, ArrowLeft } from 'lucide-react'; // Import ArrowLeft icon
|
||||||
import { ModelConfigManager } from '@/components/settings/model-config-manager';
|
import { ModelConfigManager } from '@/components/settings/model-config-manager';
|
||||||
import { LLMRoleManager } from '@/components/settings/llm-role-manager';
|
import { LLMRoleManager } from '@/components/settings/llm-role-manager';
|
||||||
|
|
||||||
export default function SettingsPage() {
|
export default function SettingsPage() {
|
||||||
|
const router = useRouter(); // Initialize router
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="min-h-screen bg-background">
|
<div className="min-h-screen bg-background">
|
||||||
<div className="container max-w-7xl mx-auto p-6 lg:p-8">
|
<div className="container max-w-7xl mx-auto p-6 lg:p-8">
|
||||||
|
@ -15,6 +18,15 @@ export default function SettingsPage() {
|
||||||
{/* Header Section */}
|
{/* Header Section */}
|
||||||
<div className="space-y-4">
|
<div className="space-y-4">
|
||||||
<div className="flex items-center space-x-4">
|
<div className="flex items-center space-x-4">
|
||||||
|
{/* Back Button */}
|
||||||
|
<button
|
||||||
|
onClick={() => router.push('/dashboard')}
|
||||||
|
className="flex items-center justify-center h-10 w-10 rounded-lg bg-primary/10 hover:bg-primary/20 transition-colors"
|
||||||
|
aria-label="Back to Dashboard"
|
||||||
|
type="button"
|
||||||
|
>
|
||||||
|
<ArrowLeft className="h-5 w-5 text-primary" />
|
||||||
|
</button>
|
||||||
<div className="flex h-12 w-12 items-center justify-center rounded-lg bg-primary/10">
|
<div className="flex h-12 w-12 items-center justify-center rounded-lg bg-primary/10">
|
||||||
<Settings className="h-6 w-6 text-primary" />
|
<Settings className="h-6 w-6 text-primary" />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Add table
Reference in a new issue