import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
/**
 * EventPlanViewer — Renders a list of planned analytics events.
 *
 * Each event shows as: ● event name — description
 */
import { Box, Text } from 'ink';
import { Colors, Icons } from '../styles.js';
export const EventPlanViewer = ({ events }) => {
    const visible = events.filter((e) => e.name.trim().length > 0);
    if (visible.length === 0) {
        return (_jsxs(Box, { flexDirection: "column", paddingX: 1, children: [_jsx(Text, { bold: true, children: "Event plan" }), _jsx(Box, { height: 1 }), _jsx(Text, { color: Colors.muted, children: "Waiting for the agent to propose events..." })] }));
    }
    return (_jsxs(Box, { flexDirection: "column", paddingX: 1, children: [_jsx(Text, { bold: true, children: "Event plan" }), _jsx(Box, { height: 1 }), visible.map((event) => (_jsxs(Text, { color: Colors.muted, children: [Icons.bullet, ' ', _jsx(Text, { color: Colors.accent, bold: true, children: event.name }), event.description ? ` — ${event.description}` : ''] }, event.name)))] }));
};
