Expand description
CSS var(--name [, fallback]) resolver shared by the cascade in crate::css and the runtime’s IR loader.
Structs§
- Lenient
Resolution - Outcome of
resolve_lenient: the substituted text plus a human-readable message for everyvar()call that could not resolve, in the order encountered.warningsis empty when every call resolved.
Functions§
- resolve
- Recursively replaces every
var(--name)andvar(--name, fallback)substring insrcwith the matching entry fromvars. - resolve_
lenient - Same substitution as
resolve, but never fails: an unresolvablevar()call (unknown name with no fallback, unterminated call, or a recursion/cycle depth over 16) degrades to an empty string and records a message inLenientResolution::warnings, instead of aborting the rest ofsrc.