pub(crate) fn compute_styles_with_vars<'a>(
root: &'a Node,
stylesheet: &StyleSheet,
rule_index: Option<&RuleIndex>,
ancestors: &[AncestorContext<'a>],
sibling_index: Option<usize>,
sibling_count: Option<usize>,
active_pseudo_states: &[&str],
parent_vars: &Rc<BTreeMap<String, String>>,
counters_in: &BTreeMap<String, i64>,
) -> (BTreeMap<String, String>, Rc<BTreeMap<String, String>>, BTreeMap<String, i64>, BTreeSet<String>)Expand description
root にスタイルを適用する。counters_in は直前までの文書順カウンタ状態
(counter-reset/counter-incrementは全カウンタをフラットに共有する簡略化実装で、
実 CSS 仕様のようなネストごとのスコープ分離は行わない)。戻り値の第3要素は
この要素自身の counter-reset/counter-increment 適用後のカウンタ状態。