Donny/강동윤
85be8a4de1
refactor(css/parser): Remove value normalization ( #8434 )
...
**Related issue :**
- https://linear.app/vercel/issue/PACK-2154
2024-01-03 20:40:51 +00:00
Donny/강동윤
d89b60a000
fix(css/parser): Fix parsing of hsla(var(--foo), 1)
( #8443 )
...
**Description:**
```css
.test {
border-color: hsla(var(--ds-gray-200-value), 1);
}
```
should be compiled as
```css
.test {
border-color: hsla(var(--ds-gray-200-value), 1);
}
```
Previously, it was
```
.test {
border-color: hsla(var(--ds-gray-200-value),);
}
```
**Related issue:**
- https://linear.app/vercel/issue/PACK-2175
2023-12-23 12:39:54 +09:00
Donny/강동윤
d1097ccb59
feat(css/parser): Store lexed comments ( #8091 )
...
**Description:**
For now, we leave every comment as a leading comment. As logic for determining leading vs trailing is quite complex, I'll do it with another PR.
2023-10-10 11:42:20 +00:00
Donny/강동윤
84cec8766d
refactor(atoms): Remove usage of js_word!
to drop string-cache
( #7976 )
...
**Description:**
This PR is to prepare removal of `string-cache`. Actually, this PR does not remove it. Instead, this PR only removes direct usages of `js_word!`s, especially in patterns.
**Related issue:**
- #4946 .
2023-10-08 00:39:51 +00:00
Jason
a34f3592b3
feat(css/ast): Support @scope
at-rule ( #7837 )
...
> ### Describe the feature
> [Chrome 118 is shipping
soon](https://chromium-review.googlesource.com/c/chromium/src/+/4790561 ),
which is expected to be one of the more popular CSS features, giving new
hope for style isolation of components.
>
> * Explainer https://css.oddbird.net/scope/explainer
> * Specification https://drafts.csswg.org/css-cascade-6/#scope-atrule
>
Closed : #7836
2023-08-24 08:18:35 +00:00
Jason
cfb7b511ee
feat(css/parser): Support @starting-style
( #7677 )
2023-07-20 14:55:50 +09:00
OJ Kwon
56bdacc72d
feat(plugin/runner): Update wasmer
to v3
( #7197 )
...
**Description:**
This PR reattempts https://github.com/swc-project/swc/pull/5456 .
Most of the changes are for the breaking changes of wasmer@3, as well as enabling rkyv's strict mode (https://github.com/swc-project/swc/pull/6922 ). This could not be seperated since wasmer@3 enables strict mode by default without a way to turn it off.
There are a couple of changes worth noting:
- Disabling in-memory module lookup: https://github.com/swc-project/swc/pull/7197/files#diff-3bda5def6ce2b7553c3b3a5ad241c0bdb7021e67b7de1e594df4cd5a54d403b3R154-R159
- Disabling plugin_runner in bindings_wasm: https://github.com/swc-project/swc/pull/7197/files#diff-dc3ded556a1fd709a129acd588e5eda651b842c6acc3f5340d40088a1f927facR310-R312
- Skipping plugin compat test: https://github.com/swc-project/swc/pull/7197/files#diff-531197dfcefba05faca53f0cf442ecc2dc6b59d5ead01979f5ffb912aa36249aR64-R66
2023-04-10 03:40:25 +00:00
Donny/강동윤
5e58b3e5f6
feat(css/parser): Add legacy_ie
to the ParserConfig
( #7109 )
2023-03-27 15:02:18 +09:00
Donny/강동윤
963c460613
refactor: Fix lints using clippy from nightly-2023-03-13
( #6920 )
2023-03-14 04:56:21 +00:00
Alexander Akait
43e75194e5
feat(css/parser): Normalize at-rules ( #6705 )
2023-01-14 08:58:24 +00:00
Alexander Akait
8af627d5c4
feat(css/parser): Normalize urange ( #6704 )
2022-12-27 12:22:46 +00:00
Alexander Akait
ebebd60875
refactor(css/codegen): Do not use raw
( #6674 )
2022-12-22 01:36:36 +00:00
Alexander Akait
2571070148
feat(css/parser): Normalize and improve function name ( #6667 )
2022-12-20 12:43:58 +00:00
Alexander Akait
d27a270fec
perf(css/prefixer): Use JsWord
instead of &str
( #6658 )
2022-12-20 06:09:02 +00:00
Alexander Akait
d7a0524fb6
feat(css/parser): Normalize keyframe selectors ( #6688 )
2022-12-20 04:35:14 +00:00
Alexander Akait
7f8ba9c22c
feat(css/parser): Normalize at-rule names ( #6676 )
2022-12-19 08:30:06 +00:00
Alexander Akait
c01464e452
feat(css/parser): Normalize URL functions ( #6675 )
2022-12-19 07:53:29 +00:00
Alexander Akait
3d3863dc1f
feat(css/parser): Normalize dimension ( #6654 )
2022-12-16 04:04:07 +00:00
Alexander Akait
1fc97a7cea
feat(css/parser): Normalize declaration and important ( #6663 )
2022-12-16 02:34:18 +00:00
Alexander Akait
87e1efd98c
test(css/parser): Add a test ( #6666 )
2022-12-16 08:55:05 +09:00
Alexander Akait
649438b76a
feat(css/parser): Normalize selector AST ( #6657 )
2022-12-15 06:55:22 +00:00
Alexander Akait
b257d5d591
feat(css/parser): Normalize hex colors ( #6652 )
2022-12-15 04:34:07 +00:00
Alexander Akait
7d3aa66bb8
perf(html/minifier): Reduce allocations ( #6623 )
2022-12-13 12:34:55 +09:00
Alexander Akait
cb49fa6f1d
feat(css/minifier): Support to
and from
with initial
( #6613 )
2022-12-12 02:36:48 +00:00
Donny/강동윤
b4eef53680
feat(css/ast): Make AST intuitive ( #6606 )
2022-12-09 02:27:19 +00:00
Alexander Akait
252edb550b
perf(css/parser): Reduce number of function calls ( #6587 )
2022-12-07 01:45:03 +00:00
Alexander Akait
8633d27df0
perf(css/ast): Reduce token size ( #6569 )
2022-12-06 01:58:29 +00:00
Alexander Akait
4d422b6228
test(css/parser): Move vendor tests ( #6564 )
2022-12-02 04:27:09 +00:00
Alexander Akait
a1fe9076c2
fix(css/parser): Fix parsing of nested rules ( #6563 )
2022-12-02 03:52:54 +00:00
Alexander Akait
db1eb483fd
fix(css/parser): Fix recovery more for invalid component values in declaration value ( #6560 )
2022-12-01 06:26:47 +00:00
Donny/강동윤
7ee86d1d25
test: Use correct extensions for fixture tests ( #6539 )
2022-11-29 09:47:56 +00:00
Donny/강동윤
b8fe04f720
feat(common): Add contexts to the error messages ( #6526 )
...
**Description:**
This PR makes the error reporter print contexts.
**Related issue:**
- https://github.com/swc-project/swc/issues/6525 .
2022-11-29 00:56:47 +09:00
Alexander Akait
3d7545d89b
fix(css/parser): Fix a bug with scope in block ( #6402 )
2022-11-15 01:49:05 +00:00
Alexander Akait
983ab91435
refactor(css/parser): Refactor parser ( #6395 )
2022-11-11 07:27:19 +00:00
Alexander Akait
ec2c021255
perf(css/ast): Use Atom
for raw
values ( #6401 )
2022-11-11 01:24:11 +00:00
Alexander Akait
d18eaf1698
fix(css/parser): Fix parsing of <general-enclosed>
( #6380 )
2022-11-10 12:37:14 +09:00
Alexander Akait
434a7657ed
refactor(css/parser): Union input types ( #6385 )
2022-11-10 02:10:23 +00:00
Alexander Akait
bea6cce0c6
perf(css): Reduce size of tokens ( #6384 )
2022-11-10 01:36:53 +00:00
Alexander Akait
f4832247bc
fix(css/parser): Fix parsing of supports()
( #6333 )
2022-11-08 01:32:48 +00:00
Alexander Akait
e0967efa6e
feat(css/parser): Support new nesting spec ( #6337 )
2022-11-03 15:08:23 +00:00
Alexander Akait
0bc682f529
feat(css/parser): Improve error recovery ( #6336 )
2022-11-03 06:30:09 +00:00
Alexander Akait
6cafeb2bcc
refactor(css/parser): Refactor even more ( #6288 )
2022-10-29 08:28:39 +00:00
Alexander Akait
2813acccc2
fix(css/parser): Fix various issues ( #6281 )
2022-10-28 04:34:23 +00:00
Alexander Akait
956d574683
feat(css/parser): Improve error reporting ( #6274 )
2022-10-28 03:14:08 +00:00
Alexander Akait
c3944ba239
fix(css/parser): Fix parsing of colors ( #6260 )
2022-10-27 01:55:06 +00:00
Alexander Akait
4c293f965b
test(css/parser): Add tests for refactoring ( #6262 )
2022-10-26 22:58:59 +00:00
Alexander Akait
a0e4684476
refactor(css/parser): Refactor more ( #6251 )
2022-10-26 19:22:27 +09:00
Donny/강동윤
6341554628
fix(css/parser): Add more error recovery ( #6240 )
2022-10-24 03:11:27 +00:00
Alexander Akait
e4fe8403d7
refactor(css/parser): Fix parsing of declarations ( #6234 )
2022-10-22 22:50:19 +00:00
Alexander Akait
ac619e88bf
refactor(css/parser): Use new approach for parsing invalid tokens ( #6224 )
...
Co-authored-by: Donny/강동윤 <kdy1997.dev@gmail.com>
2022-10-22 04:21:40 +00:00