/** * Just enough lexing for `check-font-weights.mjs`: comments, the string that * encloses each position, and where a declaration's value ends. */ const QUOTES = new Set(["'", '"', '`']); const VALUE_END = new Set([';', '{', '}', ']']); /** * Plain CSS has block comments only; SCSS and TypeScript add `//`. In SCSS * a `//` is a comment anywhere outside a string (`font-weight:// old`, `(// * note`) except in an unquoted `url(//cdn…)` or `url(https://…)`. In * TypeScript a URL is always inside a string, so every `//` there is a * comment. */ function syntaxOf(file) { // SVG is markup like HTML: attributes, `` comments, `