0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-16 21:46:22 -05:00

Update Compiler with new CSS Parser (#2833)

* chore: update compiler

* Update eighty-trees-thank.md

* test: update css test
This commit is contained in:
Nate Moore 2022-03-18 18:16:32 -05:00 committed by GitHub
parent 31a1b40cb8
commit 7954541291
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 14 additions and 6 deletions

View file

@ -0,0 +1,7 @@
---
'astro': minor
---
This PR introduces a new internal CSS parser for `@astrojs/compiler`. See [`withastro/compiler#329`](https://github.com/withastro/compiler/pull/329) for more details.
This fixes Astro's support for modern CSS syntax like `@container`, `@layer`, and nesting. **Note** While Astro now correctly parses this modern syntax, it does not automatically compile features for browser compatability purposes.

View file

@ -61,7 +61,7 @@
"test:match": "mocha --timeout 20000 -g"
},
"dependencies": {
"@astrojs/compiler": "^0.12.1",
"@astrojs/compiler": "^0.13.0",
"@astrojs/language-server": "^0.8.10",
"@astrojs/markdown-remark": "^0.6.4",
"@astrojs/prism": "0.4.0",

View file

@ -33,7 +33,7 @@ describe('Partial HTML', async () => {
},
})
.then((res) => res.text());
expect(css).to.match(/\.astro-[^{]+{color:red;}/);
expect(css).to.match(/\.astro-[^{]+{color:red}/);
});
it('injects framework styles', async () => {

View file

@ -354,7 +354,7 @@ importers:
packages/astro:
specifiers:
'@astrojs/compiler': ^0.12.1
'@astrojs/compiler': ^0.13.0
'@astrojs/language-server': ^0.8.10
'@astrojs/markdown-remark': ^0.6.4
'@astrojs/parser': ^0.22.2
@ -426,7 +426,7 @@ importers:
yargs-parser: ^21.0.1
zod: ^3.13.4
dependencies:
'@astrojs/compiler': 0.12.1
'@astrojs/compiler': 0.13.0
'@astrojs/language-server': 0.8.10
'@astrojs/markdown-remark': link:../markdown/remark
'@astrojs/prism': link:../astro-prism
@ -1554,8 +1554,8 @@ packages:
leven: 3.1.0
dev: true
/@astrojs/compiler/0.12.1:
resolution: {integrity: sha512-XpKZyJlnDhszulwwse/1uV+ZiyTpg6xNH5TrriYDVdzB8dUbQLdE7tX4Cxhdw5QrJpV57AaPrPXvJKi1jnIkxw==}
/@astrojs/compiler/0.13.0:
resolution: {integrity: sha512-omPv8V2OG05Nx7cV1PiYKV2GewsVf91kZDRUajPsjAHVEorIDMNV8ekv1gjjgAt8UVKbQYev2hzGhmdyHdo06Q==}
dependencies:
tsm: 2.2.1
uvu: 0.5.3
@ -9126,6 +9126,7 @@ packages:
/source-map/0.6.1:
resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==}
engines: {node: '>=0.10.0'}
requiresBuild: true
/source-map/0.7.3:
resolution: {integrity: sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==}