Skip to content

Commit c349ccf

Browse files
Bump the development-dependencies group with 8 updates (#1783)
Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Romain Menke <[email protected]> Co-authored-by: Romain Menke <[email protected]>
1 parent ff9fa50 commit c349ccf

165 files changed

Lines changed: 564 additions & 671 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/bin/list-workspaces/list-workspaces.mjs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,8 @@ export async function listWorkspaces() {
7676
} catch (err) {
7777
// eslint-disable-next-line no-console
7878
console.error(err);
79-
throw new Error('failed to get the list of workspaces');
79+
throw new Error('failed to get the list of workspaces', {
80+
cause: err,
81+
});
8082
}
8183
}

.github/bin/release-plan/prepare-current-release-plan.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export async function prepareCurrentReleasePlan() {
4141
let changelog = (await fs.readFile(path.join(workspace.path, 'CHANGELOG.md'))).toString();
4242
if (changelog.includes('Unreleased')) {
4343

44-
let increment = '';
44+
let increment;
4545
if (changelog.includes('Unreleased (patch)')) {
4646
increment = 'patch';
4747
} else if (changelog.includes('Unreleased (minor)')) {

cli/csstools-cli/dist/cli.cjs

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

eslint.config.mjs

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import js from '@eslint/js';
22
import globals from 'globals';
33
import tseslint from 'typescript-eslint';
4+
import stylistic from '@stylistic/eslint-plugin';
45

56
export default [
67
js.configs.recommended,
@@ -38,6 +39,10 @@ export default [
3839
sourceType: 'module',
3940
},
4041

42+
plugins: {
43+
'@stylistic': stylistic,
44+
},
45+
4146
rules: {
4247
'no-console': ['error'],
4348
quotes: ['error', 'single'],
@@ -58,6 +63,10 @@ export default [
5863
}],
5964

6065
'no-duplicate-imports': 'error',
66+
67+
'eqeqeq': 'error',
68+
'no-useless-return': 'error',
69+
'@stylistic/semi': ['error', 'always'],
6170
},
6271
},
6372
{
@@ -75,10 +84,17 @@ export default [
7584
sourceType: 'module',
7685
},
7786

87+
plugins: {
88+
'@stylistic': stylistic,
89+
},
90+
7891
rules: {
7992
'no-console': ['error'],
8093
'no-unused-vars': ['error', { 'caughtErrorsIgnorePattern': '_' }],
8194
'no-constant-condition': 'off',
95+
'eqeqeq': 'error',
96+
'no-useless-return': 'error',
97+
'@stylistic/semi': ['error', 'always'],
8298
},
8399
},
84100
{
@@ -94,9 +110,17 @@ export default [
94110
tsconfigRootDir: import.meta.dirname,
95111
},
96112
},
113+
114+
plugins: {
115+
'@stylistic': stylistic,
116+
},
117+
97118
rules: {
98119
'no-console': ['error'],
99120
'no-shadow': 'off',
121+
'eqeqeq': 'error',
122+
'no-useless-return': 'error',
123+
'@stylistic/semi': ['error', 'always'],
100124
'@typescript-eslint/no-shadow': 'error',
101125

102126
'@typescript-eslint/array-type': ['error', {

experimental/postcss-gradient-stop-increments/CHANGELOG.md

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22

33
### Unreleased (patch)
44

5-
- Updated [`@csstools/css-calc`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc) to [`3.0.1`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc/CHANGELOG.md#301) (patch)
6-
- Updated [`@csstools/css-calc`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc) to [`3.1.0`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc/CHANGELOG.md#310) (minor)
7-
- Updated [`@csstools/css-calc`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc) to [`3.1.1`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc/CHANGELOG.md#311) (patch)
5+
- Updated [`@csstools/css-calc`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc) to [`3.1.1`](https://github.com/csstools/postcss-plugins/tree/main/packages/css-calc/CHANGELOG.md#311) (minor)
86

97
### 3.0.0
108

experimental/postcss-gradient-stop-increments/src/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,6 @@ const creator: PluginCreator<pluginOptions> = (opts?: pluginOptions) => {
9191
continue;
9292
}
9393
}
94-
95-
return;
9694
},
9795
));
9896

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
import e from"postcss-selector-parser";function ampersandToScope(t,n){let r,o=t.parent;for(;o;){if("rule"===o.type)return;o=o.parent}try{r=e().astSync(t.selector)}catch(e){if(!(e instanceof Error))throw e;return void t.warn(n,`Failed to parse selector : "${t.selector}" with message: "${e.message}"`)}r&&(r.walkNesting(t=>{"root"===t.parent?.parent?.type?t.replaceWith(e.pseudo({value:":scope"})):t.replaceWith(e.pseudo({value:":is",nodes:[e.pseudo({value:":root"}),e.pseudo({value:":host"})]}))}),t.selector=r.toString())}function cleanupParent(e){if(!e.nodes.length)return void e.remove();const t=e.nodes.filter(e=>"comment"===e.type);t.length===e.nodes.length&&e.replaceWith(...t)}function shiftNodesBeforeParent(e,t){const n=t.index(e);if(n){const e=t.cloneBefore().removeAll().append(t.nodes.slice(0,n));e.raws.semicolon=!0,cleanupParent(e)}t.before(e),t.raws.semicolon=!0}function mergeSelectors(t,n,r,o){const s=[];if(0===o.length)return;const i=e().astSync(`:is(${r.join(",")})`);for(let r=0;r<o.length;r++){const l=e().astSync(o[r]);if(!l)continue;let a=!1;if(l.walk(e=>{"nesting"===e.type&&(a=!0)}),!a){const s=l.nodes[0];let i=!1;if(s.each(e=>"combinator"===e.type&&(i=!0,!1)),0===r){let e=!1;s.each(t=>"tag"===t.type&&(e=!0,!1)),e&&t.warn(n,`Invalid nested rule : "${o[r]}"`)}i||s.insertBefore(s.at(0),e.combinator({value:" "})),s.insertBefore(s.at(0),e.nesting())}l.walk(e=>{"nesting"===e.type&&e.replaceWith(i.clone({}))}),s.push(l.toString())}return s}function groupDeclarations(e){let t=-1;e.each((n,r)=>{if("decl"===n.type){if(-1===t)return void(t=r);if(t===r-1)return void(t=r);n.remove(),e.insertAfter(t,n),t=e.index(n)}})}function transformRuleWithinRule(e,t,n){let r=[];try{r=mergeSelectors(e,n,t.selectors,e.selectors)}catch(r){if(!(r instanceof Error))throw r;return void e.warn(n,`Failed to transform selectors : "${t.selector}" / "${e.selector}" with message: "${r.message}"`)}groupDeclarations(t),shiftNodesBeforeParent(e,t),e.selectors=r;"rule"===e.type&&"rule"===t.type&&e.selector===t.selector&&e.append(...t.nodes),cleanupParent(t)}var t=["container","document","media","supports","layer"];function atruleWithinRule(e,t,n,r){if(groupDeclarations(t),shiftNodesBeforeParent(e,t),e.nodes){const o=t.clone().removeAll().append(e.nodes);e.append(o),cleanupParent(t),r(o,n)}}function isAtruleWithinRule(e){return t.includes(e.name)}function comma(e){const t=[];let n="",r=!1,o=0,s=!1,i=!1;for(const l of e)i?i=!1:"\\"===l?i=!0:s?l===s&&(s=!1):'"'===l||"'"===l?s=l:"("===l?o+=1:")"===l?o>0&&(o-=1):0===o&&","===l&&(r=!0),r?(""!==n&&t.push(n.trim()),n="",r=!1):n+=l;return t.push(n.trim()),t}function transformAtruleWithinAtrule(e,t){var n,r;groupDeclarations(t),shiftNodesBeforeParent(e,t),e.params=(n=t.params,r=e.params,comma(n).map(e=>comma(r).map(t=>`${e} and ${t}`).join(", ")).join(", ")),cleanupParent(t)}function isAtruleWithinAtrule(e,n){return t.includes(e.name)&&e.name===n.name}function isAtRule(e){return e&&"atrule"===e.type}function isRule(e){return e&&"rule"===e.type}function walk(e,t){e.each(e=>{const n=e.parent;isRule(e)&&e.selector.trim()&&isRule(n)&&n.selector.trim()?transformRuleWithinRule(e,n,t):isAtRule(e)&&isRule(n)&&n.selector.trim()&&isAtruleWithinRule(e)?atruleWithinRule(e,n,t,walk):isAtRule(e)&&isAtRule(n)&&isAtruleWithinAtrule(e,n)&&transformAtruleWithinAtrule(e,n),"nodes"in e&&e.nodes.length&&walk(e,t)})}const creator=()=>({postcssPlugin:"postcss-nesting",Rule(e,{result:t}){walk(e,t),e.selector.trim().includes("&")&&ampersandToScope(e,t)}});creator.postcss=!0;export{creator as default,creator as"module.exports"};
1+
import e from"postcss-selector-parser";function ampersandToScope(t,n){let r,o=t.parent;for(;o;){if("rule"===o.type)return;o=o.parent}try{r=e().astSync(t.selector)}catch(e){if(!(e instanceof Error))throw e;return void t.warn(n,`Failed to parse selector : "${t.selector}" with message: "${e.message}"`)}r&&(r.walkNesting(t=>{"root"===t.parent?.parent?.type?t.replaceWith(e.pseudo({value:":scope"})):t.replaceWith(e.pseudo({value:":is",nodes:[e.pseudo({value:":root"}),e.pseudo({value:":host"})]}))}),t.selector=r.toString())}function cleanupParent(e){if(!e.nodes.length)return void e.remove();const t=e.nodes.filter(e=>"comment"===e.type);t.length===e.nodes.length&&e.replaceWith(...t)}function shiftNodesBeforeParent(e,t){const n=t.index(e);if(n){const e=t.cloneBefore().removeAll().append(t.nodes.slice(0,n));e.raws.semicolon=!0,cleanupParent(e)}t.before(e),t.raws.semicolon=!0}function mergeSelectors(t,n,r,o){const s=[];if(0===o.length)return;const i=e().astSync(`:is(${r.join(",")})`);for(let r=0;r<o.length;r++){const l=e().astSync(o[r]);if(!l)continue;let a=!1;if(l.walk(e=>{"nesting"===e.type&&(a=!0)}),!a){const s=l.nodes[0];let i=!1;if(s.each(e=>"combinator"===e.type&&(i=!0,!1)),0===r){let e=!1;s.each(t=>"tag"===t.type&&(e=!0,!1)),e&&t.warn(n,`Invalid nested rule : "${o[r]}"`)}i||s.insertBefore(s.at(0),e.combinator({value:" "})),s.insertBefore(s.at(0),e.nesting())}l.walk(e=>{"nesting"===e.type&&e.replaceWith(i.clone({}))}),s.push(l.toString())}return s}function groupDeclarations(e){let t=-1;e.each((n,r)=>{if("decl"===n.type){if(-1===t)return void(t=r);if(t===r-1)return void(t=r);n.remove(),e.insertAfter(t,n),t=e.index(n)}})}function transformRuleWithinRule(e,t,n){let r;try{r=mergeSelectors(e,n,t.selectors,e.selectors)}catch(r){if(!(r instanceof Error))throw r;return void e.warn(n,`Failed to transform selectors : "${t.selector}" / "${e.selector}" with message: "${r.message}"`)}groupDeclarations(t),shiftNodesBeforeParent(e,t),e.selectors=r;"rule"===e.type&&"rule"===t.type&&e.selector===t.selector&&e.append(...t.nodes),cleanupParent(t)}var t=["container","document","media","supports","layer"];function atruleWithinRule(e,t,n,r){if(groupDeclarations(t),shiftNodesBeforeParent(e,t),e.nodes){const o=t.clone().removeAll().append(e.nodes);e.append(o),cleanupParent(t),r(o,n)}}function isAtruleWithinRule(e){return t.includes(e.name)}function comma(e){const t=[];let n="",r=!1,o=0,s=!1,i=!1;for(const l of e)i?i=!1:"\\"===l?i=!0:s?l===s&&(s=!1):'"'===l||"'"===l?s=l:"("===l?o+=1:")"===l?o>0&&(o-=1):0===o&&","===l&&(r=!0),r?(""!==n&&t.push(n.trim()),n="",r=!1):n+=l;return t.push(n.trim()),t}function transformAtruleWithinAtrule(e,t){var n,r;groupDeclarations(t),shiftNodesBeforeParent(e,t),e.params=(n=t.params,r=e.params,comma(n).map(e=>comma(r).map(t=>`${e} and ${t}`).join(", ")).join(", ")),cleanupParent(t)}function isAtruleWithinAtrule(e,n){return t.includes(e.name)&&e.name===n.name}function isAtRule(e){return e&&"atrule"===e.type}function isRule(e){return e&&"rule"===e.type}function walk(e,t){e.each(e=>{const n=e.parent;isRule(e)&&e.selector.trim()&&isRule(n)&&n.selector.trim()?transformRuleWithinRule(e,n,t):isAtRule(e)&&isRule(n)&&n.selector.trim()&&isAtruleWithinRule(e)?atruleWithinRule(e,n,t,walk):isAtRule(e)&&isAtRule(n)&&isAtruleWithinAtrule(e,n)&&transformAtruleWithinAtrule(e,n),"nodes"in e&&e.nodes.length&&walk(e,t)})}const creator=()=>({postcssPlugin:"postcss-nesting",Rule(e,{result:t}){walk(e,t),e.selector.trim().includes("&")&&ampersandToScope(e,t)}});creator.postcss=!0;export{creator as default,creator as"module.exports"};

experimental/postcss-nesting/src/lib/rule-within-rule.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import type { Result, Rule } from 'postcss';
55
import groupDeclarations from './group-declarations.js';
66

77
export default function transformRuleWithinRule(node: Rule, parent: Rule, result: Result): void {
8-
let selectors: Array<string> = [];
8+
let selectors: Array<string>;
99

1010
try {
1111
selectors = mergeSelectors(node, result, parent.selectors, node.selectors);

0 commit comments

Comments
 (0)