parcel-bundler / parcel-bundler/lightningcss
Can media queries use custom units?
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 7.7k
- Forks
- 302
- PR merge metrics
- No merged PRs in 30d
Description
Use px units for media queries, convert to rem
@media screen and (max-width: 1000px) {
.test {
width: 100px;
}
}
But I use custom units and expect no px conversion, which will cause the media query style to be lost
@media screen and (max-width: 1000customPx) {
.test {
width: 100px;
}
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how lightningcss converts px units in media-query conditions, then look for tests covering @media unit handling. Use the examples in the issue to verify that ordinary px values retain their current conversion while custom units remain unchanged. Done means the custom-unit media query is not lost during transformation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css, rust
- Domain
- compilers, web-dev
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100