/* * ============================================================================= * VibeQuant (vquant) — AI-Powered Financial Intelligence Platform * ----------------------------------------------------------------------------- * File: client/src/components/theme-color-picker.tsx * * Author: Simon-Pierre Boucher * Contact: contact@spboucher.ai * Website: https://www.spboucher.ai * Demo: https://www.vquant.ai * License: MIT (see LICENSE) * * Copyright © 2026 Simon-Pierre Boucher. All rights reserved. * ============================================================================= */ import { Palette, Check } from "lucide-react"; import { Button } from "@/components/ui/button"; import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger, } from "@/components/ui/dropdown-menu"; import { useTheme, type ThemeColor } from "./theme-provider"; const colorOptions: { value: ThemeColor; label: string; color: string }[] = [ { value: "blue", label: "Bleu", color: "hsl(210, 100%, 50%)" }, { value: "green", label: "Vert", color: "hsl(142, 76%, 45%)" }, { value: "purple", label: "Violet", color: "hsl(255, 85%, 62%)" }, { value: "red", label: "Rouge", color: "hsl(0, 84%, 60%)" }, { value: "orange", label: "Orange", color: "hsl(14, 100%, 55%)" }, { value: "cyan", label: "Cyan", color: "hsl(199, 89%, 55%)" }, ]; export function ThemeColorPicker() { const { themeColor, setThemeColor } = useTheme(); const handleColorChange = (color: ThemeColor) => { try { setThemeColor(color); } catch (error) { console.error("Failed to set theme color:", error); } }; return ( {colorOptions.map((option) => ( handleColorChange(option.value)} className="flex items-center gap-3 cursor-pointer" >
{option.label} {themeColor === option.value && ( )} ))} ); }