Expand description
Shared low-level parsing helpers — not glob-re-exported because its items are meant to be used via qualified paths. CSS string parsing utilities.
Parenthesized expressions, quote stripping, comma/whitespace-aware splitting that respects nesting depth, and CSS image/url path parsing.
Structs§
- Quote
Stripped - A string that has been stripped of the beginning and ending quote
- Unclosed
Quotes Error - String has unbalanced
'or"quotation marks
Enums§
- CssImage
Parse Error - CssImage
Parse Error Owned - Owned version of
CssImageParseError. - Parenthesis
Parse Error - Parenthesis
Parse Error Owned - Owned version of
ParenthesisParseError.
Functions§
- parse_
image - A string slice that has been stripped of its quotes.
In CSS, quotes are optional in
url()so we accept both quoted and unquoted strings. - parse_
parentheses - Checks whether a given input is enclosed in parentheses, prefixed by a certain number of stopwords.
- split_
string_ respect_ comma - Splits a string by commas, but respects parentheses/braces
- split_
string_ respect_ whitespace - Splits a string by whitespace, but respects parentheses/braces
- strip_
quotes - Strip quotes from an input, given that both quotes use either
"or', but not both.