use vize_carton::CompactString;
#[derive(Debug, Clone)]
pub struct DisabledRange {
pub start_line: u32,
pub end_line: Option<u32>,
}
#[derive(Debug, Clone, Copy, PartialEq, Eq, Default)]
pub enum SsrMode {
Disabled,
#[default]
Enabled,
}
#[derive(Debug, Clone)]
pub struct ElementContext {
pub tag: CompactString,
pub has_v_for: bool,
pub has_v_if: bool,
pub v_for_vars: Vec<CompactString>,
}
impl ElementContext {
#[inline]
pub fn new(tag: impl Into<CompactString>) -> Self {
Self {
tag: tag.into(),
has_v_for: false,
has_v_if: false,
v_for_vars: Vec::new(),
}
}
#[inline]
pub fn with_v_for(tag: impl Into<CompactString>, vars: Vec<CompactString>) -> Self {
Self {
tag: tag.into(),
has_v_for: true,
has_v_if: false,
v_for_vars: vars,
}
}
}