@csstools/postcss-is-pseudo-class
Advanced tools
Comparing version
# Changes to PostCSS Is Pseudo Class | ||
### 5.0.1 | ||
### 5.0.2 | ||
_October 23, 2024_ | ||
_June 10, 2025_ | ||
- Make sorting compound selectors forwards compatible with potential future changes in `postcss-selector-parser` | ||
- Updated: `postcss-selector-parser` | ||
- Updated [`@csstools/selector-specificity`](https://github.com/csstools/postcss-plugins/tree/main/packages/selector-specificity) to [`5.0.0`](https://github.com/csstools/postcss-plugins/tree/main/packages/selector-specificity/CHANGELOG.md#500) (major) | ||
- Add support for more complex selector patterns. `.a > :is(.b > .c)` -> `.a.b > .c` | ||
[Full CHANGELOG](https://github.com/csstools/postcss-plugins/tree/main/plugins/postcss-is-pseudo-class/CHANGELOG.md) |
{ | ||
"name": "@csstools/postcss-is-pseudo-class", | ||
"description": "A pseudo-class for matching elements in a selector list", | ||
"version": "5.0.1", | ||
"version": "5.0.2", | ||
"author": "Jonathan Neal <jonathantneal@hotmail.com>", | ||
@@ -6,0 +6,0 @@ "license": "MIT-0", |
# PostCSS Is Pseudo [<img src="https://postcss.github.io/postcss/logo.svg" alt="PostCSS" width="90" height="90" align="right">][postcss] | ||
[![NPM Version][npm-img]][npm-url] | ||
[<img alt="Build Status" src="https://github.com/csstools/postcss-plugins/workflows/test/badge.svg" height="20">][cli-url] | ||
[<img alt="Build Status" src="https://github.com/csstools/postcss-plugins/actions/workflows/test.yml/badge.svg?branch=main" height="20">][cli-url] | ||
[<img alt="Discord" src="https://shields.io/badge/Discord-5865F2?logo=discord&logoColor=white">][discord] | ||
@@ -13,3 +13,3 @@ <br><br> | ||
```pcss | ||
```css | ||
:is(input, button):is(:hover, :focus) { | ||
@@ -22,3 +22,3 @@ order: 1; | ||
```pcss | ||
```css | ||
input:hover { | ||
@@ -75,3 +75,3 @@ order: 1; | ||
```pcss | ||
```css | ||
:is(input, button):is(:hover, :focus) { | ||
@@ -84,3 +84,3 @@ order: 1; | ||
```pcss | ||
```css | ||
input:hover { | ||
@@ -117,3 +117,3 @@ order: 1; | ||
```pcss | ||
```css | ||
:is(.button, button):hover { | ||
@@ -126,3 +126,3 @@ order: 7; | ||
```pcss | ||
```css | ||
.button:hover { | ||
@@ -185,3 +185,3 @@ order: 7; | ||
```pcss | ||
```css | ||
:is(:hover, :focus):is(.button, button) { | ||
@@ -194,3 +194,3 @@ order: 7; | ||
```pcss | ||
```css | ||
/* specificity: [0, 2, 0] */ | ||
@@ -224,3 +224,3 @@ .button:hover { | ||
```pcss | ||
```css | ||
:is(.alpha > .beta) ~ :is(:focus > .beta) { | ||
@@ -233,3 +233,3 @@ order: 2; | ||
```pcss | ||
```css | ||
.alpha > .beta ~ :focus > .beta { | ||
@@ -244,3 +244,3 @@ order: 2; | ||
```pcss | ||
```css | ||
/* without is */ | ||
@@ -247,0 +247,0 @@ .alpha:focus > .beta ~ .beta { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
29269
6.92%104
8.33%