diff --git a/cli/csstools-cli/dist/cli.cjs b/cli/csstools-cli/dist/cli.cjs index 5b005ccc1a..81df3e5b34 100755 --- a/cli/csstools-cli/dist/cli.cjs +++ b/cli/csstools-cli/dist/cli.cjs @@ -1,3 +1,3 @@ #!/usr/bin/env node -"use strict";var s,e=require("css-blank-pseudo"),o=require("postcss"),t=require("node:path"),i=require("node:fs/promises"),c=require("css-has-pseudo"),n=require("css-prefers-color-scheme"),r=require("postcss-attribute-case-insensitive"),a=require("@csstools/postcss-cascade-layers"),l=require("@csstools/postcss-color-function"),p=require("postcss-color-functional-notation"),u=require("postcss-color-hex-alpha"),d=require("@csstools/postcss-color-mix-function"),g=require("postcss-color-rebeccapurple"),f=require("@csstools/postcss-content-alt-text"),S=require("postcss-custom-media"),v=require("postcss-custom-properties"),h=require("postcss-custom-selectors"),w=require("postcss-dir-pseudo-class"),m=require("postcss-double-position-gradients"),C=require("@csstools/postcss-exponential-functions"),y=require("postcss-focus-visible"),P=require("postcss-focus-within"),b=require("@csstools/postcss-font-format-keywords"),x=require("postcss-gap-properties"),L=require("@csstools/postcss-gradients-interpolation-method"),T=require("@csstools/postcss-hwb-function"),F=require("@csstools/postcss-ic-unit"),q=require("postcss-image-set-function"),k=require("@csstools/postcss-is-pseudo-class"),M=require("postcss-lab-function"),I=require("@csstools/postcss-light-dark-function"),D=require("postcss-logical"),A=require("@csstools/postcss-logical-float-and-clear"),N=require("@csstools/postcss-logical-resize"),O=require("@csstools/postcss-logical-viewport-units"),V=require("@csstools/postcss-media-minmax"),E=require("@csstools/postcss-media-queries-aspect-ratio-number-values"),z=require("@csstools/postcss-nested-calc"),R=require("postcss-nesting"),$=require("@csstools/postcss-normalize-display-values"),U=require("@csstools/postcss-oklab-function"),W=require("postcss-overflow-shorthand"),G=require("postcss-place"),j=require("postcss-preset-env"),H=require("postcss-pseudo-class-any-link"),B=require("@csstools/postcss-relative-color-syntax"),K=require("@csstools/postcss-scope-pseudo-class"),Q=require("postcss-selector-not"),J=require("@csstools/postcss-stepped-value-functions"),Y=require("@csstools/postcss-text-decoration-shorthand"),_=require("@csstools/postcss-trigonometric-functions"),X=require("@csstools/postcss-unset-value");function parseArguments(e,o,t){const i=e.map(s=>s.trim()).filter(s=>!!s),c={stdin:!1,stdout:!1,output:void 0,outputDir:void 0,inputs:[],inlineMap:!0,externalMap:!1,replace:!1,pluginOptions:{},debug:!1};let n,r=!1;for(let e=0;e1&&c.output)return console.warn('[error] omit "--output" when processing multiple inputs\n'),t(),s.InvalidArguments;0===c.inputs.length&&(c.stdin=!0),c.output||c.outputDir||c.replace||(c.stdout=!0),c.stdout&&(c.externalMap=!1);let a={};if(n)try{a=JSON.parse(n)}catch{return console.warn("[error] plugin options must be valid JSON\n"),t(),s.InvalidArguments}for(const e in a){const i=a[e];if(!o.includes(e))return console.warn(`[error] unknown plugin option: ${e}\n`),t(),s.InvalidArguments;c.pluginOptions[e]=i}return c}async function getStdin(){return new Promise(s=>{let e="",o=!1;if(setTimeout(()=>{o=!0,s("")},1e4),process.stdin.isTTY){if(o)return;s(e)}else process.stdin.setEncoding("utf8"),process.stdin.on("readable",()=>{let s="";for(;s=process.stdin.read();)e+=s??""}),process.stdin.on("end",()=>{o||s(e)})})}async function stdinToStdout(s,e,t){let i="";try{const c=await getStdin();c||(t(),process.exit(1));const n=await o([s]).process(c,{from:"stdin",to:"stdout",map:!!e.inlineMap&&{inline:!0}});n.warnings().forEach(s=>{console.warn(s.toString())}),i=n.css}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}process.stdout.write(i+(e.inlineMap?"\n":"")),process.exit(0)}async function stdinToFs(s,e,c){let n=e.output;!n&&e.outputDir&&(n=t.join(e.outputDir,"output.css")),n||process.exit(0);try{const t=await getStdin();t||(c(),process.exit(1));const r=await o([s]).process(t,{from:"stdin",to:n,map:!(!e.inlineMap&&!e.externalMap)&&{inline:e.inlineMap}});r.warnings().forEach(s=>{console.warn(s.toString())}),e.externalMap&&r.map?await Promise.all([await i.writeFile(n,r.css+(e.inlineMap?"\n":"")),await i.writeFile(`${n}.map`,r.map.toString())]):await i.writeFile(n,r.css+(e.inlineMap?"\n":""))}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}console.log(`CSS was written to "${t.normalize(n)}"`),process.exit(0)}async function fsToStdout(s,e){let t=[];try{t=await Promise.all(e.inputs.map(async e=>{const t=await i.readFile(e),c=await o([s]).process(t,{from:e,to:"stdout",map:!1});return c.warnings().forEach(s=>{console.warn(s.toString())}),c.css}))}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}for(const s of t)process.stdout.write(s);process.exit(0)}async function fsToFs(s,e){try{await Promise.all(e.inputs.map(async c=>{let n=e.output;e.outputDir&&(n=t.join(e.outputDir,t.basename(c))),e.replace&&(n=c),n||process.exit(0);const r=await i.readFile(c),a=await o([s]).process(r,{from:c,to:n,map:!(!e.inlineMap&&!e.externalMap)&&{inline:e.inlineMap}});a.warnings().forEach(s=>{console.warn(s.toString())}),e.externalMap&&a.map?await Promise.all([await i.writeFile(n,a.css+(e.inlineMap?"\n":"")),await i.writeFile(`${n}.map`,a.map.toString())]):await i.writeFile(n,a.css+(e.inlineMap?"\n":"")),console.log(`CSS was written to "${t.normalize(n)}"`)}))}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}process.exit(0)}function helpTextLogger(s,e,o,t=null){let i=[];if(t){const s=Math.max(...Object.keys(t).map(s=>s.length)),e=new Array(s).fill(" ").join("");e.length&&(i=["\nPlugin Options:",...Object.keys(t).map(s=>` ${(s+e).slice(0,e.length)} ${typeof t[s]}`)],i.push(`\n ${JSON.stringify(t,null,2).split("\n").join("\n ")}`))}const c=[`${e}\n`,` ${o}\n`,"Usage:",` ${s} [input.css] [OPTIONS] [-o|--output output.css]`,` ${s} ... [OPTIONS] --dir `,` ${s} ... [OPTIONS] --replace`,"\nOptions:"," -o, --output Output file"," -d, --dir Output directory"," -r, --replace Replace (overwrite) the input file"," -m, --map Create an external sourcemap"," --no-map Disable the default inline sourcemaps"," -p, --plugin-options Stringified JSON object with plugin options"];return i.length>0&&c.push(...i),()=>{console.warn(c.join("\n"))}}async function cli(e,o,t,i=!0){const c=parseArguments(process.argv.slice(i?2:3),o,t);c===s.InvalidArguments&&process.exit(1);const n=e(c.pluginOptions);c.stdin&&c.stdout?await stdinToStdout(n,c,t):c.stdin?await stdinToFs(n,c,t):c.stdout?await fsToStdout(n,c):await fsToFs(n,c)}async function cssBlankPseudo(){await cli(e,["preserve","replaceWith"],helpTextLogger("@csstools/cli css-blank-pseudo","PostCSS Blank Pseudo","Lets you style form elements when they are empty, following the Selectors Level 4 specification.",{preserve:!0,replaceWith:".css-blank"}),!1)}async function cssHasPseudo(){await cli(c,["preserve"],helpTextLogger("@csstools/cli css-has-pseudo","PostCSS Has Pseudo","Transforms CSS with :has {}",{preserve:!0}),!1)}async function cssPrefersColorScheme(){await cli(n,["preserve","mediaQuery"],helpTextLogger("@csstools/cli css-prefers-color-scheme","Prefers Color Scheme","Lets you use light and dark color schemes in all browsers, following the Media Queries specification.",{preserve:!0,mediaQuery:"color|color-index"}),!1)}async function postcssAttributeCaseInsensitive(){await cli(r,[],helpTextLogger("@csstools/cli postcss-attribute-case-insensitive","PostCSS Attribute Case Insensitive","Enables support for Case Insensitive Attribute matching in selectors"),!1)}async function postcssCascadeLayers(){await cli(a,[],helpTextLogger("@csstools/cli postcss-cascade-layers","PostCSS Cascade Layers","Lets you use `@layer` following the Cascade Layers Specification."),!1)}async function postcssColorFunction(){await cli(l,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-color-function","PostCSS Color Function","Lets you use the color() function in CSS.",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssColorFunctionalNotation(){await cli(p,["preserve"],helpTextLogger("@csstools/cli postcss-color-functional-notation","PostCSS Color Functional Notation","Lets you use space and slash separated color notation in CSS, following the CSS Color specification.",{preserve:!0}),!1)}async function postcssColorHexAlpha(){await cli(u,["preserve"],helpTextLogger("@csstools/cli postcss-color-hex-alpha","PostCSS Color Hex Alpha","Lets you use 4 & 8 character hex color notation in CSS, following the CSS Color Module specification.",{preserve:!0}),!1)}async function postcssColorMixFunction(){await cli(d,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-color-mix-function","PostCSS Color Mix Function","Lets you use the color-mix() function in CSS.",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssColorRebeccaPurple(){await cli(g,["preserve"],helpTextLogger("@csstools/cli postcss-color-rebeccapurple","PostCSS RebeccaPurple","Lets you use the rebeccapurple color keyword in CSS.",{preserve:!0}),!1)}async function postcssContentAltText(){await cli(f,["preserve","stripAltText","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-content-alt-text","PostCSS Content Alt Text","Generate fallback values for content with alt text.",{preserve:!0,stripAltText:!1,enableProgressiveCustomProperties:!0}),!1)}async function postcssCustomMedia(){await cli(S,["preserve"],helpTextLogger("@csstools/cli postcss-custom-media","PostCSS Custom Media","Lets you define @custom-media in CSS following the Custom Media Specification",{preserve:!0}),!1)}async function postcssCustomProperties(){await cli(v,["preserve"],helpTextLogger("@csstools/cli postcss-custom-properties","PostCSS Custom Properties","Lets you use Custom Properties in CSS, following the CSS Custom Properties specification.",{preserve:!0}),!1)}async function postcssCustomSelectors(){await cli(h,["preserve"],helpTextLogger("@csstools/cli postcss-custom-selectors","PostCSS Custom Selectors","Lets you define @custom-selector in CSS following the Custom Selectors Specification",{preserve:!0}),!1)}async function postcssDirPseudoClass(){await cli(w,["dir","preserve","shadow"],helpTextLogger("@csstools/cli postcss-dir-pseudo-class","PostCSS Dir Pseudo Class","Lets you style by directionality using the `:dir()` pseudo-class in CSS",{dir:"ltr",preserve:!0,shadow:!0}),!1)}async function postcssDoublePositionGradients(){await cli(m,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-double-position-gradients","PostCSS Double Position Gradients","Lets you use double-position gradients in CSS, following the CSS Image Values and Replaced Content specification",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssExponentialFunctions(){await cli(C,["preserve"],helpTextLogger("@csstools/cli postcss-exponential-functions","PostCSS Exponential Functions","Lets you use the `pow()`, `sqrt()`, `hypot()`, `log()`, `exp()` functions following the CSS Values 4 Specification.",{preserve:!0}),!1)}async function postcssFocusVisible(){await cli(y,["preserve","replaceWith"],helpTextLogger("@csstools/cli postcss-focus-visible","PostCSS Focus Visible","Lets you use the `:focus-visible` pseudo-class in CSS, following the Selectors Level 4 specification.",{preserve:!0,replaceWith:".focus-visible"}),!1)}async function postcssFocusWithin(){await cli(P,["preserve","replaceWith"],helpTextLogger("@csstools/cli postcss-focus-within","PostCSS Focus Within","Lets you use the `:focus-within` pseudo-class in CSS, following the Selectors Level 4 specification.",{preserve:!0,replaceWith:".focus-within"}),!1)}async function postcssFontFormatKeywords(){await cli(b,["preserve"],helpTextLogger("@csstools/cli postcss-font-format-keywords","PostCSS Font Format Keyword","Lets you use unquoted format on @font-face CSS definitions.",{preserve:!0}),!1)}async function postcssGapProperties(){await cli(x,["preserve"],helpTextLogger("@csstools/cli postcss-gap-properties","PostCSS Gap Properties","Lets you use the gap, column-gap, and row-gap shorthand properties in CSS, following the CSS Grid Layout specification.",{preserve:!0}),!1)}async function postcssGradientsInterpolationMethod(){await cli(L,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-gradients-interpolation-method","PostCSS Gradients Interpolation Method","Lets you use different interpolation methods in CSS gradient functions.",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssHWBFunction(){await cli(T,["preserve"],helpTextLogger("@csstools/cli postcss-hwb-function","PostCSS HWB function","Convert hwb() to rgb()",{preserve:!0}),!1)}async function postcssICUnit(){await cli(F,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-ic-unit","PostCSS IC Unit","Lets you use the ic length unit.",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssImageSetFunction(){await cli(q,["oninvalid","preserve"],helpTextLogger("@csstools/cli postcss-image-set-function","PostCSS Image Set Function","Lets you display resolution-dependent images using the image-set() function in CSS, following the CSS Images specification.",{preserve:!0,oninvalid:"ignore|warn|throw"}),!1)}async function postcssIsPseudoClass(){await cli(k,["onComplexSelector","preserve","specificityMatchingName"],helpTextLogger("@csstools/cli postcss-is-pseudo-class","PostCSS Is Pseudo Class","Lets you use the :is pseudo class function, following the CSS Selector specification.",{onComplexSelector:"warning",preserve:!0,specificityMatchingName:"does-not-exist"}),!1)}async function postcssLabFunction(){await cli(M,["preserve","enableProgressiveCustomProperties","subFeatures"],helpTextLogger("@csstools/cli postcss-lab-function","PostCSS Lab function","Convert lab() to rgb()",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssLightDarkFunction(){await cli(I,["preserve"],helpTextLogger("@csstools/cli postcss-light-dark-function","PostCSS Light Dark function","Use the light-dark() color function in CSS",{preserve:!0}),!1)}async function postcssLogical$1(){await cli(D,["inlineDirection","blockDirection"],helpTextLogger("@csstools/cli postcss-logical","PostCSS Logical","Lets you use logical, rather than physical, direction and dimension mappings in CSS, following the CSS Logical Properties and Values specification.",{inlineDirection:"left-to-right",blockDirection:"top-to-bottom"}),!1)}async function postcssLogical(){await cli(A,["inlineDirection","blockDirection"],helpTextLogger("@csstools/cli postcss-logical-float-and-clear","PostCSS Logical Float And Clear","Lets you use flow-relative (inline-start and inline-end) values for float and clear, following the CSS Logical Properties and Values specification.",{inlineDirection:"left-to-right"}),!1)}async function postcssLogicalResize(){await cli(N,["inlineDirection"],helpTextLogger("@csstools/cli postcss-logical-resize","PostCSS Logical Resize","Lets you use logical values in the resize property, following the CSS Logical Properties and Values specification.",{inlineDirection:"left-to-right"}),!1)}async function postcssLogicalViewportUnits(){await cli(O,["inlineDirection","preserve"],helpTextLogger("@csstools/cli postcss-viewport-units","PostCSS Logical Viewport Units","Lets you use vb and vi length units in CSS, following the CSS Values and Units Module Level 4 specification.",{inlineDirection:"left-to-right",preserve:!0}),!1)}async function postcssMediaMinMax(){await cli(V,[],helpTextLogger("@csstools/cli postcss-media-minmax","PostCSS Media MinMax","Lets you use the range notation in CSS media queries.",{}),!1)}async function postcssMediaQueriesAspectRatioNumberValues(){await cli(E,[],helpTextLogger("@csstools/cli postcss-media-queries-aspect-ratio-number-values","PostCSS Media Queries Aspect-Ratio Number Values","Lets you use number values in aspect-ratio media queries.",{}),!1)}async function postcssNestedCalc(){await cli(z,["preserve"],helpTextLogger("@csstools/cli postcss-nested-calc","PostCSS Nested Calc","Lets you use nested calc() expressions in CSS.",{preserve:!0}),!1)}async function postcssNesting(){await cli(R,["noIsPseudoSelector"],helpTextLogger("@csstools/cli postcss-nesting","PostCSS Nesting","Lets you nest style rules inside each other, following the CSS Nesting specification.",{noIsPseudoSelector:!0}),!1)}async function postcssNormalizeDisplayValues(){await cli($,["preserve"],helpTextLogger("@csstools/cli postcss-normalize-display-values","PostCSS Normalize Display Values","Lets you use two values display syntax for inner and outer display types.",{preserve:!0}),!1)}async function postcssOKLabFunction(){await cli(U,["preserve","enableProgressiveCustomProperties","subFeatures"],helpTextLogger("@csstools/cli postcss-oklab-function","PostCSS OKLab Function","Lets you use oklab() and oklch() color functions in CSS.",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssOverflowShorthand(){await cli(W,["preserve"],helpTextLogger("@csstools/cli postcss-overflow-shorthand","PostCSS Overflow Shorthand","Lets you use the `overflow` shorthand in CSS, following the CSS Overflow specification.",{preserve:!0}),!1)}async function postcssPlace(){await cli(G,["preserve"],helpTextLogger("@csstools/cli postcss-place","PostCSS Place","Lets you use place-* properties as shorthands for align-* and justify-*, following the CSS Box Alignment specification.",{preserve:!0}),!1)}async function postcssPresetEnv(){await cli(j,["stage","minimumVendorImplementations","features","env","browsers","autoprefixer","preserve","logical","enableClientSidePolyfills","debug"],helpTextLogger("@csstools/cli postcss-preset-env","PostCSS Preset Env","Lets you convert modern CSS into something most browsers can understand, determining the polyfills you need based on your targeted browsers or runtime environments.",{stage:0,minimumVendorImplementations:2,features:{"blank-pseudo-class":{preserve:!1},"color-functional-notation":{preserve:!0}},env:"production",browsers:"last 2 versions",autoprefixer:{grid:!0},preserve:!1,logical:{inlineDirection:"left-to-right",blockDirection:"top-to-bottom"},enableClientSidePolyfills:!1,debug:!1}),!1)}async function postcssPseudoClassAnyLink(){await cli(H,["preserve"],helpTextLogger("@csstools/cli postcss-pseudo-class-any-link","PostCSS Pseudo Class Any Link","Lets you :any-link pseudo-class in CSS, following the Selectors specification.",{preserve:!0}),!1)}async function postcssRelativeColorSyntax(){await cli(B,["preserve","enableProgressiveCustomProperties","subFeatures"],helpTextLogger("@csstools/cli postcss-relative-color-syntax","PostCSS Relative Color Syntax","Lets you use the relative color syntax in CSS color functions.",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssScopePseudoClass(){await cli(K,["preserve"],helpTextLogger("@csstools/cli postcss-scope-pseudo-class","PostCSS Scope Pseudo Class","Lets you use the Reference Element Pseudo-class: :scope.",{preserve:!0}),!1)}async function postcssSelectorNot(){await cli(Q,[],helpTextLogger("@csstools/cli postcss-selector-not","PostCSS Selector Not","Transforms :not() W3C CSS level 4 pseudo classes to :not() CSS level 3 selectors following the Selectors 4 Specification"),!1)}async function postcssSteppedValueFunctions(){await cli(J,["preserve","onInvalid"],helpTextLogger("@csstools/cli postcss-stepped-value-functions","PostCSS Stepped Value Functions","Lets you use round(), mod() and rem() functions.",{preserve:!1,onInvalid:"warn"}),!1)}async function postcssTextDecorationShorthand(){await cli(Y,["preserve"],helpTextLogger("@csstools/cli postcss-text-decoration-shorthand","PostCSS Text Decoration Shorthand","Lets you use text-decoration in it's shorthand form in CSS.",{preserve:!0}),!1)}async function postcssTrigonometricFunctions(){await cli(_,["preserve"],helpTextLogger("@csstools/cli postcss-trigonometric-functions","PostCSS Trigonometric Functions","Lets you use `sin`, `cos`, `tan`, `asin`, `acos`, `atan` and `atan2` to be able to compute trigonometric relationships following the CSS Values 4 specification.",{preserve:!0}),!1)}async function postcssUnsetValue(){await cli(X,["preserve"],helpTextLogger("@csstools/cli postcss-unset-value","PostCSS Stepped Unset Value","Use the unset keyword in CSS.",{preserve:!1}),!1)}(s||(s={})).InvalidArguments="INVALID_ARGUMENTS",async function main(){switch(process.argv[2]??!1){case"css-blank-pseudo":return void await cssBlankPseudo();case"css-has-pseudo":return void await cssHasPseudo();case"css-prefers-color-scheme":return void await cssPrefersColorScheme();case"postcss-attribute-case-insensitive":return void await postcssAttributeCaseInsensitive();case"postcss-cascade-layers":return void await postcssCascadeLayers();case"postcss-color-function":return void await postcssColorFunction();case"postcss-color-mix-function":return void await postcssColorMixFunction();case"postcss-color-functional-notation":return void await postcssColorFunctionalNotation();case"postcss-color-hex-alpha":return void await postcssColorHexAlpha();case"postcss-color-rebeccapurple":return void await postcssColorRebeccaPurple();case"postcss-content-alt-text":return void await postcssContentAltText();case"postcss-custom-media":return void await postcssCustomMedia();case"postcss-custom-properties":return void await postcssCustomProperties();case"postcss-custom-selectors":return void await postcssCustomSelectors();case"postcss-dir-pseudo-class":return void await postcssDirPseudoClass();case"postcss-double-position-gradients":return void await postcssDoublePositionGradients();case"postcss-exponential-functions":return void await postcssExponentialFunctions();case"postcss-focus-visible":return void await postcssFocusVisible();case"postcss-focus-within":return void await postcssFocusWithin();case"postcss-font-format-keywords":return void await postcssFontFormatKeywords();case"postcss-gap-properties":return void await postcssGapProperties();case"postcss-gradients-interpolation-method":return void await postcssGradientsInterpolationMethod();case"postcss-hwb-function":return void await postcssHWBFunction();case"postcss-ic-unit":return void await postcssICUnit();case"postcss-image-set-function":return void await postcssImageSetFunction();case"postcss-is-pseudo-class":return void await postcssIsPseudoClass();case"postcss-lab-function":return void await postcssLabFunction();case"postcss-light-dark-function":return void await postcssLightDarkFunction();case"postcss-logical":return void await postcssLogical$1();case"postcss-logical-float-and-clear":return void await postcssLogical();case"postcss-logical-resize":return void await postcssLogicalResize();case"postcss-logical-viewport-units":return void await postcssLogicalViewportUnits();case"postcss-media-minmax":return void await postcssMediaMinMax();case"postcss-media-queries-aspect-ratio-number-values":return void await postcssMediaQueriesAspectRatioNumberValues();case"postcss-nested-calc":return void await postcssNestedCalc();case"postcss-nesting":return void await postcssNesting();case"postcss-normalize-display-values":return void await postcssNormalizeDisplayValues();case"postcss-oklab-function":return void await postcssOKLabFunction();case"postcss-overflow-shorthand":return void await postcssOverflowShorthand();case"postcss-place":return void await postcssPlace();case"postcss-preset-env":return void await postcssPresetEnv();case"postcss-pseudo-class-any-link":return void await postcssPseudoClassAnyLink();case"postcss-scope-pseudo-class":return void await postcssScopePseudoClass();case"postcss-relative-color-syntax":return void await postcssRelativeColorSyntax();case"postcss-selector-not":return void await postcssSelectorNot();case"postcss-stepped-value-functions":return void await postcssSteppedValueFunctions();case"postcss-text-decoration-shorthand":return void await postcssTextDecorationShorthand();case"postcss-trigonometric-functions":return void await postcssTrigonometricFunctions();case"postcss-unset-value":return void await postcssUnsetValue();default:{const s=["CSSTools CLI\n"," Transform CSS with any plugin from https://github.com/csstools/postcss-plugins\n","Usage:"," @csstools/csstools-cli postcss-preset-env [input.css] [OPTIONS] [-o|--output output.css]"," @csstools/csstools-cli postcss-preset-env ... [OPTIONS] --dir "," @csstools/csstools-cli postcss-preset-env ... [OPTIONS] --replace","\nAvailable Plugins:"," postcss-preset-env"," css-blank-pseudo"," css-has-pseudo"," css-prefers-color-scheme"," postcss-attribute-case-insensitive"," postcss-cascade-layers"," postcss-color-function"," postcss-color-functional-notation"," postcss-color-hex-alpha"," postcss-color-mix-function"," postcss-color-rebeccapurple"," postcss-content-alt-text"," postcss-custom-media"," postcss-custom-properties"," postcss-custom-selectors"," postcss-dir-pseudo-class"," postcss-double-position-gradients"," postcss-exponential-functions"," postcss-focus-visible"," postcss-focus-within"," postcss-font-format-keywords"," postcss-gap-properties"," postcss-gradients-interpolation-method"," postcss-hwb-function"," postcss-ic-unit"," postcss-image-set-function"," postcss-is-pseudo-class"," postcss-lab-function"," postcss-light-dark-function"," postcss-logical"," postcss-logical-float-and-clear"," postcss-logical-resize"," postcss-logical-viewport-units"," postcss-media-minmax"," postcss-media-queries-aspect-ratio-number-values"," postcss-nested-calc"," postcss-nesting"," postcss-normalize-display-values"," postcss-oklab-function"," postcss-overflow-shorthand"," postcss-place"," postcss-pseudo-class-any-link"," postcss-relative-color-syntax"," postcss-scope-pseudo-class"," postcss-selector-not"," postcss-stepped-value-functions"," postcss-text-decoration-shorthand"," postcss-trigonometric-functions"," postcss-unset-value","\nPlugin Help:"," @csstools/csstools-cli "," @csstools/csstools-cli postcss-preset-env"];console.warn(s.join("\n"))}}}(); +"use strict";var s,e=require("css-blank-pseudo"),o=require("postcss"),t=require("node:path"),i=require("node:fs/promises"),c=require("css-has-pseudo"),n=require("css-prefers-color-scheme"),r=require("postcss-attribute-case-insensitive"),a=require("@csstools/postcss-cascade-layers"),l=require("@csstools/postcss-color-function"),p=require("postcss-color-functional-notation"),u=require("postcss-color-hex-alpha"),d=require("@csstools/postcss-color-mix-function"),g=require("postcss-color-rebeccapurple"),f=require("@csstools/postcss-content-alt-text"),S=require("postcss-custom-media"),v=require("postcss-custom-properties"),h=require("postcss-custom-selectors"),w=require("postcss-dir-pseudo-class"),m=require("postcss-double-position-gradients"),C=require("@csstools/postcss-exponential-functions"),y=require("postcss-focus-visible"),P=require("postcss-focus-within"),b=require("@csstools/postcss-font-format-keywords"),x=require("postcss-gap-properties"),L=require("@csstools/postcss-gradients-interpolation-method"),T=require("@csstools/postcss-hwb-function"),F=require("@csstools/postcss-ic-unit"),q=require("postcss-image-set-function"),k=require("@csstools/postcss-is-pseudo-class"),M=require("postcss-lab-function"),I=require("@csstools/postcss-light-dark-function"),D=require("postcss-logical"),A=require("@csstools/postcss-logical-float-and-clear"),N=require("@csstools/postcss-logical-resize"),O=require("@csstools/postcss-logical-viewport-units"),V=require("@csstools/postcss-media-minmax"),E=require("@csstools/postcss-media-queries-aspect-ratio-number-values"),z=require("@csstools/postcss-nested-calc"),R=require("postcss-nesting"),$=require("@csstools/postcss-normalize-display-values"),U=require("@csstools/postcss-oklab-function"),W=require("postcss-overflow-shorthand"),G=require("postcss-place"),j=require("postcss-preset-env"),H=require("postcss-pseudo-class-any-link"),B=require("@csstools/postcss-relative-color-syntax"),K=require("@csstools/postcss-scope-pseudo-class"),Q=require("postcss-selector-not"),J=require("@csstools/postcss-stepped-value-functions"),Y=require("@csstools/postcss-text-decoration-shorthand"),_=require("@csstools/postcss-trigonometric-functions"),X=require("@csstools/postcss-unset-value");function parseArguments(e,o,t){const i=e.map(s=>s.trim()).filter(s=>!!s),c={stdin:!1,stdout:!1,output:void 0,outputDir:void 0,inputs:[],inlineMap:!0,externalMap:!1,replace:!1,pluginOptions:{},debug:!1};let n,r=!1;for(let e=0;e1&&c.output)return console.warn('[error] omit "--output" when processing multiple inputs\n'),t(),s.InvalidArguments;0===c.inputs.length&&(c.stdin=!0),c.output||c.outputDir||c.replace||(c.stdout=!0),c.stdout&&(c.externalMap=!1);let a={};if(n)try{a=JSON.parse(n)}catch{return console.warn("[error] plugin options must be valid JSON\n"),t(),s.InvalidArguments}for(const e in a){const i=a[e];if(!o.includes(e))return console.warn(`[error] unknown plugin option: ${e}\n`),t(),s.InvalidArguments;c.pluginOptions[e]=i}return c}async function getStdin(){return new Promise(s=>{let e="",o=!1;if(setTimeout(()=>{o=!0,s("")},1e4),process.stdin.isTTY){if(o)return;s(e)}else process.stdin.setEncoding("utf8"),process.stdin.on("readable",()=>{let s="";for(;s=process.stdin.read();)e+=s??""}),process.stdin.on("end",()=>{o||s(e)})})}async function stdinToStdout(s,e,t){let i="";try{const c=await getStdin();c||(t(),process.exit(1));const n=await o([s]).process(c,{from:"stdin",to:"stdout",map:!!e.inlineMap&&{inline:!0}});n.warnings().forEach(s=>{console.warn(s.toString())}),i=n.css}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}process.stdout.write(i+(e.inlineMap?"\n":"")),process.exit(0)}async function stdinToFs(s,e,c){let n=e.output;!n&&e.outputDir&&(n=t.join(e.outputDir,"output.css")),n||process.exit(0);try{const t=await getStdin();t||(c(),process.exit(1));const r=await o([s]).process(t,{from:"stdin",to:n,map:!(!e.inlineMap&&!e.externalMap)&&{inline:e.inlineMap}});r.warnings().forEach(s=>{console.warn(s.toString())}),e.externalMap&&r.map?await Promise.all([i.writeFile(n,r.css+(e.inlineMap?"\n":"")),i.writeFile(`${n}.map`,r.map.toString())]):await i.writeFile(n,r.css+(e.inlineMap?"\n":""))}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}console.log(`CSS was written to "${t.normalize(n)}"`),process.exit(0)}async function fsToStdout(s,e){let t=[];try{t=await Promise.all(e.inputs.map(async e=>{const t=await i.readFile(e),c=await o([s]).process(t,{from:e,to:"stdout",map:!1});return c.warnings().forEach(s=>{console.warn(s.toString())}),c.css}))}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}for(const s of t)process.stdout.write(s);process.exit(0)}async function fsToFs(s,e){try{await Promise.all(e.inputs.map(async c=>{let n=e.output;e.outputDir&&(n=t.join(e.outputDir,t.basename(c))),e.replace&&(n=c),n||process.exit(0);const r=await i.readFile(c),a=await o([s]).process(r,{from:c,to:n,map:!(!e.inlineMap&&!e.externalMap)&&{inline:e.inlineMap}});a.warnings().forEach(s=>{console.warn(s.toString())}),e.externalMap&&a.map?await Promise.all([i.writeFile(n,a.css+(e.inlineMap?"\n":"")),i.writeFile(`${n}.map`,a.map.toString())]):await i.writeFile(n,a.css+(e.inlineMap?"\n":"")),console.log(`CSS was written to "${t.normalize(n)}"`)}))}catch(s){s instanceof Error?console.error(e.debug?s:s.message):console.error(s),process.exit(1)}process.exit(0)}function helpTextLogger(s,e,o,t=null){let i=[];if(t){const s=Math.max(...Object.keys(t).map(s=>s.length)),e=new Array(s).fill(" ").join("");e.length&&(i=["\nPlugin Options:",...Object.keys(t).map(s=>` ${(s+e).slice(0,e.length)} ${typeof t[s]}`)],i.push(`\n ${JSON.stringify(t,null,2).split("\n").join("\n ")}`))}const c=[`${e}\n`,` ${o}\n`,"Usage:",` ${s} [input.css] [OPTIONS] [-o|--output output.css]`,` ${s} ... [OPTIONS] --dir `,` ${s} ... [OPTIONS] --replace`,"\nOptions:"," -o, --output Output file"," -d, --dir Output directory"," -r, --replace Replace (overwrite) the input file"," -m, --map Create an external sourcemap"," --no-map Disable the default inline sourcemaps"," -p, --plugin-options Stringified JSON object with plugin options"];return i.length>0&&c.push(...i),()=>{console.warn(c.join("\n"))}}async function cli(e,o,t,i=!0){const c=parseArguments(process.argv.slice(i?2:3),o,t);c===s.InvalidArguments&&process.exit(1);const n=e(c.pluginOptions);c.stdin&&c.stdout?await stdinToStdout(n,c,t):c.stdin?await stdinToFs(n,c,t):c.stdout?await fsToStdout(n,c):await fsToFs(n,c)}async function cssBlankPseudo(){await cli(e,["preserve","replaceWith"],helpTextLogger("@csstools/cli css-blank-pseudo","PostCSS Blank Pseudo","Lets you style form elements when they are empty, following the Selectors Level 4 specification.",{preserve:!0,replaceWith:".css-blank"}),!1)}async function cssHasPseudo(){await cli(c,["preserve"],helpTextLogger("@csstools/cli css-has-pseudo","PostCSS Has Pseudo","Transforms CSS with :has {}",{preserve:!0}),!1)}async function cssPrefersColorScheme(){await cli(n,["preserve","mediaQuery"],helpTextLogger("@csstools/cli css-prefers-color-scheme","Prefers Color Scheme","Lets you use light and dark color schemes in all browsers, following the Media Queries specification.",{preserve:!0,mediaQuery:"color|color-index"}),!1)}async function postcssAttributeCaseInsensitive(){await cli(r,[],helpTextLogger("@csstools/cli postcss-attribute-case-insensitive","PostCSS Attribute Case Insensitive","Enables support for Case Insensitive Attribute matching in selectors"),!1)}async function postcssCascadeLayers(){await cli(a,[],helpTextLogger("@csstools/cli postcss-cascade-layers","PostCSS Cascade Layers","Lets you use `@layer` following the Cascade Layers Specification."),!1)}async function postcssColorFunction(){await cli(l,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-color-function","PostCSS Color Function","Lets you use the color() function in CSS.",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssColorFunctionalNotation(){await cli(p,["preserve"],helpTextLogger("@csstools/cli postcss-color-functional-notation","PostCSS Color Functional Notation","Lets you use space and slash separated color notation in CSS, following the CSS Color specification.",{preserve:!0}),!1)}async function postcssColorHexAlpha(){await cli(u,["preserve"],helpTextLogger("@csstools/cli postcss-color-hex-alpha","PostCSS Color Hex Alpha","Lets you use 4 & 8 character hex color notation in CSS, following the CSS Color Module specification.",{preserve:!0}),!1)}async function postcssColorMixFunction(){await cli(d,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-color-mix-function","PostCSS Color Mix Function","Lets you use the color-mix() function in CSS.",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssColorRebeccaPurple(){await cli(g,["preserve"],helpTextLogger("@csstools/cli postcss-color-rebeccapurple","PostCSS RebeccaPurple","Lets you use the rebeccapurple color keyword in CSS.",{preserve:!0}),!1)}async function postcssContentAltText(){await cli(f,["preserve","stripAltText","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-content-alt-text","PostCSS Content Alt Text","Generate fallback values for content with alt text.",{preserve:!0,stripAltText:!1,enableProgressiveCustomProperties:!0}),!1)}async function postcssCustomMedia(){await cli(S,["preserve"],helpTextLogger("@csstools/cli postcss-custom-media","PostCSS Custom Media","Lets you define @custom-media in CSS following the Custom Media Specification",{preserve:!0}),!1)}async function postcssCustomProperties(){await cli(v,["preserve"],helpTextLogger("@csstools/cli postcss-custom-properties","PostCSS Custom Properties","Lets you use Custom Properties in CSS, following the CSS Custom Properties specification.",{preserve:!0}),!1)}async function postcssCustomSelectors(){await cli(h,["preserve"],helpTextLogger("@csstools/cli postcss-custom-selectors","PostCSS Custom Selectors","Lets you define @custom-selector in CSS following the Custom Selectors Specification",{preserve:!0}),!1)}async function postcssDirPseudoClass(){await cli(w,["dir","preserve","shadow"],helpTextLogger("@csstools/cli postcss-dir-pseudo-class","PostCSS Dir Pseudo Class","Lets you style by directionality using the `:dir()` pseudo-class in CSS",{dir:"ltr",preserve:!0,shadow:!0}),!1)}async function postcssDoublePositionGradients(){await cli(m,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-double-position-gradients","PostCSS Double Position Gradients","Lets you use double-position gradients in CSS, following the CSS Image Values and Replaced Content specification",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssExponentialFunctions(){await cli(C,["preserve"],helpTextLogger("@csstools/cli postcss-exponential-functions","PostCSS Exponential Functions","Lets you use the `pow()`, `sqrt()`, `hypot()`, `log()`, `exp()` functions following the CSS Values 4 Specification.",{preserve:!0}),!1)}async function postcssFocusVisible(){await cli(y,["preserve","replaceWith"],helpTextLogger("@csstools/cli postcss-focus-visible","PostCSS Focus Visible","Lets you use the `:focus-visible` pseudo-class in CSS, following the Selectors Level 4 specification.",{preserve:!0,replaceWith:".focus-visible"}),!1)}async function postcssFocusWithin(){await cli(P,["preserve","replaceWith"],helpTextLogger("@csstools/cli postcss-focus-within","PostCSS Focus Within","Lets you use the `:focus-within` pseudo-class in CSS, following the Selectors Level 4 specification.",{preserve:!0,replaceWith:".focus-within"}),!1)}async function postcssFontFormatKeywords(){await cli(b,["preserve"],helpTextLogger("@csstools/cli postcss-font-format-keywords","PostCSS Font Format Keyword","Lets you use unquoted format on @font-face CSS definitions.",{preserve:!0}),!1)}async function postcssGapProperties(){await cli(x,["preserve"],helpTextLogger("@csstools/cli postcss-gap-properties","PostCSS Gap Properties","Lets you use the gap, column-gap, and row-gap shorthand properties in CSS, following the CSS Grid Layout specification.",{preserve:!0}),!1)}async function postcssGradientsInterpolationMethod(){await cli(L,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-gradients-interpolation-method","PostCSS Gradients Interpolation Method","Lets you use different interpolation methods in CSS gradient functions.",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssHWBFunction(){await cli(T,["preserve"],helpTextLogger("@csstools/cli postcss-hwb-function","PostCSS HWB function","Convert hwb() to rgb()",{preserve:!0}),!1)}async function postcssICUnit(){await cli(F,["preserve","enableProgressiveCustomProperties"],helpTextLogger("@csstools/cli postcss-ic-unit","PostCSS IC Unit","Lets you use the ic length unit.",{preserve:!0,enableProgressiveCustomProperties:!1}),!1)}async function postcssImageSetFunction(){await cli(q,["oninvalid","preserve"],helpTextLogger("@csstools/cli postcss-image-set-function","PostCSS Image Set Function","Lets you display resolution-dependent images using the image-set() function in CSS, following the CSS Images specification.",{preserve:!0,oninvalid:"ignore|warn|throw"}),!1)}async function postcssIsPseudoClass(){await cli(k,["onComplexSelector","preserve","specificityMatchingName"],helpTextLogger("@csstools/cli postcss-is-pseudo-class","PostCSS Is Pseudo Class","Lets you use the :is pseudo class function, following the CSS Selector specification.",{onComplexSelector:"warning",preserve:!0,specificityMatchingName:"does-not-exist"}),!1)}async function postcssLabFunction(){await cli(M,["preserve","enableProgressiveCustomProperties","subFeatures"],helpTextLogger("@csstools/cli postcss-lab-function","PostCSS Lab function","Convert lab() to rgb()",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssLightDarkFunction(){await cli(I,["preserve"],helpTextLogger("@csstools/cli postcss-light-dark-function","PostCSS Light Dark function","Use the light-dark() color function in CSS",{preserve:!0}),!1)}async function postcssLogical$1(){await cli(D,["inlineDirection","blockDirection"],helpTextLogger("@csstools/cli postcss-logical","PostCSS Logical","Lets you use logical, rather than physical, direction and dimension mappings in CSS, following the CSS Logical Properties and Values specification.",{inlineDirection:"left-to-right",blockDirection:"top-to-bottom"}),!1)}async function postcssLogical(){await cli(A,["inlineDirection","blockDirection"],helpTextLogger("@csstools/cli postcss-logical-float-and-clear","PostCSS Logical Float And Clear","Lets you use flow-relative (inline-start and inline-end) values for float and clear, following the CSS Logical Properties and Values specification.",{inlineDirection:"left-to-right"}),!1)}async function postcssLogicalResize(){await cli(N,["inlineDirection"],helpTextLogger("@csstools/cli postcss-logical-resize","PostCSS Logical Resize","Lets you use logical values in the resize property, following the CSS Logical Properties and Values specification.",{inlineDirection:"left-to-right"}),!1)}async function postcssLogicalViewportUnits(){await cli(O,["inlineDirection","preserve"],helpTextLogger("@csstools/cli postcss-viewport-units","PostCSS Logical Viewport Units","Lets you use vb and vi length units in CSS, following the CSS Values and Units Module Level 4 specification.",{inlineDirection:"left-to-right",preserve:!0}),!1)}async function postcssMediaMinMax(){await cli(V,[],helpTextLogger("@csstools/cli postcss-media-minmax","PostCSS Media MinMax","Lets you use the range notation in CSS media queries.",{}),!1)}async function postcssMediaQueriesAspectRatioNumberValues(){await cli(E,[],helpTextLogger("@csstools/cli postcss-media-queries-aspect-ratio-number-values","PostCSS Media Queries Aspect-Ratio Number Values","Lets you use number values in aspect-ratio media queries.",{}),!1)}async function postcssNestedCalc(){await cli(z,["preserve"],helpTextLogger("@csstools/cli postcss-nested-calc","PostCSS Nested Calc","Lets you use nested calc() expressions in CSS.",{preserve:!0}),!1)}async function postcssNesting(){await cli(R,["noIsPseudoSelector"],helpTextLogger("@csstools/cli postcss-nesting","PostCSS Nesting","Lets you nest style rules inside each other, following the CSS Nesting specification.",{noIsPseudoSelector:!0}),!1)}async function postcssNormalizeDisplayValues(){await cli($,["preserve"],helpTextLogger("@csstools/cli postcss-normalize-display-values","PostCSS Normalize Display Values","Lets you use two values display syntax for inner and outer display types.",{preserve:!0}),!1)}async function postcssOKLabFunction(){await cli(U,["preserve","enableProgressiveCustomProperties","subFeatures"],helpTextLogger("@csstools/cli postcss-oklab-function","PostCSS OKLab Function","Lets you use oklab() and oklch() color functions in CSS.",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssOverflowShorthand(){await cli(W,["preserve"],helpTextLogger("@csstools/cli postcss-overflow-shorthand","PostCSS Overflow Shorthand","Lets you use the `overflow` shorthand in CSS, following the CSS Overflow specification.",{preserve:!0}),!1)}async function postcssPlace(){await cli(G,["preserve"],helpTextLogger("@csstools/cli postcss-place","PostCSS Place","Lets you use place-* properties as shorthands for align-* and justify-*, following the CSS Box Alignment specification.",{preserve:!0}),!1)}async function postcssPresetEnv(){await cli(j,["stage","minimumVendorImplementations","features","env","browsers","autoprefixer","preserve","logical","enableClientSidePolyfills","debug"],helpTextLogger("@csstools/cli postcss-preset-env","PostCSS Preset Env","Lets you convert modern CSS into something most browsers can understand, determining the polyfills you need based on your targeted browsers or runtime environments.",{stage:0,minimumVendorImplementations:2,features:{"blank-pseudo-class":{preserve:!1},"color-functional-notation":{preserve:!0}},env:"production",browsers:"last 2 versions",autoprefixer:{grid:!0},preserve:!1,logical:{inlineDirection:"left-to-right",blockDirection:"top-to-bottom"},enableClientSidePolyfills:!1,debug:!1}),!1)}async function postcssPseudoClassAnyLink(){await cli(H,["preserve"],helpTextLogger("@csstools/cli postcss-pseudo-class-any-link","PostCSS Pseudo Class Any Link","Lets you :any-link pseudo-class in CSS, following the Selectors specification.",{preserve:!0}),!1)}async function postcssRelativeColorSyntax(){await cli(B,["preserve","enableProgressiveCustomProperties","subFeatures"],helpTextLogger("@csstools/cli postcss-relative-color-syntax","PostCSS Relative Color Syntax","Lets you use the relative color syntax in CSS color functions.",{preserve:!0,enableProgressiveCustomProperties:!1,subFeatures:{displayP3:!1}}),!1)}async function postcssScopePseudoClass(){await cli(K,["preserve"],helpTextLogger("@csstools/cli postcss-scope-pseudo-class","PostCSS Scope Pseudo Class","Lets you use the Reference Element Pseudo-class: :scope.",{preserve:!0}),!1)}async function postcssSelectorNot(){await cli(Q,[],helpTextLogger("@csstools/cli postcss-selector-not","PostCSS Selector Not","Transforms :not() W3C CSS level 4 pseudo classes to :not() CSS level 3 selectors following the Selectors 4 Specification"),!1)}async function postcssSteppedValueFunctions(){await cli(J,["preserve","onInvalid"],helpTextLogger("@csstools/cli postcss-stepped-value-functions","PostCSS Stepped Value Functions","Lets you use round(), mod() and rem() functions.",{preserve:!1,onInvalid:"warn"}),!1)}async function postcssTextDecorationShorthand(){await cli(Y,["preserve"],helpTextLogger("@csstools/cli postcss-text-decoration-shorthand","PostCSS Text Decoration Shorthand","Lets you use text-decoration in it's shorthand form in CSS.",{preserve:!0}),!1)}async function postcssTrigonometricFunctions(){await cli(_,["preserve"],helpTextLogger("@csstools/cli postcss-trigonometric-functions","PostCSS Trigonometric Functions","Lets you use `sin`, `cos`, `tan`, `asin`, `acos`, `atan` and `atan2` to be able to compute trigonometric relationships following the CSS Values 4 specification.",{preserve:!0}),!1)}async function postcssUnsetValue(){await cli(X,["preserve"],helpTextLogger("@csstools/cli postcss-unset-value","PostCSS Stepped Unset Value","Use the unset keyword in CSS.",{preserve:!1}),!1)}(s||(s={})).InvalidArguments="INVALID_ARGUMENTS",async function main(){switch(process.argv[2]??!1){case"css-blank-pseudo":return void await cssBlankPseudo();case"css-has-pseudo":return void await cssHasPseudo();case"css-prefers-color-scheme":return void await cssPrefersColorScheme();case"postcss-attribute-case-insensitive":return void await postcssAttributeCaseInsensitive();case"postcss-cascade-layers":return void await postcssCascadeLayers();case"postcss-color-function":return void await postcssColorFunction();case"postcss-color-mix-function":return void await postcssColorMixFunction();case"postcss-color-functional-notation":return void await postcssColorFunctionalNotation();case"postcss-color-hex-alpha":return void await postcssColorHexAlpha();case"postcss-color-rebeccapurple":return void await postcssColorRebeccaPurple();case"postcss-content-alt-text":return void await postcssContentAltText();case"postcss-custom-media":return void await postcssCustomMedia();case"postcss-custom-properties":return void await postcssCustomProperties();case"postcss-custom-selectors":return void await postcssCustomSelectors();case"postcss-dir-pseudo-class":return void await postcssDirPseudoClass();case"postcss-double-position-gradients":return void await postcssDoublePositionGradients();case"postcss-exponential-functions":return void await postcssExponentialFunctions();case"postcss-focus-visible":return void await postcssFocusVisible();case"postcss-focus-within":return void await postcssFocusWithin();case"postcss-font-format-keywords":return void await postcssFontFormatKeywords();case"postcss-gap-properties":return void await postcssGapProperties();case"postcss-gradients-interpolation-method":return void await postcssGradientsInterpolationMethod();case"postcss-hwb-function":return void await postcssHWBFunction();case"postcss-ic-unit":return void await postcssICUnit();case"postcss-image-set-function":return void await postcssImageSetFunction();case"postcss-is-pseudo-class":return void await postcssIsPseudoClass();case"postcss-lab-function":return void await postcssLabFunction();case"postcss-light-dark-function":return void await postcssLightDarkFunction();case"postcss-logical":return void await postcssLogical$1();case"postcss-logical-float-and-clear":return void await postcssLogical();case"postcss-logical-resize":return void await postcssLogicalResize();case"postcss-logical-viewport-units":return void await postcssLogicalViewportUnits();case"postcss-media-minmax":return void await postcssMediaMinMax();case"postcss-media-queries-aspect-ratio-number-values":return void await postcssMediaQueriesAspectRatioNumberValues();case"postcss-nested-calc":return void await postcssNestedCalc();case"postcss-nesting":return void await postcssNesting();case"postcss-normalize-display-values":return void await postcssNormalizeDisplayValues();case"postcss-oklab-function":return void await postcssOKLabFunction();case"postcss-overflow-shorthand":return void await postcssOverflowShorthand();case"postcss-place":return void await postcssPlace();case"postcss-preset-env":return void await postcssPresetEnv();case"postcss-pseudo-class-any-link":return void await postcssPseudoClassAnyLink();case"postcss-scope-pseudo-class":return void await postcssScopePseudoClass();case"postcss-relative-color-syntax":return void await postcssRelativeColorSyntax();case"postcss-selector-not":return void await postcssSelectorNot();case"postcss-stepped-value-functions":return void await postcssSteppedValueFunctions();case"postcss-text-decoration-shorthand":return void await postcssTextDecorationShorthand();case"postcss-trigonometric-functions":return void await postcssTrigonometricFunctions();case"postcss-unset-value":return void await postcssUnsetValue();default:{const s=["CSSTools CLI\n"," Transform CSS with any plugin from https://github.com/csstools/postcss-plugins\n","Usage:"," @csstools/csstools-cli postcss-preset-env [input.css] [OPTIONS] [-o|--output output.css]"," @csstools/csstools-cli postcss-preset-env ... [OPTIONS] --dir "," @csstools/csstools-cli postcss-preset-env ... [OPTIONS] --replace","\nAvailable Plugins:"," postcss-preset-env"," css-blank-pseudo"," css-has-pseudo"," css-prefers-color-scheme"," postcss-attribute-case-insensitive"," postcss-cascade-layers"," postcss-color-function"," postcss-color-functional-notation"," postcss-color-hex-alpha"," postcss-color-mix-function"," postcss-color-rebeccapurple"," postcss-content-alt-text"," postcss-custom-media"," postcss-custom-properties"," postcss-custom-selectors"," postcss-dir-pseudo-class"," postcss-double-position-gradients"," postcss-exponential-functions"," postcss-focus-visible"," postcss-focus-within"," postcss-font-format-keywords"," postcss-gap-properties"," postcss-gradients-interpolation-method"," postcss-hwb-function"," postcss-ic-unit"," postcss-image-set-function"," postcss-is-pseudo-class"," postcss-lab-function"," postcss-light-dark-function"," postcss-logical"," postcss-logical-float-and-clear"," postcss-logical-resize"," postcss-logical-viewport-units"," postcss-media-minmax"," postcss-media-queries-aspect-ratio-number-values"," postcss-nested-calc"," postcss-nesting"," postcss-normalize-display-values"," postcss-oklab-function"," postcss-overflow-shorthand"," postcss-place"," postcss-pseudo-class-any-link"," postcss-relative-color-syntax"," postcss-scope-pseudo-class"," postcss-selector-not"," postcss-stepped-value-functions"," postcss-text-decoration-shorthand"," postcss-trigonometric-functions"," postcss-unset-value","\nPlugin Help:"," @csstools/csstools-cli "," @csstools/csstools-cli postcss-preset-env"];console.warn(s.join("\n"))}}}(); diff --git a/package-lock.json b/package-lock.json index 9bc5b63def..c325dba4fe 100644 --- a/package-lock.json +++ b/package-lock.json @@ -28,7 +28,7 @@ "devDependencies": { "@babel/core": "^7.28.4", "@babel/preset-env": "^7.28.0", - "@eslint/js": "^9.35.0", + "@eslint/js": "^9.36.0", "@microsoft/api-documenter": "^7.26.34", "@microsoft/api-extractor": "^7.52.13", "@rollup/plugin-babel": "^6.0.3", @@ -37,13 +37,13 @@ "@rollup/plugin-terser": "^0.4.3", "@rollup/plugin-typescript": "^12.1.4", "@stryker-mutator/core": "^9.1.1", - "eslint": "^9.35.0", + "eslint": "^9.36.0", "globals": "^16.4.0", "knip": "^5.63.1", - "rollup": "^4.50.1", + "rollup": "^4.52.0", "tslib": "^2.8.0", "typescript": "^5.8.3", - "typescript-eslint": "^8.43.0" + "typescript-eslint": "^8.44.0" }, "engines": { "node": "^14 || ^16 || >=18" @@ -2342,9 +2342,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.35.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.35.0.tgz", - "integrity": "sha512-30iXE9whjlILfWobBkNerJo+TXYsgVM5ERQwMcMKCHckHflCmf7wXDAHlARoWnh0s1U72WqlbeyE7iAcCzuCPw==", + "version": "9.36.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.36.0.tgz", + "integrity": "sha512-uhCbYtYynH30iZErszX78U+nR3pJU3RHGQ57NXy5QupD4SBVwDeU8TNBy+MjMngc1UyIW9noKqsRqfjQTBU2dw==", "dev": true, "license": "MIT", "engines": { @@ -3346,13 +3346,13 @@ ] }, "node_modules/@puppeteer/browsers": { - "version": "2.10.9", - "resolved": "https://registry.npmjs.org/@puppeteer/browsers/-/browsers-2.10.9.tgz", - "integrity": "sha512-kUGHwABarVhvMP+zhW5zvDA7LmGcd4TwrTEBwcTQic5EebUqaK5NjC0UXLJepIFVGsr2N/Z8NJQz2JYGo1ZwxA==", + "version": "2.10.10", + "resolved": "https://registry.npmjs.org/@puppeteer/browsers/-/browsers-2.10.10.tgz", + "integrity": "sha512-3ZG500+ZeLql8rE0hjfhkycJjDj0pI/btEh3L9IkWUYcOrgP0xCNRq3HbtbqOPbvDhFaAWD88pDFtlLv8ns8gA==", "dev": true, "license": "Apache-2.0", "dependencies": { - "debug": "^4.4.1", + "debug": "^4.4.3", "extract-zip": "^2.0.1", "progress": "^2.0.3", "proxy-agent": "^6.5.0", @@ -3554,9 +3554,9 @@ } }, "node_modules/@rollup/rollup-android-arm-eabi": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.50.1.tgz", - "integrity": "sha512-HJXwzoZN4eYTdD8bVV22DN8gsPCAj3V20NHKOs8ezfXanGpmVPR7kalUHd+Y31IJp9stdB87VKPFbsGY3H/2ag==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.52.0.tgz", + "integrity": "sha512-VxDYCDqOaR7NXzAtvRx7G1u54d2kEHopb28YH/pKzY6y0qmogP3gG7CSiWsq9WvDFxOQMpNEyjVAHZFXfH3o/A==", "cpu": [ "arm" ], @@ -3568,9 +3568,9 @@ ] }, "node_modules/@rollup/rollup-android-arm64": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.50.1.tgz", - "integrity": "sha512-PZlsJVcjHfcH53mOImyt3bc97Ep3FJDXRpk9sMdGX0qgLmY0EIWxCag6EigerGhLVuL8lDVYNnSo8qnTElO4xw==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.52.0.tgz", + "integrity": "sha512-pqDirm8koABIKvzL59YI9W9DWbRlTX7RWhN+auR8HXJxo89m4mjqbah7nJZjeKNTNYopqL+yGg+0mhCpf3xZtQ==", "cpu": [ "arm64" ], @@ -3582,9 +3582,9 @@ ] }, "node_modules/@rollup/rollup-darwin-arm64": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.50.1.tgz", - "integrity": "sha512-xc6i2AuWh++oGi4ylOFPmzJOEeAa2lJeGUGb4MudOtgfyyjr4UPNK+eEWTPLvmPJIY/pgw6ssFIox23SyrkkJw==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.52.0.tgz", + "integrity": "sha512-YCdWlY/8ltN6H78HnMsRHYlPiKvqKagBP1r+D7SSylxX+HnsgXGCmLiV3Y4nSyY9hW8qr8U9LDUx/Lo7M6MfmQ==", "cpu": [ "arm64" ], @@ -3596,9 +3596,9 @@ ] }, "node_modules/@rollup/rollup-darwin-x64": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.50.1.tgz", - "integrity": "sha512-2ofU89lEpDYhdLAbRdeyz/kX3Y2lpYc6ShRnDjY35bZhd2ipuDMDi6ZTQ9NIag94K28nFMofdnKeHR7BT0CATw==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.52.0.tgz", + "integrity": "sha512-z4nw6y1j+OOSGzuVbSWdIp1IUks9qNw4dc7z7lWuWDKojY38VMWBlEN7F9jk5UXOkUcp97vA1N213DF+Lz8BRg==", "cpu": [ "x64" ], @@ -3610,9 +3610,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-arm64": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.50.1.tgz", - "integrity": "sha512-wOsE6H2u6PxsHY/BeFHA4VGQN3KUJFZp7QJBmDYI983fgxq5Th8FDkVuERb2l9vDMs1D5XhOrhBrnqcEY6l8ZA==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-arm64/-/rollup-freebsd-arm64-4.52.0.tgz", + "integrity": "sha512-Q/dv9Yvyr5rKlK8WQJZVrp5g2SOYeZUs9u/t2f9cQ2E0gJjYB/BWoedXfUT0EcDJefi2zzVfhcOj8drWCzTviw==", "cpu": [ "arm64" ], @@ -3624,9 +3624,9 @@ ] }, "node_modules/@rollup/rollup-freebsd-x64": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.50.1.tgz", - "integrity": "sha512-A/xeqaHTlKbQggxCqispFAcNjycpUEHP52mwMQZUNqDUJFFYtPHCXS1VAG29uMlDzIVr+i00tSFWFLivMcoIBQ==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-freebsd-x64/-/rollup-freebsd-x64-4.52.0.tgz", + "integrity": "sha512-kdBsLs4Uile/fbjZVvCRcKB4q64R+1mUq0Yd7oU1CMm1Av336ajIFqNFovByipciuUQjBCPMxwJhCgfG2re3rg==", "cpu": [ "x64" ], @@ -3638,9 +3638,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-gnueabihf": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.50.1.tgz", - "integrity": "sha512-54v4okehwl5TaSIkpp97rAHGp7t3ghinRd/vyC1iXqXMfjYUTm7TfYmCzXDoHUPTTf36L8pr0E7YsD3CfB3ZDg==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.52.0.tgz", + "integrity": "sha512-aL6hRwu0k7MTUESgkg7QHY6CoqPgr6gdQXRJI1/VbFlUMwsSzPGSR7sG5d+MCbYnJmJwThc2ol3nixj1fvI/zQ==", "cpu": [ "arm" ], @@ -3652,9 +3652,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm-musleabihf": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.50.1.tgz", - "integrity": "sha512-p/LaFyajPN/0PUHjv8TNyxLiA7RwmDoVY3flXHPSzqrGcIp/c2FjwPPP5++u87DGHtw+5kSH5bCJz0mvXngYxw==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm-musleabihf/-/rollup-linux-arm-musleabihf-4.52.0.tgz", + "integrity": "sha512-BTs0M5s1EJejgIBJhCeiFo7GZZ2IXWkFGcyZhxX4+8usnIo5Mti57108vjXFIQmmJaRyDwmV59Tw64Ap1dkwMw==", "cpu": [ "arm" ], @@ -3666,9 +3666,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-gnu": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.50.1.tgz", - "integrity": "sha512-2AbMhFFkTo6Ptna1zO7kAXXDLi7H9fGTbVaIq2AAYO7yzcAsuTNWPHhb2aTA6GPiP+JXh85Y8CiS54iZoj4opw==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.52.0.tgz", + "integrity": "sha512-uj672IVOU9m08DBGvoPKPi/J8jlVgjh12C9GmjjBxCTQc3XtVmRkRKyeHSmIKQpvJ7fIm1EJieBUcnGSzDVFyw==", "cpu": [ "arm64" ], @@ -3680,9 +3680,9 @@ ] }, "node_modules/@rollup/rollup-linux-arm64-musl": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.50.1.tgz", - "integrity": "sha512-Cgef+5aZwuvesQNw9eX7g19FfKX5/pQRIyhoXLCiBOrWopjo7ycfB292TX9MDcDijiuIJlx1IzJz3IoCPfqs9w==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.52.0.tgz", + "integrity": "sha512-/+IVbeDMDCtB/HP/wiWsSzduD10SEGzIZX2945KSgZRNi4TSkjHqRJtNTVtVb8IRwhJ65ssI56krlLik+zFWkw==", "cpu": [ "arm64" ], @@ -3693,10 +3693,10 @@ "linux" ] }, - "node_modules/@rollup/rollup-linux-loongarch64-gnu": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loongarch64-gnu/-/rollup-linux-loongarch64-gnu-4.50.1.tgz", - "integrity": "sha512-RPhTwWMzpYYrHrJAS7CmpdtHNKtt2Ueo+BlLBjfZEhYBhK00OsEqM08/7f+eohiF6poe0YRDDd8nAvwtE/Y62Q==", + "node_modules/@rollup/rollup-linux-loong64-gnu": { + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-loong64-gnu/-/rollup-linux-loong64-gnu-4.52.0.tgz", + "integrity": "sha512-U1vVzvSWtSMWKKrGoROPBXMh3Vwn93TA9V35PldokHGqiUbF6erSzox/5qrSMKp6SzakvyjcPiVF8yB1xKr9Pg==", "cpu": [ "loong64" ], @@ -3708,9 +3708,9 @@ ] }, "node_modules/@rollup/rollup-linux-ppc64-gnu": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.50.1.tgz", - "integrity": "sha512-eSGMVQw9iekut62O7eBdbiccRguuDgiPMsw++BVUg+1K7WjZXHOg/YOT9SWMzPZA+w98G+Fa1VqJgHZOHHnY0Q==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-ppc64-gnu/-/rollup-linux-ppc64-gnu-4.52.0.tgz", + "integrity": "sha512-X/4WfuBAdQRH8cK3DYl8zC00XEE6aM472W+QCycpQJeLWVnHfkv7RyBFVaTqNUMsTgIX8ihMjCvFF9OUgeABzw==", "cpu": [ "ppc64" ], @@ -3722,9 +3722,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-gnu": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.50.1.tgz", - "integrity": "sha512-S208ojx8a4ciIPrLgazF6AgdcNJzQE4+S9rsmOmDJkusvctii+ZvEuIC4v/xFqzbuP8yDjn73oBlNDgF6YGSXQ==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.52.0.tgz", + "integrity": "sha512-xIRYc58HfWDBZoLmWfWXg2Sq8VCa2iJ32B7mqfWnkx5mekekl0tMe7FHpY8I72RXEcUkaWawRvl3qA55og+cwQ==", "cpu": [ "riscv64" ], @@ -3736,9 +3736,9 @@ ] }, "node_modules/@rollup/rollup-linux-riscv64-musl": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.50.1.tgz", - "integrity": "sha512-3Ag8Ls1ggqkGUvSZWYcdgFwriy2lWo+0QlYgEFra/5JGtAd6C5Hw59oojx1DeqcA2Wds2ayRgvJ4qxVTzCHgzg==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-riscv64-musl/-/rollup-linux-riscv64-musl-4.52.0.tgz", + "integrity": "sha512-mbsoUey05WJIOz8U1WzNdf+6UMYGwE3fZZnQqsM22FZ3wh1N887HT6jAOjXs6CNEK3Ntu2OBsyQDXfIjouI4dw==", "cpu": [ "riscv64" ], @@ -3750,9 +3750,9 @@ ] }, "node_modules/@rollup/rollup-linux-s390x-gnu": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.50.1.tgz", - "integrity": "sha512-t9YrKfaxCYe7l7ldFERE1BRg/4TATxIg+YieHQ966jwvo7ddHJxPj9cNFWLAzhkVsbBvNA4qTbPVNsZKBO4NSg==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-s390x-gnu/-/rollup-linux-s390x-gnu-4.52.0.tgz", + "integrity": "sha512-qP6aP970bucEi5KKKR4AuPFd8aTx9EF6BvutvYxmZuWLJHmnq4LvBfp0U+yFDMGwJ+AIJEH5sIP+SNypauMWzg==", "cpu": [ "s390x" ], @@ -3764,9 +3764,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-gnu": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.50.1.tgz", - "integrity": "sha512-MCgtFB2+SVNuQmmjHf+wfI4CMxy3Tk8XjA5Z//A0AKD7QXUYFMQcns91K6dEHBvZPCnhJSyDWLApk40Iq/H3tA==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.52.0.tgz", + "integrity": "sha512-nmSVN+F2i1yKZ7rJNKO3G7ZzmxJgoQBQZ/6c4MuS553Grmr7WqR7LLDcYG53Z2m9409z3JLt4sCOhLdbKQ3HmA==", "cpu": [ "x64" ], @@ -3778,9 +3778,9 @@ ] }, "node_modules/@rollup/rollup-linux-x64-musl": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.50.1.tgz", - "integrity": "sha512-nEvqG+0jeRmqaUMuwzlfMKwcIVffy/9KGbAGyoa26iu6eSngAYQ512bMXuqqPrlTyfqdlB9FVINs93j534UJrg==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.52.0.tgz", + "integrity": "sha512-2d0qRo33G6TfQVjaMR71P+yJVGODrt5V6+T0BDYH4EMfGgdC/2HWDVjSSFw888GSzAZUwuska3+zxNUCDco6rQ==", "cpu": [ "x64" ], @@ -3792,9 +3792,9 @@ ] }, "node_modules/@rollup/rollup-openharmony-arm64": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.50.1.tgz", - "integrity": "sha512-RDsLm+phmT3MJd9SNxA9MNuEAO/J2fhW8GXk62G/B4G7sLVumNFbRwDL6v5NrESb48k+QMqdGbHgEtfU0LCpbA==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-openharmony-arm64/-/rollup-openharmony-arm64-4.52.0.tgz", + "integrity": "sha512-A1JalX4MOaFAAyGgpO7XP5khquv/7xKzLIyLmhNrbiCxWpMlnsTYr8dnsWM7sEeotNmxvSOEL7F65j0HXFcFsw==", "cpu": [ "arm64" ], @@ -3806,9 +3806,9 @@ ] }, "node_modules/@rollup/rollup-win32-arm64-msvc": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.50.1.tgz", - "integrity": "sha512-hpZB/TImk2FlAFAIsoElM3tLzq57uxnGYwplg6WDyAxbYczSi8O2eQ+H2Lx74504rwKtZ3N2g4bCUkiamzS6TQ==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.52.0.tgz", + "integrity": "sha512-YQugafP/rH0eOOHGjmNgDURrpYHrIX0yuojOI8bwCyXwxC9ZdTd3vYkmddPX0oHONLXu9Rb1dDmT0VNpjkzGGw==", "cpu": [ "arm64" ], @@ -3820,9 +3820,9 @@ ] }, "node_modules/@rollup/rollup-win32-ia32-msvc": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.50.1.tgz", - "integrity": "sha512-SXjv8JlbzKM0fTJidX4eVsH+Wmnp0/WcD8gJxIZyR6Gay5Qcsmdbi9zVtnbkGPG8v2vMR1AD06lGWy5FLMcG7A==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.52.0.tgz", + "integrity": "sha512-zYdUYhi3Qe2fndujBqL5FjAFzvNeLxtIqfzNEVKD1I7C37/chv1VxhscWSQHTNfjPCrBFQMnynwA3kpZpZ8w4A==", "cpu": [ "ia32" ], @@ -3833,10 +3833,24 @@ "win32" ] }, + "node_modules/@rollup/rollup-win32-x64-gnu": { + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-gnu/-/rollup-win32-x64-gnu-4.52.0.tgz", + "integrity": "sha512-fGk03kQylNaCOQ96HDMeT7E2n91EqvCDd3RwvT5k+xNdFCeMGnj5b5hEgTGrQuyidqSsD3zJDQ21QIaxXqTBJw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ] + }, "node_modules/@rollup/rollup-win32-x64-msvc": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.50.1.tgz", - "integrity": "sha512-StxAO/8ts62KZVRAm4JZYq9+NqNsV7RvimNK+YM7ry//zebEH6meuugqW/P5OFUCjyQgui+9fUxT6d5NShvMvA==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.52.0.tgz", + "integrity": "sha512-6iKDCVSIUQ8jPMoIV0OytRKniaYyy5EbY/RRydmLW8ZR3cEBhxbWl5ro0rkUNe0ef6sScvhbY79HrjRm8i3vDQ==", "cpu": [ "x64" ], @@ -4197,17 +4211,17 @@ } }, "node_modules/@typescript-eslint/eslint-plugin": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.43.0.tgz", - "integrity": "sha512-8tg+gt7ENL7KewsKMKDHXR1vm8tt9eMxjJBYINf6swonlWgkYn5NwyIgXpbbDxTNU5DgpDFfj95prcTq2clIQQ==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-8.44.0.tgz", + "integrity": "sha512-EGDAOGX+uwwekcS0iyxVDmRV9HX6FLSM5kzrAToLTsr9OWCIKG/y3lQheCq18yZ5Xh78rRKJiEpP0ZaCs4ryOQ==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/regexpp": "^4.10.0", - "@typescript-eslint/scope-manager": "8.43.0", - "@typescript-eslint/type-utils": "8.43.0", - "@typescript-eslint/utils": "8.43.0", - "@typescript-eslint/visitor-keys": "8.43.0", + "@typescript-eslint/scope-manager": "8.44.0", + "@typescript-eslint/type-utils": "8.44.0", + "@typescript-eslint/utils": "8.44.0", + "@typescript-eslint/visitor-keys": "8.44.0", "graphemer": "^1.4.0", "ignore": "^7.0.0", "natural-compare": "^1.4.0", @@ -4221,7 +4235,7 @@ "url": "https://opencollective.com/typescript-eslint" }, "peerDependencies": { - "@typescript-eslint/parser": "^8.43.0", + "@typescript-eslint/parser": "^8.44.0", "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } @@ -4237,16 +4251,16 @@ } }, "node_modules/@typescript-eslint/parser": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.43.0.tgz", - "integrity": "sha512-B7RIQiTsCBBmY+yW4+ILd6mF5h1FUwJsVvpqkrgpszYifetQ2Ke+Z4u6aZh0CblkUGIdR59iYVyXqqZGkZ3aBw==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-8.44.0.tgz", + "integrity": "sha512-VGMpFQGUQWYT9LfnPcX8ouFojyrZ/2w3K5BucvxL/spdNehccKhB4jUyB1yBCXpr2XFm0jkECxgrpXBW2ipoAw==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/scope-manager": "8.43.0", - "@typescript-eslint/types": "8.43.0", - "@typescript-eslint/typescript-estree": "8.43.0", - "@typescript-eslint/visitor-keys": "8.43.0", + "@typescript-eslint/scope-manager": "8.44.0", + "@typescript-eslint/types": "8.44.0", + "@typescript-eslint/typescript-estree": "8.44.0", + "@typescript-eslint/visitor-keys": "8.44.0", "debug": "^4.3.4" }, "engines": { @@ -4262,14 +4276,14 @@ } }, "node_modules/@typescript-eslint/project-service": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.43.0.tgz", - "integrity": "sha512-htB/+D/BIGoNTQYffZw4uM4NzzuolCoaA/BusuSIcC8YjmBYQioew5VUZAYdAETPjeed0hqCaW7EHg+Robq8uw==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/project-service/-/project-service-8.44.0.tgz", + "integrity": "sha512-ZeaGNraRsq10GuEohKTo4295Z/SuGcSq2LzfGlqiuEvfArzo/VRrT0ZaJsVPuKZ55lVbNk8U6FcL+ZMH8CoyVA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/tsconfig-utils": "^8.43.0", - "@typescript-eslint/types": "^8.43.0", + "@typescript-eslint/tsconfig-utils": "^8.44.0", + "@typescript-eslint/types": "^8.44.0", "debug": "^4.3.4" }, "engines": { @@ -4284,14 +4298,14 @@ } }, "node_modules/@typescript-eslint/scope-manager": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.43.0.tgz", - "integrity": "sha512-daSWlQ87ZhsjrbMLvpuuMAt3y4ba57AuvadcR7f3nl8eS3BjRc8L9VLxFLk92RL5xdXOg6IQ+qKjjqNEimGuAg==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-8.44.0.tgz", + "integrity": "sha512-87Jv3E+al8wpD+rIdVJm/ItDBe/Im09zXIjFoipOjr5gHUhJmTzfFLuTJ/nPTMc2Srsroy4IBXwcTCHyRR7KzA==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.43.0", - "@typescript-eslint/visitor-keys": "8.43.0" + "@typescript-eslint/types": "8.44.0", + "@typescript-eslint/visitor-keys": "8.44.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4302,9 +4316,9 @@ } }, "node_modules/@typescript-eslint/tsconfig-utils": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.43.0.tgz", - "integrity": "sha512-ALC2prjZcj2YqqL5X/bwWQmHA2em6/94GcbB/KKu5SX3EBDOsqztmmX1kMkvAJHzxk7TazKzJfFiEIagNV3qEA==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/tsconfig-utils/-/tsconfig-utils-8.44.0.tgz", + "integrity": "sha512-x5Y0+AuEPqAInc6yd0n5DAcvtoQ/vyaGwuX5HE9n6qAefk1GaedqrLQF8kQGylLUb9pnZyLf+iEiL9fr8APDtQ==", "dev": true, "license": "MIT", "engines": { @@ -4319,15 +4333,15 @@ } }, "node_modules/@typescript-eslint/type-utils": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.43.0.tgz", - "integrity": "sha512-qaH1uLBpBuBBuRf8c1mLJ6swOfzCXryhKND04Igr4pckzSEW9JX5Aw9AgW00kwfjWJF0kk0ps9ExKTfvXfw4Qg==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-8.44.0.tgz", + "integrity": "sha512-9cwsoSxJ8Sak67Be/hD2RNt/fsqmWnNE1iHohG8lxqLSNY8xNfyY7wloo5zpW3Nu9hxVgURevqfcH6vvKCt6yg==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.43.0", - "@typescript-eslint/typescript-estree": "8.43.0", - "@typescript-eslint/utils": "8.43.0", + "@typescript-eslint/types": "8.44.0", + "@typescript-eslint/typescript-estree": "8.44.0", + "@typescript-eslint/utils": "8.44.0", "debug": "^4.3.4", "ts-api-utils": "^2.1.0" }, @@ -4344,9 +4358,9 @@ } }, "node_modules/@typescript-eslint/types": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.43.0.tgz", - "integrity": "sha512-vQ2FZaxJpydjSZJKiSW/LJsabFFvV7KgLC5DiLhkBcykhQj8iK9BOaDmQt74nnKdLvceM5xmhaTF+pLekrxEkw==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-8.44.0.tgz", + "integrity": "sha512-ZSl2efn44VsYM0MfDQe68RKzBz75NPgLQXuGypmym6QVOWL5kegTZuZ02xRAT9T+onqvM6T8CdQk0OwYMB6ZvA==", "dev": true, "license": "MIT", "engines": { @@ -4358,16 +4372,16 @@ } }, "node_modules/@typescript-eslint/typescript-estree": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.43.0.tgz", - "integrity": "sha512-7Vv6zlAhPb+cvEpP06WXXy/ZByph9iL6BQRBDj4kmBsW98AqEeQHlj/13X+sZOrKSo9/rNKH4Ul4f6EICREFdw==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-8.44.0.tgz", + "integrity": "sha512-lqNj6SgnGcQZwL4/SBJ3xdPEfcBuhCG8zdcwCPgYcmiPLgokiNDKlbPzCwEwu7m279J/lBYWtDYL+87OEfn8Jw==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/project-service": "8.43.0", - "@typescript-eslint/tsconfig-utils": "8.43.0", - "@typescript-eslint/types": "8.43.0", - "@typescript-eslint/visitor-keys": "8.43.0", + "@typescript-eslint/project-service": "8.44.0", + "@typescript-eslint/tsconfig-utils": "8.44.0", + "@typescript-eslint/types": "8.44.0", + "@typescript-eslint/visitor-keys": "8.44.0", "debug": "^4.3.4", "fast-glob": "^3.3.2", "is-glob": "^4.0.3", @@ -4426,16 +4440,16 @@ } }, "node_modules/@typescript-eslint/utils": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.43.0.tgz", - "integrity": "sha512-S1/tEmkUeeswxd0GGcnwuVQPFWo8NzZTOMxCvw8BX7OMxnNae+i8Tm7REQen/SwUIPoPqfKn7EaZ+YLpiB3k9g==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-8.44.0.tgz", + "integrity": "sha512-nktOlVcg3ALo0mYlV+L7sWUD58KG4CMj1rb2HUVOO4aL3K/6wcD+NERqd0rrA5Vg06b42YhF6cFxeixsp9Riqg==", "dev": true, "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.7.0", - "@typescript-eslint/scope-manager": "8.43.0", - "@typescript-eslint/types": "8.43.0", - "@typescript-eslint/typescript-estree": "8.43.0" + "@typescript-eslint/scope-manager": "8.44.0", + "@typescript-eslint/types": "8.44.0", + "@typescript-eslint/typescript-estree": "8.44.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -4450,13 +4464,13 @@ } }, "node_modules/@typescript-eslint/visitor-keys": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.43.0.tgz", - "integrity": "sha512-T+S1KqRD4sg/bHfLwrpF/K3gQLBM1n7Rp7OjjikjTEssI2YJzQpi5WXoynOaQ93ERIuq3O8RBTOUYDKszUCEHw==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-8.44.0.tgz", + "integrity": "sha512-zaz9u8EJ4GBmnehlrpoKvj/E3dNbuQ7q0ucyZImm3cLqJ8INTc970B1qEqDX/Rzq65r3TvVTN7kHWPBoyW7DWw==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/types": "8.43.0", + "@typescript-eslint/types": "8.44.0", "eslint-visitor-keys": "^4.2.1" }, "engines": { @@ -4693,9 +4707,9 @@ } }, "node_modules/b4a": { - "version": "1.7.1", - "resolved": "https://registry.npmjs.org/b4a/-/b4a-1.7.1.tgz", - "integrity": "sha512-ZovbrBV0g6JxK5cGUF1Suby1vLfKjv4RWi8IxoaO/Mon8BDD9I21RxjHFtgQ+kskJqLAVyQZly3uMBui+vhc8Q==", + "version": "1.7.3", + "resolved": "https://registry.npmjs.org/b4a/-/b4a-1.7.3.tgz", + "integrity": "sha512-5Q2mfq2WfGuFp3uS//0s6baOJLMoVduPYVeNmDYxu5OUA1/cBfvr2RIS7vi62LdNj/urk1hfmj867I3qt6uZ7Q==", "dev": true, "license": "Apache-2.0", "peerDependencies": { @@ -4761,13 +4775,12 @@ "resolved": "https://registry.npmjs.org/bare-events/-/bare-events-2.7.0.tgz", "integrity": "sha512-b3N5eTW1g7vXkw+0CXh/HazGTcO5KYuu/RCNaJbDMPI6LHDi+7qe8EmxKUVe1sUbY2KZOVZFyj62x0OEz9qyAA==", "dev": true, - "license": "Apache-2.0", - "optional": true + "license": "Apache-2.0" }, "node_modules/bare-fs": { - "version": "4.4.4", - "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-4.4.4.tgz", - "integrity": "sha512-Q8yxM1eLhJfuM7KXVP3zjhBvtMJCYRByoTT+wHXjpdMELv0xICFJX+1w4c7csa+WZEOsq4ItJ4RGwvzid6m/dw==", + "version": "4.4.5", + "resolved": "https://registry.npmjs.org/bare-fs/-/bare-fs-4.4.5.tgz", + "integrity": "sha512-TCtu93KGLu6/aiGWzMr12TmSRS6nKdfhAnzTQRbXoSWxkbb9eRd53jQ51jG7g1gYjjtto3hbBrrhzg6djcgiKg==", "dev": true, "license": "Apache-2.0", "optional": true, @@ -5314,9 +5327,9 @@ } }, "node_modules/debug": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.1.tgz", - "integrity": "sha512-KcKCqiftBJcZr++7ykoDIEwSa3XWowTfNPo92BYxjXiyYEVrUQh2aLyhxBCwww+heortUFxEJYcRzosstTEBYQ==", + "version": "4.4.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", + "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", "dev": true, "license": "MIT", "dependencies": { @@ -5537,9 +5550,9 @@ } }, "node_modules/eslint": { - "version": "9.35.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.35.0.tgz", - "integrity": "sha512-QePbBFMJFjgmlE+cXAlbHZbHpdFVS2E/6vzCy7aKlebddvl1vadiC4JFV5u/wqTkNUwEV8WrQi257jf5f06hrg==", + "version": "9.36.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.36.0.tgz", + "integrity": "sha512-hB4FIzXovouYzwzECDcUkJ4OcfOEkXTv2zRY6B9bkwjx/cprAq0uvm1nl7zvQ0/TsUk0zQiN4uPfJpB9m+rPMQ==", "dev": true, "license": "MIT", "dependencies": { @@ -5549,7 +5562,7 @@ "@eslint/config-helpers": "^0.3.1", "@eslint/core": "^0.15.2", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.35.0", + "@eslint/js": "9.36.0", "@eslint/plugin-kit": "^0.3.5", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", @@ -5779,6 +5792,16 @@ "node": ">=0.10.0" } }, + "node_modules/events-universal": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/events-universal/-/events-universal-1.0.1.tgz", + "integrity": "sha512-LUd5euvbMLpwOF8m6ivPCbhQeSiYVNb8Vs0fQ8QjXo0JTkEHpz8pxdQf0gStltaPpw0Cca8b39KxvK9cfKRiAw==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "bare-events": "^2.7.0" + } + }, "node_modules/execa": { "version": "9.6.0", "resolved": "https://registry.npmjs.org/execa/-/execa-9.6.0.tgz", @@ -7926,18 +7949,18 @@ } }, "node_modules/puppeteer": { - "version": "24.20.0", - "resolved": "https://registry.npmjs.org/puppeteer/-/puppeteer-24.20.0.tgz", - "integrity": "sha512-iLnLV9oHKKAujmxiSxRWKfcT1q2COu0g1N9iU2TCp1MlmsyjgNAkcBOR3cAOqKb5UTiVPIGG4z5PO5yfpYZ6jA==", + "version": "24.22.0", + "resolved": "https://registry.npmjs.org/puppeteer/-/puppeteer-24.22.0.tgz", + "integrity": "sha512-QabGIvu7F0hAMiKGHZCIRHMb6UoH0QAJA2OaqxEU2tL5noXPrxUcotg2l3ttOA4p1PFnVIGkr6PXRAWlM2evVQ==", "dev": true, "hasInstallScript": true, "license": "Apache-2.0", "dependencies": { - "@puppeteer/browsers": "2.10.9", + "@puppeteer/browsers": "2.10.10", "chromium-bidi": "8.0.0", "cosmiconfig": "^9.0.0", "devtools-protocol": "0.0.1495869", - "puppeteer-core": "24.20.0", + "puppeteer-core": "24.22.0", "typed-query-selector": "^2.12.0" }, "bin": { @@ -7948,18 +7971,18 @@ } }, "node_modules/puppeteer-core": { - "version": "24.20.0", - "resolved": "https://registry.npmjs.org/puppeteer-core/-/puppeteer-core-24.20.0.tgz", - "integrity": "sha512-n0y/f8EYyZt4yEJkjP3Vrqf9A4qa3uYpKYdsiedIY4bxIfTw1aAJSpSVPmWBPlr1LO4cNq2hGNIBWKPhvBF68w==", + "version": "24.22.0", + "resolved": "https://registry.npmjs.org/puppeteer-core/-/puppeteer-core-24.22.0.tgz", + "integrity": "sha512-oUeWlIg0pMz8YM5pu0uqakM+cCyYyXkHBxx9di9OUELu9X9+AYrNGGRLK9tNME3WfN3JGGqQIH3b4/E9LGek/w==", "dev": true, "license": "Apache-2.0", "dependencies": { - "@puppeteer/browsers": "2.10.9", + "@puppeteer/browsers": "2.10.10", "chromium-bidi": "8.0.0", - "debug": "^4.4.1", + "debug": "^4.4.3", "devtools-protocol": "0.0.1495869", "typed-query-selector": "^2.12.0", - "webdriver-bidi-protocol": "0.2.8", + "webdriver-bidi-protocol": "0.2.11", "ws": "^8.18.3" }, "engines": { @@ -8157,9 +8180,9 @@ } }, "node_modules/rollup": { - "version": "4.50.1", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.50.1.tgz", - "integrity": "sha512-78E9voJHwnXQMiQdiqswVLZwJIzdBKJ1GdI5Zx6XwoFKUIk09/sSrr+05QFzvYb8q6Y9pPV45zzDuYa3907TZA==", + "version": "4.52.0", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-4.52.0.tgz", + "integrity": "sha512-+IuescNkTJQgX7AkIDtITipZdIGcWF0pnVvZTWStiazUmcGA2ag8dfg0urest2XlXUi9kuhfQ+qmdc5Stc3z7g==", "dev": true, "license": "MIT", "dependencies": { @@ -8173,27 +8196,28 @@ "npm": ">=8.0.0" }, "optionalDependencies": { - "@rollup/rollup-android-arm-eabi": "4.50.1", - "@rollup/rollup-android-arm64": "4.50.1", - "@rollup/rollup-darwin-arm64": "4.50.1", - "@rollup/rollup-darwin-x64": "4.50.1", - "@rollup/rollup-freebsd-arm64": "4.50.1", - "@rollup/rollup-freebsd-x64": "4.50.1", - "@rollup/rollup-linux-arm-gnueabihf": "4.50.1", - "@rollup/rollup-linux-arm-musleabihf": "4.50.1", - "@rollup/rollup-linux-arm64-gnu": "4.50.1", - "@rollup/rollup-linux-arm64-musl": "4.50.1", - "@rollup/rollup-linux-loongarch64-gnu": "4.50.1", - "@rollup/rollup-linux-ppc64-gnu": "4.50.1", - "@rollup/rollup-linux-riscv64-gnu": "4.50.1", - "@rollup/rollup-linux-riscv64-musl": "4.50.1", - "@rollup/rollup-linux-s390x-gnu": "4.50.1", - "@rollup/rollup-linux-x64-gnu": "4.50.1", - "@rollup/rollup-linux-x64-musl": "4.50.1", - "@rollup/rollup-openharmony-arm64": "4.50.1", - "@rollup/rollup-win32-arm64-msvc": "4.50.1", - "@rollup/rollup-win32-ia32-msvc": "4.50.1", - "@rollup/rollup-win32-x64-msvc": "4.50.1", + "@rollup/rollup-android-arm-eabi": "4.52.0", + "@rollup/rollup-android-arm64": "4.52.0", + "@rollup/rollup-darwin-arm64": "4.52.0", + "@rollup/rollup-darwin-x64": "4.52.0", + "@rollup/rollup-freebsd-arm64": "4.52.0", + "@rollup/rollup-freebsd-x64": "4.52.0", + "@rollup/rollup-linux-arm-gnueabihf": "4.52.0", + "@rollup/rollup-linux-arm-musleabihf": "4.52.0", + "@rollup/rollup-linux-arm64-gnu": "4.52.0", + "@rollup/rollup-linux-arm64-musl": "4.52.0", + "@rollup/rollup-linux-loong64-gnu": "4.52.0", + "@rollup/rollup-linux-ppc64-gnu": "4.52.0", + "@rollup/rollup-linux-riscv64-gnu": "4.52.0", + "@rollup/rollup-linux-riscv64-musl": "4.52.0", + "@rollup/rollup-linux-s390x-gnu": "4.52.0", + "@rollup/rollup-linux-x64-gnu": "4.52.0", + "@rollup/rollup-linux-x64-musl": "4.52.0", + "@rollup/rollup-openharmony-arm64": "4.52.0", + "@rollup/rollup-win32-arm64-msvc": "4.52.0", + "@rollup/rollup-win32-ia32-msvc": "4.52.0", + "@rollup/rollup-win32-x64-gnu": "4.52.0", + "@rollup/rollup-win32-x64-msvc": "4.52.0", "fsevents": "~2.3.2" } }, @@ -8518,17 +8542,15 @@ "license": "BSD-3-Clause" }, "node_modules/streamx": { - "version": "2.22.1", - "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.22.1.tgz", - "integrity": "sha512-znKXEBxfatz2GBNK02kRnCXjV+AA4kjZIUxeWSr3UGirZMJfTE9uiwKHobnbgxWyL/JWro8tTq+vOqAK1/qbSA==", + "version": "2.23.0", + "resolved": "https://registry.npmjs.org/streamx/-/streamx-2.23.0.tgz", + "integrity": "sha512-kn+e44esVfn2Fa/O0CPFcex27fjIL6MkVae0Mm6q+E6f0hWv578YCERbv+4m02cjxvDsPKLnmxral/rR6lBMAg==", "dev": true, "license": "MIT", "dependencies": { + "events-universal": "^1.0.0", "fast-fifo": "^1.3.2", "text-decoder": "^1.1.0" - }, - "optionalDependencies": { - "bare-events": "^2.2.0" } }, "node_modules/string-argv": { @@ -9017,16 +9039,16 @@ } }, "node_modules/typescript-eslint": { - "version": "8.43.0", - "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.43.0.tgz", - "integrity": "sha512-FyRGJKUGvcFekRRcBKFBlAhnp4Ng8rhe8tuvvkR9OiU0gfd4vyvTRQHEckO6VDlH57jbeUQem2IpqPq9kLJH+w==", + "version": "8.44.0", + "resolved": "https://registry.npmjs.org/typescript-eslint/-/typescript-eslint-8.44.0.tgz", + "integrity": "sha512-ib7mCkYuIzYonCq9XWF5XNw+fkj2zg629PSa9KNIQ47RXFF763S5BIX4wqz1+FLPogTZoiw8KmCiRPRa8bL3qw==", "dev": true, "license": "MIT", "dependencies": { - "@typescript-eslint/eslint-plugin": "8.43.0", - "@typescript-eslint/parser": "8.43.0", - "@typescript-eslint/typescript-estree": "8.43.0", - "@typescript-eslint/utils": "8.43.0" + "@typescript-eslint/eslint-plugin": "8.44.0", + "@typescript-eslint/parser": "8.44.0", + "@typescript-eslint/typescript-estree": "8.44.0", + "@typescript-eslint/utils": "8.44.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -9185,9 +9207,9 @@ "license": "Apache-2.0" }, "node_modules/webdriver-bidi-protocol": { - "version": "0.2.8", - "resolved": "https://registry.npmjs.org/webdriver-bidi-protocol/-/webdriver-bidi-protocol-0.2.8.tgz", - "integrity": "sha512-KPvtVAIX8VHjLZH1KHT5GXoOaPeb0Ju+JlAcdshw6Z/gsmRtLoxt0Hw99PgJwZta7zUQaAUIHHWDRkzrPHsQTQ==", + "version": "0.2.11", + "resolved": "https://registry.npmjs.org/webdriver-bidi-protocol/-/webdriver-bidi-protocol-0.2.11.tgz", + "integrity": "sha512-Y9E1/oi4XMxcR8AT0ZC4OvYntl34SPgwjmELH+owjBr0korAX4jKgZULBWILGCVGdVCQ0dodTToIETozhG8zvA==", "dev": true, "license": "Apache-2.0" }, @@ -9981,7 +10003,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -10014,7 +10036,7 @@ "postcss-dir-pseudo-class": "*", "postcss-logical": "*", "postcss-nesting": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -10038,7 +10060,7 @@ "license": "MIT-0", "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -10174,7 +10196,7 @@ "devDependencies": { "@csstools/postcss-bundler": "*", "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -10776,7 +10798,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -10803,7 +10825,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -11081,7 +11103,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -11143,7 +11165,7 @@ "devDependencies": { "@csstools/postcss-tape": "*", "postcss-nesting": "^13.0.0", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -11327,7 +11349,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" @@ -11440,7 +11462,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "engines": { "node": ">=18" diff --git a/package.json b/package.json index 03058a9708..04e4295a90 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "devDependencies": { "@babel/core": "^7.28.4", "@babel/preset-env": "^7.28.0", - "@eslint/js": "^9.35.0", + "@eslint/js": "^9.36.0", "@microsoft/api-documenter": "^7.26.34", "@microsoft/api-extractor": "^7.52.13", "@rollup/plugin-babel": "^6.0.3", @@ -37,13 +37,13 @@ "@rollup/plugin-terser": "^0.4.3", "@rollup/plugin-typescript": "^12.1.4", "@stryker-mutator/core": "^9.1.1", - "eslint": "^9.35.0", + "eslint": "^9.36.0", "globals": "^16.4.0", "knip": "^5.63.1", - "rollup": "^4.50.1", + "rollup": "^4.52.0", "tslib": "^2.8.0", "typescript": "^5.8.3", - "typescript-eslint": "^8.43.0" + "typescript-eslint": "^8.44.0" }, "scripts": { "everything": "npm run lint && npm run knip && npm run build && npm run docs && npm run test", diff --git a/packages/base-cli/dist/index.cjs b/packages/base-cli/dist/index.cjs index fb802eadd1..37897f8370 100644 --- a/packages/base-cli/dist/index.cjs +++ b/packages/base-cli/dist/index.cjs @@ -1 +1 @@ -"use strict";var t,e=require("postcss"),n=require("node:path"),s=require("node:fs/promises");function parseArguments(e,n,s){const o=e.map(t=>t.trim()).filter(t=>!!t),i={stdin:!1,stdout:!1,output:void 0,outputDir:void 0,inputs:[],inlineMap:!0,externalMap:!1,replace:!1,pluginOptions:{},debug:!1};let r,a=!1;for(let e=0;e1&&i.output)return console.warn('[error] omit "--output" when processing multiple inputs\n'),s(),t.InvalidArguments;0===i.inputs.length&&(i.stdin=!0),i.output||i.outputDir||i.replace||(i.stdout=!0),i.stdout&&(i.externalMap=!1);let p={};if(r)try{p=JSON.parse(r)}catch{return console.warn("[error] plugin options must be valid JSON\n"),s(),t.InvalidArguments}for(const e in p){const o=p[e];if(!n.includes(e))return console.warn(`[error] unknown plugin option: ${e}\n`),s(),t.InvalidArguments;i.pluginOptions[e]=o}return i}async function getStdin(){return new Promise(t=>{let e="",n=!1;if(setTimeout(()=>{n=!0,t("")},1e4),process.stdin.isTTY){if(n)return;t(e)}else process.stdin.setEncoding("utf8"),process.stdin.on("readable",()=>{let t="";for(;t=process.stdin.read();)e+=t??""}),process.stdin.on("end",()=>{n||t(e)})})}async function stdinToStdout(t,n,s){let o="";try{const i=await getStdin();i||(s(),process.exit(1));const r=await e([t]).process(i,{from:"stdin",to:"stdout",map:!!n.inlineMap&&{inline:!0}});r.warnings().forEach(t=>{console.warn(t.toString())}),o=r.css}catch(t){t instanceof Error?console.error(n.debug?t:t.message):console.error(t),process.exit(1)}process.stdout.write(o+(n.inlineMap?"\n":"")),process.exit(0)}async function stdinToFs(t,o,i){let r=o.output;!r&&o.outputDir&&(r=n.join(o.outputDir,"output.css")),r||process.exit(0);try{const n=await getStdin();n||(i(),process.exit(1));const a=await e([t]).process(n,{from:"stdin",to:r,map:!(!o.inlineMap&&!o.externalMap)&&{inline:o.inlineMap}});a.warnings().forEach(t=>{console.warn(t.toString())}),o.externalMap&&a.map?await Promise.all([await s.writeFile(r,a.css+(o.inlineMap?"\n":"")),await s.writeFile(`${r}.map`,a.map.toString())]):await s.writeFile(r,a.css+(o.inlineMap?"\n":""))}catch(t){t instanceof Error?console.error(o.debug?t:t.message):console.error(t),process.exit(1)}console.log(`CSS was written to "${n.normalize(r)}"`),process.exit(0)}async function fsToStdout(t,n){let o=[];try{o=await Promise.all(n.inputs.map(async n=>{const o=await s.readFile(n),i=await e([t]).process(o,{from:n,to:"stdout",map:!1});return i.warnings().forEach(t=>{console.warn(t.toString())}),i.css}))}catch(t){t instanceof Error?console.error(n.debug?t:t.message):console.error(t),process.exit(1)}for(const t of o)process.stdout.write(t);process.exit(0)}async function fsToFs(t,o){try{await Promise.all(o.inputs.map(async i=>{let r=o.output;o.outputDir&&(r=n.join(o.outputDir,n.basename(i))),o.replace&&(r=i),r||process.exit(0);const a=await s.readFile(i),p=await e([t]).process(a,{from:i,to:r,map:!(!o.inlineMap&&!o.externalMap)&&{inline:o.inlineMap}});p.warnings().forEach(t=>{console.warn(t.toString())}),o.externalMap&&p.map?await Promise.all([await s.writeFile(r,p.css+(o.inlineMap?"\n":"")),await s.writeFile(`${r}.map`,p.map.toString())]):await s.writeFile(r,p.css+(o.inlineMap?"\n":"")),console.log(`CSS was written to "${n.normalize(r)}"`)}))}catch(t){t instanceof Error?console.error(o.debug?t:t.message):console.error(t),process.exit(1)}process.exit(0)}!function(t){t.InvalidArguments="INVALID_ARGUMENTS"}(t||(t={})),exports.cli=async function cli(e,n,s,o=!0){const i=parseArguments(process.argv.slice(o?2:3),n,s);i===t.InvalidArguments&&process.exit(1);const r=e(i.pluginOptions);i.stdin&&i.stdout?await stdinToStdout(r,i,s):i.stdin?await stdinToFs(r,i,s):i.stdout?await fsToStdout(r,i):await fsToFs(r,i)},exports.helpTextLogger=function helpTextLogger(t,e,n,s=null){let o=[];if(s){const t=Math.max(...Object.keys(s).map(t=>t.length)),e=new Array(t).fill(" ").join("");e.length&&(o=["\nPlugin Options:",...Object.keys(s).map(t=>` ${(t+e).slice(0,e.length)} ${typeof s[t]}`)],o.push(`\n ${JSON.stringify(s,null,2).split("\n").join("\n ")}`))}const i=[`${e}\n`,` ${n}\n`,"Usage:",` ${t} [input.css] [OPTIONS] [-o|--output output.css]`,` ${t} ... [OPTIONS] --dir `,` ${t} ... [OPTIONS] --replace`,"\nOptions:"," -o, --output Output file"," -d, --dir Output directory"," -r, --replace Replace (overwrite) the input file"," -m, --map Create an external sourcemap"," --no-map Disable the default inline sourcemaps"," -p, --plugin-options Stringified JSON object with plugin options"];return o.length>0&&i.push(...o),()=>{console.warn(i.join("\n"))}},exports.parseArguments=parseArguments; +"use strict";var t,e=require("postcss"),n=require("node:path"),s=require("node:fs/promises");function parseArguments(e,n,s){const o=e.map(t=>t.trim()).filter(t=>!!t),r={stdin:!1,stdout:!1,output:void 0,outputDir:void 0,inputs:[],inlineMap:!0,externalMap:!1,replace:!1,pluginOptions:{},debug:!1};let i,a=!1;for(let e=0;e1&&r.output)return console.warn('[error] omit "--output" when processing multiple inputs\n'),s(),t.InvalidArguments;0===r.inputs.length&&(r.stdin=!0),r.output||r.outputDir||r.replace||(r.stdout=!0),r.stdout&&(r.externalMap=!1);let p={};if(i)try{p=JSON.parse(i)}catch{return console.warn("[error] plugin options must be valid JSON\n"),s(),t.InvalidArguments}for(const e in p){const o=p[e];if(!n.includes(e))return console.warn(`[error] unknown plugin option: ${e}\n`),s(),t.InvalidArguments;r.pluginOptions[e]=o}return r}async function getStdin(){return new Promise(t=>{let e="",n=!1;if(setTimeout(()=>{n=!0,t("")},1e4),process.stdin.isTTY){if(n)return;t(e)}else process.stdin.setEncoding("utf8"),process.stdin.on("readable",()=>{let t="";for(;t=process.stdin.read();)e+=t??""}),process.stdin.on("end",()=>{n||t(e)})})}async function stdinToStdout(t,n,s){let o="";try{const r=await getStdin();r||(s(),process.exit(1));const i=await e([t]).process(r,{from:"stdin",to:"stdout",map:!!n.inlineMap&&{inline:!0}});i.warnings().forEach(t=>{console.warn(t.toString())}),o=i.css}catch(t){t instanceof Error?console.error(n.debug?t:t.message):console.error(t),process.exit(1)}process.stdout.write(o+(n.inlineMap?"\n":"")),process.exit(0)}async function stdinToFs(t,o,r){let i=o.output;!i&&o.outputDir&&(i=n.join(o.outputDir,"output.css")),i||process.exit(0);try{const n=await getStdin();n||(r(),process.exit(1));const a=await e([t]).process(n,{from:"stdin",to:i,map:!(!o.inlineMap&&!o.externalMap)&&{inline:o.inlineMap}});a.warnings().forEach(t=>{console.warn(t.toString())}),o.externalMap&&a.map?await Promise.all([s.writeFile(i,a.css+(o.inlineMap?"\n":"")),s.writeFile(`${i}.map`,a.map.toString())]):await s.writeFile(i,a.css+(o.inlineMap?"\n":""))}catch(t){t instanceof Error?console.error(o.debug?t:t.message):console.error(t),process.exit(1)}console.log(`CSS was written to "${n.normalize(i)}"`),process.exit(0)}async function fsToStdout(t,n){let o=[];try{o=await Promise.all(n.inputs.map(async n=>{const o=await s.readFile(n),r=await e([t]).process(o,{from:n,to:"stdout",map:!1});return r.warnings().forEach(t=>{console.warn(t.toString())}),r.css}))}catch(t){t instanceof Error?console.error(n.debug?t:t.message):console.error(t),process.exit(1)}for(const t of o)process.stdout.write(t);process.exit(0)}async function fsToFs(t,o){try{await Promise.all(o.inputs.map(async r=>{let i=o.output;o.outputDir&&(i=n.join(o.outputDir,n.basename(r))),o.replace&&(i=r),i||process.exit(0);const a=await s.readFile(r),p=await e([t]).process(a,{from:r,to:i,map:!(!o.inlineMap&&!o.externalMap)&&{inline:o.inlineMap}});p.warnings().forEach(t=>{console.warn(t.toString())}),o.externalMap&&p.map?await Promise.all([s.writeFile(i,p.css+(o.inlineMap?"\n":"")),s.writeFile(`${i}.map`,p.map.toString())]):await s.writeFile(i,p.css+(o.inlineMap?"\n":"")),console.log(`CSS was written to "${n.normalize(i)}"`)}))}catch(t){t instanceof Error?console.error(o.debug?t:t.message):console.error(t),process.exit(1)}process.exit(0)}!function(t){t.InvalidArguments="INVALID_ARGUMENTS"}(t||(t={})),exports.cli=async function cli(e,n,s,o=!0){const r=parseArguments(process.argv.slice(o?2:3),n,s);r===t.InvalidArguments&&process.exit(1);const i=e(r.pluginOptions);r.stdin&&r.stdout?await stdinToStdout(i,r,s):r.stdin?await stdinToFs(i,r,s):r.stdout?await fsToStdout(i,r):await fsToFs(i,r)},exports.helpTextLogger=function helpTextLogger(t,e,n,s=null){let o=[];if(s){const t=Math.max(...Object.keys(s).map(t=>t.length)),e=new Array(t).fill(" ").join("");e.length&&(o=["\nPlugin Options:",...Object.keys(s).map(t=>` ${(t+e).slice(0,e.length)} ${typeof s[t]}`)],o.push(`\n ${JSON.stringify(s,null,2).split("\n").join("\n ")}`))}const r=[`${e}\n`,` ${n}\n`,"Usage:",` ${t} [input.css] [OPTIONS] [-o|--output output.css]`,` ${t} ... [OPTIONS] --dir `,` ${t} ... [OPTIONS] --replace`,"\nOptions:"," -o, --output Output file"," -d, --dir Output directory"," -r, --replace Replace (overwrite) the input file"," -m, --map Create an external sourcemap"," --no-map Disable the default inline sourcemaps"," -p, --plugin-options Stringified JSON object with plugin options"];return o.length>0&&r.push(...o),()=>{console.warn(r.join("\n"))}},exports.parseArguments=parseArguments; diff --git a/packages/base-cli/dist/index.mjs b/packages/base-cli/dist/index.mjs index f9c81cc39c..79f43514d8 100644 --- a/packages/base-cli/dist/index.mjs +++ b/packages/base-cli/dist/index.mjs @@ -1 +1 @@ -import t from"postcss";import e from"node:path";import n from"node:fs/promises";var o;function parseArguments(t,e,n){const s=t.map(t=>t.trim()).filter(t=>!!t),i={stdin:!1,stdout:!1,output:void 0,outputDir:void 0,inputs:[],inlineMap:!0,externalMap:!1,replace:!1,pluginOptions:{},debug:!1};let r,a=!1;for(let t=0;t1&&i.output)return console.warn('[error] omit "--output" when processing multiple inputs\n'),n(),o.InvalidArguments;0===i.inputs.length&&(i.stdin=!0),i.output||i.outputDir||i.replace||(i.stdout=!0),i.stdout&&(i.externalMap=!1);let p={};if(r)try{p=JSON.parse(r)}catch{return console.warn("[error] plugin options must be valid JSON\n"),n(),o.InvalidArguments}for(const t in p){const s=p[t];if(!e.includes(t))return console.warn(`[error] unknown plugin option: ${t}\n`),n(),o.InvalidArguments;i.pluginOptions[t]=s}return i}async function getStdin(){return new Promise(t=>{let e="",n=!1;if(setTimeout(()=>{n=!0,t("")},1e4),process.stdin.isTTY){if(n)return;t(e)}else process.stdin.setEncoding("utf8"),process.stdin.on("readable",()=>{let t="";for(;t=process.stdin.read();)e+=t??""}),process.stdin.on("end",()=>{n||t(e)})})}async function stdinToStdout(e,n,o){let s="";try{const i=await getStdin();i||(o(),process.exit(1));const r=await t([e]).process(i,{from:"stdin",to:"stdout",map:!!n.inlineMap&&{inline:!0}});r.warnings().forEach(t=>{console.warn(t.toString())}),s=r.css}catch(t){t instanceof Error?console.error(n.debug?t:t.message):console.error(t),process.exit(1)}process.stdout.write(s+(n.inlineMap?"\n":"")),process.exit(0)}async function stdinToFs(o,s,i){let r=s.output;!r&&s.outputDir&&(r=e.join(s.outputDir,"output.css")),r||process.exit(0);try{const e=await getStdin();e||(i(),process.exit(1));const a=await t([o]).process(e,{from:"stdin",to:r,map:!(!s.inlineMap&&!s.externalMap)&&{inline:s.inlineMap}});a.warnings().forEach(t=>{console.warn(t.toString())}),s.externalMap&&a.map?await Promise.all([await n.writeFile(r,a.css+(s.inlineMap?"\n":"")),await n.writeFile(`${r}.map`,a.map.toString())]):await n.writeFile(r,a.css+(s.inlineMap?"\n":""))}catch(t){t instanceof Error?console.error(s.debug?t:t.message):console.error(t),process.exit(1)}console.log(`CSS was written to "${e.normalize(r)}"`),process.exit(0)}async function fsToStdout(e,o){let s=[];try{s=await Promise.all(o.inputs.map(async o=>{const s=await n.readFile(o),i=await t([e]).process(s,{from:o,to:"stdout",map:!1});return i.warnings().forEach(t=>{console.warn(t.toString())}),i.css}))}catch(t){t instanceof Error?console.error(o.debug?t:t.message):console.error(t),process.exit(1)}for(const t of s)process.stdout.write(t);process.exit(0)}async function fsToFs(o,s){try{await Promise.all(s.inputs.map(async i=>{let r=s.output;s.outputDir&&(r=e.join(s.outputDir,e.basename(i))),s.replace&&(r=i),r||process.exit(0);const a=await n.readFile(i),p=await t([o]).process(a,{from:i,to:r,map:!(!s.inlineMap&&!s.externalMap)&&{inline:s.inlineMap}});p.warnings().forEach(t=>{console.warn(t.toString())}),s.externalMap&&p.map?await Promise.all([await n.writeFile(r,p.css+(s.inlineMap?"\n":"")),await n.writeFile(`${r}.map`,p.map.toString())]):await n.writeFile(r,p.css+(s.inlineMap?"\n":"")),console.log(`CSS was written to "${e.normalize(r)}"`)}))}catch(t){t instanceof Error?console.error(s.debug?t:t.message):console.error(t),process.exit(1)}process.exit(0)}function helpTextLogger(t,e,n,o=null){let s=[];if(o){const t=Math.max(...Object.keys(o).map(t=>t.length)),e=new Array(t).fill(" ").join("");e.length&&(s=["\nPlugin Options:",...Object.keys(o).map(t=>` ${(t+e).slice(0,e.length)} ${typeof o[t]}`)],s.push(`\n ${JSON.stringify(o,null,2).split("\n").join("\n ")}`))}const i=[`${e}\n`,` ${n}\n`,"Usage:",` ${t} [input.css] [OPTIONS] [-o|--output output.css]`,` ${t} ... [OPTIONS] --dir `,` ${t} ... [OPTIONS] --replace`,"\nOptions:"," -o, --output Output file"," -d, --dir Output directory"," -r, --replace Replace (overwrite) the input file"," -m, --map Create an external sourcemap"," --no-map Disable the default inline sourcemaps"," -p, --plugin-options Stringified JSON object with plugin options"];return s.length>0&&i.push(...s),()=>{console.warn(i.join("\n"))}}async function cli(t,e,n,s=!0){const i=parseArguments(process.argv.slice(s?2:3),e,n);i===o.InvalidArguments&&process.exit(1);const r=t(i.pluginOptions);i.stdin&&i.stdout?await stdinToStdout(r,i,n):i.stdin?await stdinToFs(r,i,n):i.stdout?await fsToStdout(r,i):await fsToFs(r,i)}!function(t){t.InvalidArguments="INVALID_ARGUMENTS"}(o||(o={}));export{cli,helpTextLogger,parseArguments}; +import t from"postcss";import e from"node:path";import n from"node:fs/promises";var o;function parseArguments(t,e,n){const s=t.map(t=>t.trim()).filter(t=>!!t),i={stdin:!1,stdout:!1,output:void 0,outputDir:void 0,inputs:[],inlineMap:!0,externalMap:!1,replace:!1,pluginOptions:{},debug:!1};let r,a=!1;for(let t=0;t1&&i.output)return console.warn('[error] omit "--output" when processing multiple inputs\n'),n(),o.InvalidArguments;0===i.inputs.length&&(i.stdin=!0),i.output||i.outputDir||i.replace||(i.stdout=!0),i.stdout&&(i.externalMap=!1);let p={};if(r)try{p=JSON.parse(r)}catch{return console.warn("[error] plugin options must be valid JSON\n"),n(),o.InvalidArguments}for(const t in p){const s=p[t];if(!e.includes(t))return console.warn(`[error] unknown plugin option: ${t}\n`),n(),o.InvalidArguments;i.pluginOptions[t]=s}return i}async function getStdin(){return new Promise(t=>{let e="",n=!1;if(setTimeout(()=>{n=!0,t("")},1e4),process.stdin.isTTY){if(n)return;t(e)}else process.stdin.setEncoding("utf8"),process.stdin.on("readable",()=>{let t="";for(;t=process.stdin.read();)e+=t??""}),process.stdin.on("end",()=>{n||t(e)})})}async function stdinToStdout(e,n,o){let s="";try{const i=await getStdin();i||(o(),process.exit(1));const r=await t([e]).process(i,{from:"stdin",to:"stdout",map:!!n.inlineMap&&{inline:!0}});r.warnings().forEach(t=>{console.warn(t.toString())}),s=r.css}catch(t){t instanceof Error?console.error(n.debug?t:t.message):console.error(t),process.exit(1)}process.stdout.write(s+(n.inlineMap?"\n":"")),process.exit(0)}async function stdinToFs(o,s,i){let r=s.output;!r&&s.outputDir&&(r=e.join(s.outputDir,"output.css")),r||process.exit(0);try{const e=await getStdin();e||(i(),process.exit(1));const a=await t([o]).process(e,{from:"stdin",to:r,map:!(!s.inlineMap&&!s.externalMap)&&{inline:s.inlineMap}});a.warnings().forEach(t=>{console.warn(t.toString())}),s.externalMap&&a.map?await Promise.all([n.writeFile(r,a.css+(s.inlineMap?"\n":"")),n.writeFile(`${r}.map`,a.map.toString())]):await n.writeFile(r,a.css+(s.inlineMap?"\n":""))}catch(t){t instanceof Error?console.error(s.debug?t:t.message):console.error(t),process.exit(1)}console.log(`CSS was written to "${e.normalize(r)}"`),process.exit(0)}async function fsToStdout(e,o){let s=[];try{s=await Promise.all(o.inputs.map(async o=>{const s=await n.readFile(o),i=await t([e]).process(s,{from:o,to:"stdout",map:!1});return i.warnings().forEach(t=>{console.warn(t.toString())}),i.css}))}catch(t){t instanceof Error?console.error(o.debug?t:t.message):console.error(t),process.exit(1)}for(const t of s)process.stdout.write(t);process.exit(0)}async function fsToFs(o,s){try{await Promise.all(s.inputs.map(async i=>{let r=s.output;s.outputDir&&(r=e.join(s.outputDir,e.basename(i))),s.replace&&(r=i),r||process.exit(0);const a=await n.readFile(i),p=await t([o]).process(a,{from:i,to:r,map:!(!s.inlineMap&&!s.externalMap)&&{inline:s.inlineMap}});p.warnings().forEach(t=>{console.warn(t.toString())}),s.externalMap&&p.map?await Promise.all([n.writeFile(r,p.css+(s.inlineMap?"\n":"")),n.writeFile(`${r}.map`,p.map.toString())]):await n.writeFile(r,p.css+(s.inlineMap?"\n":"")),console.log(`CSS was written to "${e.normalize(r)}"`)}))}catch(t){t instanceof Error?console.error(s.debug?t:t.message):console.error(t),process.exit(1)}process.exit(0)}function helpTextLogger(t,e,n,o=null){let s=[];if(o){const t=Math.max(...Object.keys(o).map(t=>t.length)),e=new Array(t).fill(" ").join("");e.length&&(s=["\nPlugin Options:",...Object.keys(o).map(t=>` ${(t+e).slice(0,e.length)} ${typeof o[t]}`)],s.push(`\n ${JSON.stringify(o,null,2).split("\n").join("\n ")}`))}const i=[`${e}\n`,` ${n}\n`,"Usage:",` ${t} [input.css] [OPTIONS] [-o|--output output.css]`,` ${t} ... [OPTIONS] --dir `,` ${t} ... [OPTIONS] --replace`,"\nOptions:"," -o, --output Output file"," -d, --dir Output directory"," -r, --replace Replace (overwrite) the input file"," -m, --map Create an external sourcemap"," --no-map Disable the default inline sourcemaps"," -p, --plugin-options Stringified JSON object with plugin options"];return s.length>0&&i.push(...s),()=>{console.warn(i.join("\n"))}}async function cli(t,e,n,s=!0){const i=parseArguments(process.argv.slice(s?2:3),e,n);i===o.InvalidArguments&&process.exit(1);const r=t(i.pluginOptions);i.stdin&&i.stdout?await stdinToStdout(r,i,n):i.stdin?await stdinToFs(r,i,n):i.stdout?await fsToStdout(r,i):await fsToFs(r,i)}!function(t){t.InvalidArguments="INVALID_ARGUMENTS"}(o||(o={}));export{cli,helpTextLogger,parseArguments}; diff --git a/packages/base-cli/src/io-fs-to-fs.ts b/packages/base-cli/src/io-fs-to-fs.ts index 9d76328b7a..818bc420d5 100644 --- a/packages/base-cli/src/io-fs-to-fs.ts +++ b/packages/base-cli/src/io-fs-to-fs.ts @@ -35,8 +35,8 @@ export async function fsToFs(plugin: Plugin, argo: Arguments): Promise { if (argo.externalMap && result.map) { await Promise.all([ - await fs.writeFile(output, result.css + (argo.inlineMap ? '\n' : '')), - await fs.writeFile(`${output}.map`, result.map.toString()), + fs.writeFile(output, result.css + (argo.inlineMap ? '\n' : '')), + fs.writeFile(`${output}.map`, result.map.toString()), ]); } else { await fs.writeFile(output, result.css + (argo.inlineMap ? '\n' : '')); diff --git a/packages/base-cli/src/io-stdin-to-fs.ts b/packages/base-cli/src/io-stdin-to-fs.ts index beb0fe381b..1148ad5680 100644 --- a/packages/base-cli/src/io-stdin-to-fs.ts +++ b/packages/base-cli/src/io-stdin-to-fs.ts @@ -38,8 +38,8 @@ export async function stdinToFs(plugin: Plugin, argo: Arguments, helpLogger: () if (argo.externalMap && result.map) { await Promise.all([ - await fs.writeFile(output, result.css + (argo.inlineMap ? '\n' : '')), - await fs.writeFile(`${output}.map`, result.map.toString()), + fs.writeFile(output, result.css + (argo.inlineMap ? '\n' : '')), + fs.writeFile(`${output}.map`, result.map.toString()), ]); } else { await fs.writeFile(output, result.css + (argo.inlineMap ? '\n' : '')); diff --git a/plugins/css-blank-pseudo/package.json b/plugins/css-blank-pseudo/package.json index 66a650320e..d09f76e126 100644 --- a/plugins/css-blank-pseudo/package.json +++ b/plugins/css-blank-pseudo/package.json @@ -67,7 +67,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/css-has-pseudo/package.json b/plugins/css-has-pseudo/package.json index 128ef3c50e..7bc58c8c55 100644 --- a/plugins/css-has-pseudo/package.json +++ b/plugins/css-has-pseudo/package.json @@ -73,7 +73,7 @@ "postcss-dir-pseudo-class": "*", "postcss-logical": "*", "postcss-nesting": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/css-prefers-color-scheme/package.json b/plugins/css-prefers-color-scheme/package.json index 5724745449..c3c0d0ade1 100644 --- a/plugins/css-prefers-color-scheme/package.json +++ b/plugins/css-prefers-color-scheme/package.json @@ -64,7 +64,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-cascade-layers/package.json b/plugins/postcss-cascade-layers/package.json index 718138d678..0f4d818f14 100644 --- a/plugins/postcss-cascade-layers/package.json +++ b/plugins/postcss-cascade-layers/package.json @@ -65,7 +65,7 @@ "devDependencies": { "@csstools/postcss-bundler": "*", "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-focus-visible/package.json b/plugins/postcss-focus-visible/package.json index 99403f733a..e9932f8998 100644 --- a/plugins/postcss-focus-visible/package.json +++ b/plugins/postcss-focus-visible/package.json @@ -55,7 +55,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-focus-within/package.json b/plugins/postcss-focus-within/package.json index 0e2b8785e6..1b819c9e08 100644 --- a/plugins/postcss-focus-within/package.json +++ b/plugins/postcss-focus-within/package.json @@ -67,7 +67,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-is-pseudo-class/package.json b/plugins/postcss-is-pseudo-class/package.json index 3cf76a8414..f1bc26eecb 100644 --- a/plugins/postcss-is-pseudo-class/package.json +++ b/plugins/postcss-is-pseudo-class/package.json @@ -46,7 +46,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-light-dark-function/package.json b/plugins/postcss-light-dark-function/package.json index 4e4b7648b1..008d18fcc2 100644 --- a/plugins/postcss-light-dark-function/package.json +++ b/plugins/postcss-light-dark-function/package.json @@ -59,7 +59,7 @@ "devDependencies": { "@csstools/postcss-tape": "*", "postcss-nesting": "^13.0.0", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-media-minmax/package.json b/plugins/postcss-media-minmax/package.json index 96674e6727..a9cd261238 100644 --- a/plugins/postcss-media-minmax/package.json +++ b/plugins/postcss-media-minmax/package.json @@ -61,7 +61,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs", diff --git a/plugins/postcss-nesting/package.json b/plugins/postcss-nesting/package.json index 14f033b26b..924f704117 100644 --- a/plugins/postcss-nesting/package.json +++ b/plugins/postcss-nesting/package.json @@ -63,7 +63,7 @@ }, "devDependencies": { "@csstools/postcss-tape": "*", - "puppeteer": "^24.20.0" + "puppeteer": "^24.22.0" }, "scripts": { "build": "rollup -c ../../rollup/default.mjs",