From: edison Date: Tue, 20 May 2025 13:53:11 +0000 (+0800) Subject: Merge branch 'main' into edison/fix/12241 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=47c0f03b8a889237c215978cfe8b7af264f110a7;p=thirdparty%2Fvuejs%2Fcore.git Merge branch 'main' into edison/fix/12241 --- 47c0f03b8a889237c215978cfe8b7af264f110a7 diff --cc packages/compiler-sfc/__tests__/compileStyle.spec.ts index af8c874c5f,78fd52425e..40e158f0c7 --- a/packages/compiler-sfc/__tests__/compileStyle.spec.ts +++ b/packages/compiler-sfc/__tests__/compileStyle.spec.ts @@@ -239,34 -242,11 +242,35 @@@ color: re `.div { color: red; } .div:is(.foo:hover) { color: blue; }`, ), ).toMatchInlineSnapshot(` - ".div[data-v-test] { color: red; - } - .div[data-v-test]:is(.foo:hover) { color: blue; - }"`) - + ".div[data-v-test] { color: red; + } + .div[data-v-test]:is(.foo:hover) { color: blue; + }" + `) ++ + expect(compileScoped(`#app :is(.foo) { color: red; }`)) + .toMatchInlineSnapshot(` + "#app :is(.foo[data-v-test]) { color: red; + }" + `) + + expect(compileScoped(`#app :is(:is(.foo)) { color: red; }`)) + .toMatchInlineSnapshot(` + "#app :is(:is(.foo[data-v-test])) { color: red; + }" + `) + + expect(compileScoped(`#app :where(.foo) { color: red; }`)) + .toMatchInlineSnapshot(` + "#app :where(.foo[data-v-test]) { color: red; + }" + `) + + expect(compileScoped(`#app :where(:where(.foo)) { color: red; }`)) + .toMatchInlineSnapshot(` + "#app :where(:where(.foo[data-v-test])) { color: red; + }" + `) }) test('media query', () => {