diff --git a/components/ui/Header.tsx b/components/ui/Header.tsx
index e4d9066..21cbe11 100644
--- a/components/ui/Header.tsx
+++ b/components/ui/Header.tsx
@@ -1,6 +1,7 @@
import { Card, CardContent } from '@/components/ui/Card';
import { TaskStats } from '@/lib/types';
import { useTheme } from '@/contexts/ThemeContext';
+import { useJiraConfig } from '@/contexts/JiraConfigContext';
import { usePathname } from 'next/navigation';
import Link from 'next/link';
@@ -13,6 +14,7 @@ interface HeaderProps {
export function Header({ title = "TowerControl", subtitle = "Task Management", stats, syncing = false }: HeaderProps) {
const { theme, toggleTheme } = useTheme();
+ const { isConfigured: isJiraConfigured, config: jiraConfig } = useJiraConfig();
const pathname = usePathname();
// Fonction pour déterminer si un lien est actif
@@ -82,6 +84,14 @@ export function Header({ title = "TowerControl", subtitle = "Task Management", s
>
Tags
+ {isJiraConfigured && (
+
+ Jira ({jiraConfig?.projectKey})
+
+ )}
) {
- // Récupérer uniquement le thème côté serveur pour le SSR (optimisé)
- const initialTheme = await userPreferencesService.getTheme();
+ // Récupérer les données côté serveur pour le SSR
+ const [initialTheme, jiraConfig] = await Promise.all([
+ userPreferencesService.getTheme(),
+ userPreferencesService.getJiraConfig()
+ ]);
return (
@@ -33,7 +37,9 @@ export default async function RootLayout({
className={`${geistSans.variable} ${geistMono.variable} antialiased`}
>
- {children}
+
+ {children}
+