pub fn classes_in_css(css: &str) -> BTreeSet<String>Expand description
The class names a stylesheet’s selectors match.
Public because the check this exists for reads an app’s stylesheet too, and comparing what makeover defines against what the app defines is only meaningful if both sides were read the same way.
Selector text only. A declaration value can hold a dot (0.5rem,
transition: .2s) and none of those are classes, so the scan tracks whether
it is inside a declaration block and ignores what it finds there. An at-rule
block (@layer, @media, @supports) contains rules rather than
declarations, which is why a depth counter alone is not enough: the stack
records what kind of block each brace opened.