use vtcode_core::config::ToolOutputMode;
use vtcode_core::config::loader::VTCodeConfig;
use vtcode_core::utils::ansi::{AnsiRenderer, MessageStyle};
use super::styles::{GitStyles, LsStyles};
pub struct StreamRenderContext<'a> {
pub renderer: &'a mut AnsiRenderer,
pub mode: ToolOutputMode,
pub tail_limit: usize,
pub tool_name: Option<&'a str>,
pub git_styles: &'a GitStyles,
pub ls_styles: &'a LsStyles,
pub fallback_style: MessageStyle,
pub allow_ansi: bool,
pub disable_spool: bool,
pub config: Option<&'a VTCodeConfig>,
}
impl<'a> StreamRenderContext<'a> {
pub fn new(
renderer: &'a mut AnsiRenderer,
mode: ToolOutputMode,
tail_limit: usize,
tool_name: Option<&'a str>,
git_styles: &'a GitStyles,
ls_styles: &'a LsStyles,
fallback_style: MessageStyle,
allow_ansi: bool,
disable_spool: bool,
config: Option<&'a VTCodeConfig>,
) -> Self {
Self {
renderer,
mode,
tail_limit,
tool_name,
git_styles,
ls_styles,
fallback_style,
allow_ansi,
disable_spool,
config,
}
}
}