// Global alerts runner. Subscribes to any symbols with per-symbol overrides
// so alerts fire on every page, and evaluates the current ticker map against
// the configured rules. Render as `<AlertsRunner />` inside the app layout —
// it renders nothing.

import { useDeltaTickers } from "@/hooks/use-delta-tickers";
import { useAlertsEngine, useAlertWatchSymbols } from "@/lib/alert-rules";

export function AlertsRunner() {
  const symbols = useAlertWatchSymbols();
  const { tickers } = useDeltaTickers(symbols);
  useAlertsEngine(tickers);
  return null;
}
