public final class CSSValueText extends Object
PropertyValue
terms), preserving the comma/slash/space operators between terms and recursing
into function arguments and value lists.
Unlike FSFunction.toString() it keeps comma- vs space-separated
arguments distinct, which matters when the text is re-parsed (custom property
values and var() fallbacks): var(--x, 1px solid red) must not
collapse to var(--x,1px,solid,red).
This generalizes the value joining in InvalidPropertyDeclaration.toCSS,
which is comma/space-only and non-recursive (so it can't faithfully serialize
inside functions).
| Modifier and Type | Method and Description |
|---|---|
static boolean |
containsVarFunction(List<PropertyValue> values)
Returns true if any term in the value (recursively, including function
arguments and nested lists) is a
var() function. |
static String |
toCSS(List<PropertyValue> values)
Serializes a list of value terms back to CSS text suitable for re-parsing.
|
public static String toCSS(List<PropertyValue> values)
public static boolean containsVarFunction(List<PropertyValue> values)
var() function.Copyright © 2004–2026. All rights reserved.