diff --git a/components/carnet/navigation.tsx b/components/carnet/navigation.tsx index dee9b54c..ef57e325 100644 --- a/components/carnet/navigation.tsx +++ b/components/carnet/navigation.tsx @@ -1,12 +1,9 @@ "use client"; import React, { useState } from 'react'; -import { Search, BookOpen, Tag, Trash2, Star, Archive, X, Folder, FileText, Calendar, Heart, Users, LucideIcon, Layout, Plus } from 'lucide-react'; -import { PaneLayout } from '@/app/carnet/page'; +import { Search, BookOpen, Tag, Trash2, Star, Archive, X, Folder, FileText, Calendar, Heart, Users, LucideIcon, Plus } from 'lucide-react'; interface NavigationProps { - layout: string; - onLayoutChange: (layout: string) => void; nextcloudFolders: string[]; onFolderSelect: (folder: string) => void; onNewNote: () => void; @@ -27,7 +24,7 @@ const FOLDER_CONFIG: Record = { 'Contacts': { icon: Users, order: 4 } }; -export default function Navigation({ layout, onLayoutChange, nextcloudFolders, onFolderSelect, onNewNote }: NavigationProps) { +export default function Navigation({ nextcloudFolders, onFolderSelect, onNewNote }: NavigationProps) { const [searchQuery, setSearchQuery] = useState(''); const getFolderIcon = (folder: string) => { @@ -87,36 +84,6 @@ export default function Navigation({ layout, onLayoutChange, nextcloudFolders, o - {/* Layout Selection */} -
-
- - Vues -
-
- - -
-
- {/* Folders */}
diff --git a/components/carnet/notes-view.tsx b/components/carnet/notes-view.tsx index 27128de9..4eb3e9d5 100644 --- a/components/carnet/notes-view.tsx +++ b/components/carnet/notes-view.tsx @@ -18,9 +18,10 @@ interface Note { interface NotesViewProps { onNoteSelect?: (note: Note) => void; currentFolder?: string; + onNewNote?: () => void; } -export const NotesView: React.FC = ({ onNoteSelect, currentFolder = 'Notes' }) => { +export const NotesView: React.FC = ({ onNoteSelect, currentFolder = 'Notes', onNewNote }) => { const [searchQuery, setSearchQuery] = useState(''); const [notes, setNotes] = useState([]); const [loading, setLoading] = useState(true); @@ -97,8 +98,17 @@ export const NotesView: React.FC = ({ onNoteSelect, currentFolde return (
- {/* Search Header */} + {/* Header with New Note Button */}
+
+

{currentFolder}

+ +