@@ -2068,10 +2068,8 @@ describe("CssSyntax — minify transforms, in-process", () => {
20682068 expect ( min ( '@charset "iso-8859-1";a{b:c}' ) ) . toBe ( "a{b:c}" ) ;
20692069 } ) ;
20702070
2071- // The bytes an engine reads a charset rule as are the literal `@charset "`
2072- // (CSS Syntax 3 §3.2), so lowercasing one would turn a rule the engine
2073- // drops into one that sets the sheet's encoding. A `@charset` carrying a
2074- // block is no charset rule to take out, so the case still has to hold.
2071+ // An engine reads only the literal `@charset "` (CSS Syntax 3 §3.2), so a
2072+ // cased rule — which a block makes no charset rule anyway — keeps its bytes.
20752073 it ( "leaves a cased `@charset` carrying a block alone" , ( ) => {
20762074 expect ( min ( '@CHARSET "utf-8"{}a{b:c}' ) ) . toBe ( '@CHARSET "utf-8"{}a{b:c}' ) ;
20772075 } ) ;
@@ -8011,9 +8009,8 @@ describe("CssSyntax minify — color-mix()", () => {
80118009 } ) ;
80128010
80138011 it ( "reads a hue the way the method it was given names" , ( ) => {
8014- // Each method takes the second hue its own way round the circle. Two pairs,
8015- // since one only ever tells the two arcs apart: which of them is the
8016- // shorter is also which of them increases.
8012+ // Each method takes the second hue its own way round the circle; two pairs,
8013+ // since the shorter arc is also the increasing one.
80178014 /**
80188015 * @param {string } method the hue interpolation method
80198016 * @param {string } first the first color
@@ -8303,9 +8300,8 @@ describe("CssSyntax minify — pseudo-class replacement", () => {
83038300} ) ;
83048301
83058302describe ( "CssSyntax minify — the version each rewrite turns on at" , ( ) => {
8306- // One selection either side of the version the compat data gives, so a
8307- // rewrite that starts or stops one release early is a failure rather than a
8308- // detail. Chrome alone: the browser every entry here has a version for.
8303+ // One selection either side of the compat data's version, so an off-by-one
8304+ // release fails. Chrome alone: every entry here has a version for it.
83098305 it . each ( [
83108306 [ "a hex alpha" , "a{color:#7bffff80}" , 62 ] ,
83118307 [
@@ -8452,9 +8448,8 @@ describe("CssSyntax minify — light-dark()", () => {
84528448 } ) ;
84538449
84548450 it ( "writes no fallback pair before a value a substitution reaches" , ( ) => {
8455- // An unreadable color inside a `var()` fallback is invalid at
8456- // computed-value time, which is `unset` rather than the earlier
8457- // declaration — so a pair standing before one is bytes nothing reads.
8451+ // Invalid at computed-value time is `unset`, not the earlier declaration, so
8452+ // a fallback pair before a `var()` is bytes nothing reads.
84588453 expect ( minifyFor ( "a{color:var(--x,oklch(.7 .1 20))}" , [ "chrome 100" ] ) ) . toBe (
84598454 "a{color:var(--x,oklch(.7 .1 20))}"
84608455 ) ;
0 commit comments