-
-
Notifications
You must be signed in to change notification settings - Fork 783
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(preset-mini): support composite props #3810
Conversation
✅ Deploy Preview for unocss ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Since this PR adds a composite prop to the CSS props array in handler utils, it more or less breaks the whole prop resolving mechanism. I think the better approach is to remove the composite prop from that handler array, and guard the So an approach like this passes the test cases. Though for some odd reason the snapshot matching fails.
function transitionProperty(prop: string): string | undefined {
const cssProps = h.properties(prop)
if (cssProps !== undefined)
return cssProps
const transformed = prop.split(',').flatMap(x => transitionPropertyGroup[x]).filter(x => x !== undefined)
return transformed.length > 0 ? transformed.join(',') : undefined
} |
I'll need to revert to this after unocss/unocss#3810 gets merged
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@unocss/eslint-config](https://togithub.com/unocss/unocss/tree/main/packages/eslint-config#readme) ([source](https://togithub.com/unocss/unocss/tree/HEAD/packages/eslint-config)) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2feslint-config/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2feslint-config/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2feslint-config/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2feslint-config/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2feslint-config/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@unocss/preset-icons](https://togithub.com/unocss/unocss/tree/main/packages/preset-icons#readme) ([source](https://togithub.com/unocss/unocss/tree/HEAD/packages/preset-icons)) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2fpreset-icons/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2fpreset-icons/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2fpreset-icons/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2fpreset-icons/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2fpreset-icons/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@unocss/preset-uno](https://togithub.com/unocss/unocss/tree/main/packages/preset-uno#readme) ([source](https://togithub.com/unocss/unocss/tree/HEAD/packages/preset-uno)) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2fpreset-uno/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2fpreset-uno/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2fpreset-uno/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2fpreset-uno/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2fpreset-uno/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@unocss/preset-web-fonts](https://togithub.com/unocss/unocss/tree/main/packages/preset-web-fonts#readme) ([source](https://togithub.com/unocss/unocss/tree/HEAD/packages/preset-web-fonts)) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2fpreset-web-fonts/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2fpreset-web-fonts/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2fpreset-web-fonts/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2fpreset-web-fonts/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2fpreset-web-fonts/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@unocss/reset](https://togithub.com/unocss/unocss) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2freset/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2freset/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2freset/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2freset/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2freset/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@unocss/transformer-directives](https://togithub.com/unocss/unocss/tree/main/packages/transformer-directives#readme) ([source](https://togithub.com/unocss/unocss/tree/HEAD/packages/transformer-directives)) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2ftransformer-directives/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2ftransformer-directives/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2ftransformer-directives/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2ftransformer-directives/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2ftransformer-directives/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@unocss/transformer-variant-group](https://togithub.com/unocss/unocss/tree/main/packages/transformer-variant-group#readme) ([source](https://togithub.com/unocss/unocss/tree/HEAD/packages/transformer-variant-group)) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/@unocss%2ftransformer-variant-group/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@unocss%2ftransformer-variant-group/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@unocss%2ftransformer-variant-group/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@unocss%2ftransformer-variant-group/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@unocss%2ftransformer-variant-group/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [unocss](https://togithub.com/unocss/unocss) | [`0.60.4` -> `0.61.0`](https://renovatebot.com/diffs/npm/unocss/0.60.4/0.61.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/unocss/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/unocss/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/unocss/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/unocss/0.60.4/0.61.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>unocss/unocss (@​unocss/eslint-config)</summary> ### [`v0.61.0`](https://togithub.com/unocss/unocss/releases/tag/v0.61.0) [Compare Source](https://togithub.com/unocss/unocss/compare/v0.60.4...v0.61.0) ##### 🚀 Features - **core**: - Support generator in rule matcher - by [@​antfu](https://togithub.com/antfu) in [unocss/unocss#3884 [<samp>(7e156)</samp>](https://togithub.com/unocss/unocss/commit/7e15633b) - Introduce special symbols for applying custom variants - by [@​antfu](https://togithub.com/antfu) in [unocss/unocss#3885 [<samp>(d80f6)</samp>](https://togithub.com/unocss/unocss/commit/d80f6cad) - **preset-mini**: - Add support for peer and group variants on aria-\* variants to Preset-Mini - by [@​Johnkat-Mj](https://togithub.com/Johnkat-Mj) and [@​Simon-He95](https://togithub.com/Simon-He95) in [unocss/unocss#3692 [<samp>(c3265)</samp>](https://togithub.com/unocss/unocss/commit/c3265cc2) - **vscode**: - Add borderRadius to control color cube - by [@​Simon-He95](https://togithub.com/Simon-He95) and [@​antfu](https://togithub.com/antfu) in [unocss/unocss#3872 [<samp>(ad294)</samp>](https://togithub.com/unocss/unocss/commit/ad294ffd) ##### 🐞 Bug Fixes - **extractor-arbitrary-variants**: - Quote in \[] - by [@​Simon-He95](https://togithub.com/Simon-He95) and [@​antfu](https://togithub.com/antfu) in [unocss/unocss#3875 [<samp>(cd529)</samp>](https://togithub.com/unocss/unocss/commit/cd5296f5) - **preset-mini**: - ColorableShadows with cssvar - by [@​Simon-He95](https://togithub.com/Simon-He95) in [unocss/unocss#3878 [<samp>(1ac22)</samp>](https://togithub.com/unocss/unocss/commit/1ac223a4) - Support composite props - by [@​zyyv](https://togithub.com/zyyv) and [@​antfu](https://togithub.com/antfu) in [unocss/unocss#3810 [<samp>(f7ad5)</samp>](https://togithub.com/unocss/unocss/commit/f7ad5200) - `transform-cpu` should not include `rotate-x` and `rotate-y` - by [@​zzc6332](https://togithub.com/zzc6332) in [unocss/unocss#3813 [<samp>(ae072)</samp>](https://togithub.com/unocss/unocss/commit/ae072a54) - **transformer-attributify-jsx**: - With prefix - by [@​Simon-He95](https://togithub.com/Simon-He95) in [unocss/unocss#3867 [<samp>(83728)</samp>](https://togithub.com/unocss/unocss/commit/83728748) - **vite**: - Legacy chunks build - by [@​Simon-He95](https://togithub.com/Simon-He95) and [@​antfu](https://togithub.com/antfu) in [unocss/unocss#3879 [<samp>(c7f63)</samp>](https://togithub.com/unocss/unocss/commit/c7f63118) ##### [View changes on GitHub](https://togithub.com/unocss/unocss/compare/v0.60.4...v0.61.0) </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/ramackersjp/Piped). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zOTMuMCIsInVwZGF0ZWRJblZlciI6IjM3LjM5My4wIiwidGFyZ2V0QnJhbmNoIjoibWFzdGVyIiwibGFiZWxzIjpbXX0=-->
close #3807.