"use client"; import { EVENT_TYPE_STYLES } from "@/components/calendario/day-cell"; import type { CalendarEvent } from "@/components/calendario/types"; import { cn } from "@/lib/utils/ui"; const LEGEND_ITEMS: Array<{ type?: CalendarEvent["type"]; label: string; dotColor?: string; }> = [ { type: "lancamento", label: "Lançamentos" }, { type: "boleto", label: "Boleto com vencimento" }, { type: "cartao", label: "Vencimento de cartão" }, { label: "Pagamento fatura", dotColor: "bg-success" }, ]; export function CalendarLegend() { return (
{LEGEND_ITEMS.map((item, index) => { const dotColor = item.dotColor || (item.type ? EVENT_TYPE_STYLES[item.type].dot : ""); return ( {item.label} ); })}
); }