yummacss 3.24.17 → 3.26.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 Yumma CSS
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Yumma CSS
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,33 +1,33 @@
1
- # yummacss
2
-
3
- The ergonomic CSS framework.
4
-
5
- ## Installation
6
- ```bash
7
- npm install yummacss -D
8
- npx yummacss init
9
- ```
10
-
11
- ## Commands
12
-
13
- ### `init`
14
- Initialize configuration file
15
- ```bash
16
- npx yummacss init
17
- ```
18
-
19
- ### `build`
20
- Build styles once
21
- ```bash
22
- npx yummacss build
23
- ```
24
-
25
- ### `watch`
26
- Build styles continuously
27
- ```bash
28
- npx yummacss watch
29
- ```
30
-
31
- ## Documentation
32
-
1
+ # yummacss
2
+
3
+ The ergonomic CSS framework.
4
+
5
+ ## Installation
6
+ ```bash
7
+ npm install yummacss -D
8
+ npx yummacss init
9
+ ```
10
+
11
+ ## Commands
12
+
13
+ ### `init`
14
+ Initialize configuration file
15
+ ```bash
16
+ npx yummacss init
17
+ ```
18
+
19
+ ### `build`
20
+ Build styles once
21
+ ```bash
22
+ npx yummacss build
23
+ ```
24
+
25
+ ### `watch`
26
+ Build styles continuously
27
+ ```bash
28
+ npx yummacss watch
29
+ ```
30
+
31
+ ## Documentation
32
+
33
33
  Learn more at [yummacss.com](https://yummacss.com)
package/dist/cli.mjs CHANGED
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/env node
2
- import{ConfigSchema as e,configName as t,extractor as n,generator as r}from"@yummacss/nitro";import{existsSync as i,mkdirSync as a,watch as o,writeFileSync as s}from"node:fs";import{dirname as c,join as l}from"node:path";import*as u from"fs";import d from"fs";import f,{basename as p,dirname as m,normalize as h,posix as g,relative as ee,resolve as _,sep as v}from"path";import{fileURLToPath as y}from"url";import{createRequire as b}from"module";import{pathToFileURL as x}from"node:url";var S=Object.create,C=Object.defineProperty,w=Object.getOwnPropertyDescriptor,T=Object.getOwnPropertyNames,E=Object.getPrototypeOf,D=Object.prototype.hasOwnProperty,O=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),k=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=T(t),a=0,o=i.length,s;a<o;a++)s=i[a],!D.call(e,s)&&s!==n&&C(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=w(t,s))||r.enumerable});return e},te=(e,t,n)=>(n=e==null?{}:S(E(e)),k(t||!e||!e.__esModule?C(n,`default`,{value:e,enumerable:!0}):n,e)),A=`3.24.17`;function j(e){"@babel/helpers - typeof";return j=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},j(e)}function ne(e,t){if(j(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(j(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function M(e){var t=ne(e,`string`);return j(t)==`symbol`?t:t+``}function N(e,t,n){return(t=M(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var P=b(import.meta.url);function F(e){let t=h(e);return t.length>1&&t[t.length-1]===v&&(t=t.substring(0,t.length-1)),t}const I=/[\\/]/g;function L(e,t){return e.replace(I,t)}const R=/^[a-z]:[\\/]$/i;function z(e){return e===`/`||R.test(e)}function B(e,t){let{resolvePaths:n,normalizePath:r,pathSeparator:i}=t,a=process.platform===`win32`&&e.includes(`/`)||e.startsWith(`.`);return n&&(e=_(e)),(r||a)&&(e=F(e)),e===`.`?``:L(e[e.length-1]===i?e:e+i,i)}function V(e,t){return t+e}function H(e,t){return function(n,r){return r.startsWith(e)?r.slice(e.length)+n:L(ee(e,r),t.pathSeparator)+t.pathSeparator+n}}function U(e){return e}function W(e,t,n){return t+e+n}function re(e,t){let{relativePaths:n,includeBasePath:r}=t;return n&&e?H(e,t):r?V:U}function G(e){return function(t,n){n.push(t.substring(e.length)||`.`)}}function K(e){return function(t,n,r){let i=t.substring(e.length)||`.`;r.every(e=>e(i,!0))&&n.push(i)}}const q=(e,t)=>{t.push(e||`.`)},ie=(e,t,n)=>{let r=e||`.`;n.every(e=>e(r,!0))&&t.push(r)},ae=()=>{};function oe(e,t){let{includeDirs:n,filters:r,relativePaths:i}=t;return n?i?r&&r.length?K(e):G(e):r&&r.length?ie:q:ae}const se=(e,t,n,r)=>{r.every(t=>t(e,!1))&&n.files++},ce=(e,t,n,r)=>{r.every(t=>t(e,!1))&&t.push(e)},le=(e,t,n,r)=>{n.files++},ue=(e,t)=>{t.push(e)},de=()=>{};function fe(e){let{excludeFiles:t,filters:n,onlyCounts:r}=e;return t?de:n&&n.length?r?se:ce:r?le:ue}const pe=e=>e,me=()=>[``].slice(0,0);function he(e){return e.group?me:pe}const ge=(e,t,n)=>{e.push({directory:t,files:n,dir:t})},_e=()=>{};function ve(e){return e.group?ge:_e}const ye=function(e,t,n){let{queue:r,fs:i,options:{suppressErrors:a}}=t;r.enqueue(),i.realpath(e,(o,s)=>{if(o)return r.dequeue(a?null:o,t);i.stat(s,(i,o)=>{if(i)return r.dequeue(a?null:i,t);if(o.isDirectory()&&Se(e,s,t))return r.dequeue(null,t);n(o,s),r.dequeue(null,t)})})},be=function(e,t,n){let{queue:r,fs:i,options:{suppressErrors:a}}=t;r.enqueue();try{let r=i.realpathSync(e),a=i.statSync(r);if(a.isDirectory()&&Se(e,r,t))return;n(a,r)}catch(e){if(!a)throw e}};function xe(e,t){return!e.resolveSymlinks||e.excludeSymlinks?null:t?be:ye}function Se(e,t,n){if(n.options.useRealPaths)return Ce(t,n);let r=m(e),i=1;for(;r!==n.root&&i<2;){let e=n.symlinks.get(r);e&&(e===t||e.startsWith(t)||t.startsWith(e))?i++:r=m(r)}return n.symlinks.set(e,t),i>1}function Ce(e,t){return t.visited.includes(e+t.options.pathSeparator)}const we=e=>e.counts,Te=e=>e.groups,Ee=e=>e.paths,De=e=>e.paths.slice(0,e.options.maxFiles),Oe=(e,t,n)=>(Me(t,n,e.counts,e.options.suppressErrors),null),ke=(e,t,n)=>(Me(t,n,e.paths,e.options.suppressErrors),null),Ae=(e,t,n)=>(Me(t,n,e.paths.slice(0,e.options.maxFiles),e.options.suppressErrors),null),je=(e,t,n)=>(Me(t,n,e.groups,e.options.suppressErrors),null);function Me(e,t,n,r){t(e&&!r?e:null,n)}function Ne(e,t){let{onlyCounts:n,group:r,maxFiles:i}=e;return n?t?we:Oe:r?t?Te:je:i?t?De:Ae:t?Ee:ke}const Pe={withFileTypes:!0},Fe=(e,t,n,r,i)=>{if(e.queue.enqueue(),r<0)return e.queue.dequeue(null,e);let{fs:a}=e;e.visited.push(t),e.counts.directories++,a.readdir(t||`.`,Pe,(t,a=[])=>{i(a,n,r),e.queue.dequeue(e.options.suppressErrors?null:t,e)})},Ie=(e,t,n,r,i)=>{let{fs:a}=e;if(r<0)return;e.visited.push(t),e.counts.directories++;let o=[];try{o=a.readdirSync(t||`.`,Pe)}catch(t){if(!e.options.suppressErrors)throw t}i(o,n,r)};function Le(e){return e?Ie:Fe}var Re=class{constructor(e){N(this,`count`,0),this.onQueueEmpty=e}enqueue(){return this.count++,this.count}dequeue(e,t){this.onQueueEmpty&&(--this.count<=0||e)&&(this.onQueueEmpty(e,t),e&&(t.controller.abort(),this.onQueueEmpty=void 0))}},ze=class{constructor(){N(this,`_files`,0),N(this,`_directories`,0)}set files(e){this._files=e}get files(){return this._files}set directories(e){this._directories=e}get directories(){return this._directories}get dirs(){return this._directories}},Be=class{constructor(){N(this,`aborted`,!1)}abort(){this.aborted=!0}},Ve=class{constructor(e,t,n){N(this,`root`,void 0),N(this,`isSynchronous`,void 0),N(this,`state`,void 0),N(this,`joinPath`,void 0),N(this,`pushDirectory`,void 0),N(this,`pushFile`,void 0),N(this,`getArray`,void 0),N(this,`groupFiles`,void 0),N(this,`resolveSymlink`,void 0),N(this,`walkDirectory`,void 0),N(this,`callbackInvoker`,void 0),N(this,`walk`,(e,t,n)=>{let{paths:r,options:{filters:i,resolveSymlinks:a,excludeSymlinks:o,exclude:s,maxFiles:c,signal:l,useRealPaths:u,pathSeparator:d},controller:f}=this.state;if(f.aborted||l&&l.aborted||c&&r.length>c)return;let h=this.getArray(this.state.paths);for(let c=0;c<e.length;++c){let l=e[c];if(l.isFile()||l.isSymbolicLink()&&!a&&!o){let e=this.joinPath(l.name,t);this.pushFile(e,h,this.state.counts,i)}else if(l.isDirectory()){let e=W(l.name,t,this.state.options.pathSeparator);if(s&&s(l.name,e))continue;this.pushDirectory(e,r,i),this.walkDirectory(this.state,e,e,n-1,this.walk)}else if(this.resolveSymlink&&l.isSymbolicLink()){let e=V(l.name,t);this.resolveSymlink(e,this.state,(t,r)=>{if(t.isDirectory()){if(r=B(r,this.state.options),s&&s(l.name,u?r:e+d))return;this.walkDirectory(this.state,r,u?r:e+d,n-1,this.walk)}else{r=u?r:e;let t=p(r),n=B(m(r),this.state.options);r=this.joinPath(t,n),this.pushFile(r,h,this.state.counts,i)}})}}this.groupFiles(this.state.groups,t,h)}),this.isSynchronous=!n,this.callbackInvoker=Ne(t,this.isSynchronous),this.root=B(e,t),this.state={root:z(this.root)?this.root:this.root.slice(0,-1),paths:[``].slice(0,0),groups:[],counts:new ze,options:t,queue:new Re((e,t)=>this.callbackInvoker(t,e,n)),symlinks:new Map,visited:[``].slice(0,0),controller:new Be,fs:t.fs||u},this.joinPath=re(this.root,t),this.pushDirectory=oe(this.root,t),this.pushFile=fe(t),this.getArray=he(t),this.groupFiles=ve(t),this.resolveSymlink=xe(t,this.isSynchronous),this.walkDirectory=Le(this.isSynchronous)}start(){return this.pushDirectory(this.root,this.state.paths,this.state.options.filters),this.walkDirectory(this.state,this.root,this.root,this.state.options.maxDepth,this.walk),this.isSynchronous?this.callbackInvoker(this.state,null):null}};function He(e,t){return new Promise((n,r)=>{Ue(e,t,(e,t)=>{if(e)return r(e);n(t)})})}function Ue(e,t,n){new Ve(e,t,n).start()}function We(e,t){return new Ve(e,t).start()}var Ge=class{constructor(e,t){this.root=e,this.options=t}withPromise(){return He(this.root,this.options)}withCallback(e){Ue(this.root,this.options,e)}sync(){return We(this.root,this.options)}};let Ke=null;try{P.resolve(`picomatch`),Ke=P(`picomatch`)}catch{}var qe=class{constructor(e){N(this,`globCache`,{}),N(this,`options`,{maxDepth:1/0,suppressErrors:!0,pathSeparator:v,filters:[]}),N(this,`globFunction`,void 0),this.options={...this.options,...e},this.globFunction=this.options.globFunction}group(){return this.options.group=!0,this}withPathSeparator(e){return this.options.pathSeparator=e,this}withBasePath(){return this.options.includeBasePath=!0,this}withRelativePaths(){return this.options.relativePaths=!0,this}withDirs(){return this.options.includeDirs=!0,this}withMaxDepth(e){return this.options.maxDepth=e,this}withMaxFiles(e){return this.options.maxFiles=e,this}withFullPaths(){return this.options.resolvePaths=!0,this.options.includeBasePath=!0,this}withErrors(){return this.options.suppressErrors=!1,this}withSymlinks({resolvePaths:e=!0}={}){return this.options.resolveSymlinks=!0,this.options.useRealPaths=e,this.withFullPaths()}withAbortSignal(e){return this.options.signal=e,this}normalize(){return this.options.normalizePath=!0,this}filter(e){return this.options.filters.push(e),this}onlyDirs(){return this.options.excludeFiles=!0,this.options.includeDirs=!0,this}exclude(e){return this.options.exclude=e,this}onlyCounts(){return this.options.onlyCounts=!0,this}crawl(e){return new Ge(e||`.`,this.options)}withGlobFunction(e){return this.globFunction=e,this}crawlWithOptions(e,t){return this.options={...this.options,...t},new Ge(e||`.`,this.options)}glob(...e){return this.globFunction?this.globWithOptions(e):this.globWithOptions(e,{dot:!0})}globWithOptions(e,...t){let n=this.globFunction||Ke;if(!n)throw Error(`Please specify a glob function to use glob matching.`);var r=this.globCache[e.join(`\0`)];return r||(r=n(e,...t),this.globCache[e.join(`\0`)]=r),this.options.filters.push(e=>r(e)),this}},Je=O(((e,t)=>{let n=`[^\\\\/]`,r=`[^/]`,i=`(?:\\/|$)`,a=`(?:^|\\/)`,o=`\\.{1,2}${i}`,s={DOT_LITERAL:`\\.`,PLUS_LITERAL:`\\+`,QMARK_LITERAL:`\\?`,SLASH_LITERAL:`\\/`,ONE_CHAR:`(?=.)`,QMARK:r,END_ANCHOR:i,DOTS_SLASH:o,NO_DOT:`(?!\\.)`,NO_DOTS:`(?!${a}${o})`,NO_DOT_SLASH:`(?!\\.{0,1}${i})`,NO_DOTS_SLASH:`(?!${o})`,QMARK_NO_DOT:`[^.\\/]`,STAR:`${r}*?`,START_ANCHOR:a,SEP:`/`},c={...s,SLASH_LITERAL:`[\\\\/]`,QMARK:n,STAR:`${n}*?`,DOTS_SLASH:`\\.{1,2}(?:[\\\\/]|$)`,NO_DOT:`(?!\\.)`,NO_DOTS:`(?!(?:^|[\\\\/])\\.{1,2}(?:[\\\\/]|$))`,NO_DOT_SLASH:`(?!\\.{0,1}(?:[\\\\/]|$))`,NO_DOTS_SLASH:`(?!\\.{1,2}(?:[\\\\/]|$))`,QMARK_NO_DOT:`[^.\\\\/]`,START_ANCHOR:`(?:^|[\\\\/])`,END_ANCHOR:`(?:[\\\\/]|$)`,SEP:`\\`};t.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:{alnum:`a-zA-Z0-9`,alpha:`a-zA-Z`,ascii:`\\x00-\\x7F`,blank:` \\t`,cntrl:`\\x00-\\x1F\\x7F`,digit:`0-9`,graph:`\\x21-\\x7E`,lower:`a-z`,print:`\\x20-\\x7E `,punct:`\\-!"#$%&'()\\*+,./:;<=>?@[\\]^_\`{|}~`,space:` \\t\\r\\n\\v\\f`,upper:`A-Z`,word:`A-Za-z0-9_`,xdigit:`A-Fa-f0-9`},REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{__proto__:null,"***":`*`,"**/**":`**`,"**/**/**":`**`},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,extglobChars(e){return{"!":{type:`negate`,open:`(?:(?!(?:`,close:`))${e.STAR})`},"?":{type:`qmark`,open:`(?:`,close:`)?`},"+":{type:`plus`,open:`(?:`,close:`)+`},"*":{type:`star`,open:`(?:`,close:`)*`},"@":{type:`at`,open:`(?:`,close:`)`}}},globChars(e){return e===!0?c:s}}})),Ye=O((e=>{let{REGEX_BACKSLASH:t,REGEX_REMOVE_BACKSLASH:n,REGEX_SPECIAL_CHARS:r,REGEX_SPECIAL_CHARS_GLOBAL:i}=Je();e.isObject=e=>typeof e==`object`&&!!e&&!Array.isArray(e),e.hasRegexChars=e=>r.test(e),e.isRegexChar=t=>t.length===1&&e.hasRegexChars(t),e.escapeRegex=e=>e.replace(i,`\\$1`),e.toPosixSlashes=e=>e.replace(t,`/`),e.isWindows=()=>{if(typeof navigator<`u`&&navigator.platform){let e=navigator.platform.toLowerCase();return e===`win32`||e===`windows`}return typeof process<`u`&&process.platform?process.platform===`win32`:!1},e.removeBackslashes=e=>e.replace(n,e=>e===`\\`?``:e),e.escapeLast=(t,n,r)=>{let i=t.lastIndexOf(n,r);return i===-1?t:t[i-1]===`\\`?e.escapeLast(t,n,i-1):`${t.slice(0,i)}\\${t.slice(i)}`},e.removePrefix=(e,t={})=>{let n=e;return n.startsWith(`./`)&&(n=n.slice(2),t.prefix=`./`),n},e.wrapOutput=(e,t={},n={})=>{let r=`${n.contains?``:`^`}(?:${e})${n.contains?``:`$`}`;return t.negated===!0&&(r=`(?:^(?!${r}).*$)`),r},e.basename=(e,{windows:t}={})=>{let n=e.split(t?/[\\/]/:`/`),r=n[n.length-1];return r===``?n[n.length-2]:r}})),Xe=O(((e,t)=>{let n=Ye(),{CHAR_ASTERISK:r,CHAR_AT:i,CHAR_BACKWARD_SLASH:a,CHAR_COMMA:o,CHAR_DOT:s,CHAR_EXCLAMATION_MARK:c,CHAR_FORWARD_SLASH:l,CHAR_LEFT_CURLY_BRACE:u,CHAR_LEFT_PARENTHESES:d,CHAR_LEFT_SQUARE_BRACKET:f,CHAR_PLUS:p,CHAR_QUESTION_MARK:m,CHAR_RIGHT_CURLY_BRACE:h,CHAR_RIGHT_PARENTHESES:g,CHAR_RIGHT_SQUARE_BRACKET:ee}=Je(),_=e=>e===l||e===a,v=e=>{e.isPrefix!==!0&&(e.depth=e.isGlobstar?1/0:1)};t.exports=(e,t)=>{let y=t||{},b=e.length-1,x=y.parts===!0||y.scanToEnd===!0,S=[],C=[],w=[],T=e,E=-1,D=0,O=0,k=!1,te=!1,A=!1,j=!1,ne=!1,M=!1,N=!1,P=!1,F=!1,I=!1,L=0,R,z,B={value:``,depth:0,isGlob:!1},V=()=>E>=b,H=()=>T.charCodeAt(E+1),U=()=>(R=z,T.charCodeAt(++E));for(;E<b;){z=U();let e;if(z===a){N=B.backslashes=!0,z=U(),z===u&&(M=!0);continue}if(M===!0||z===u){for(L++;V()!==!0&&(z=U());){if(z===a){N=B.backslashes=!0,U();continue}if(z===u){L++;continue}if(M!==!0&&z===s&&(z=U())===s){if(k=B.isBrace=!0,A=B.isGlob=!0,I=!0,x===!0)continue;break}if(M!==!0&&z===o){if(k=B.isBrace=!0,A=B.isGlob=!0,I=!0,x===!0)continue;break}if(z===h&&(L--,L===0)){M=!1,k=B.isBrace=!0,I=!0;break}}if(x===!0)continue;break}if(z===l){if(S.push(E),C.push(B),B={value:``,depth:0,isGlob:!1},I===!0)continue;if(R===s&&E===D+1){D+=2;continue}O=E+1;continue}if(y.noext!==!0&&(z===p||z===i||z===r||z===m||z===c)&&H()===d){if(A=B.isGlob=!0,j=B.isExtglob=!0,I=!0,z===c&&E===D&&(F=!0),x===!0){for(;V()!==!0&&(z=U());){if(z===a){N=B.backslashes=!0,z=U();continue}if(z===g){A=B.isGlob=!0,I=!0;break}}continue}break}if(z===r){if(R===r&&(ne=B.isGlobstar=!0),A=B.isGlob=!0,I=!0,x===!0)continue;break}if(z===m){if(A=B.isGlob=!0,I=!0,x===!0)continue;break}if(z===f){for(;V()!==!0&&(e=U());){if(e===a){N=B.backslashes=!0,U();continue}if(e===ee){te=B.isBracket=!0,A=B.isGlob=!0,I=!0;break}}if(x===!0)continue;break}if(y.nonegate!==!0&&z===c&&E===D){P=B.negated=!0,D++;continue}if(y.noparen!==!0&&z===d){if(A=B.isGlob=!0,x===!0){for(;V()!==!0&&(z=U());){if(z===d){N=B.backslashes=!0,z=U();continue}if(z===g){I=!0;break}}continue}break}if(A===!0){if(I=!0,x===!0)continue;break}}y.noext===!0&&(j=!1,A=!1);let W=T,re=``,G=``;D>0&&(re=T.slice(0,D),T=T.slice(D),O-=D),W&&A===!0&&O>0?(W=T.slice(0,O),G=T.slice(O)):A===!0?(W=``,G=T):W=T,W&&W!==``&&W!==`/`&&W!==T&&_(W.charCodeAt(W.length-1))&&(W=W.slice(0,-1)),y.unescape===!0&&(G&&(G=n.removeBackslashes(G)),W&&N===!0&&(W=n.removeBackslashes(W)));let K={prefix:re,input:e,start:D,base:W,glob:G,isBrace:k,isBracket:te,isGlob:A,isExtglob:j,isGlobstar:ne,negated:P,negatedExtglob:F};if(y.tokens===!0&&(K.maxDepth=0,_(z)||C.push(B),K.tokens=C),y.parts===!0||y.tokens===!0){let t;for(let n=0;n<S.length;n++){let r=t?t+1:D,i=S[n],a=e.slice(r,i);y.tokens&&(n===0&&D!==0?(C[n].isPrefix=!0,C[n].value=re):C[n].value=a,v(C[n]),K.maxDepth+=C[n].depth),(n!==0||a!==``)&&w.push(a),t=i}if(t&&t+1<e.length){let n=e.slice(t+1);w.push(n),y.tokens&&(C[C.length-1].value=n,v(C[C.length-1]),K.maxDepth+=C[C.length-1].depth)}K.slashes=S,K.parts=w}return K}})),Ze=O(((e,t)=>{let n=Je(),r=Ye(),{MAX_LENGTH:i,POSIX_REGEX_SOURCE:a,REGEX_NON_SPECIAL_CHARS:o,REGEX_SPECIAL_CHARS_BACKREF:s,REPLACEMENTS:c}=n,l=(e,t)=>{if(typeof t.expandRange==`function`)return t.expandRange(...e,t);e.sort();let n=`[${e.join(`-`)}]`;try{new RegExp(n)}catch{return e.map(e=>r.escapeRegex(e)).join(`..`)}return n},u=(e,t)=>`Missing ${e}: "${t}" - use "\\\\${t}" to match literal characters`,d=(e,t)=>{if(typeof e!=`string`)throw TypeError(`Expected a string`);e=c[e]||e;let f={...t},p=typeof f.maxLength==`number`?Math.min(i,f.maxLength):i,m=e.length;if(m>p)throw SyntaxError(`Input length: ${m}, exceeds maximum allowed length: ${p}`);let h={type:`bos`,value:``,output:f.prepend||``},g=[h],ee=f.capture?``:`?:`,_=n.globChars(f.windows),v=n.extglobChars(_),{DOT_LITERAL:y,PLUS_LITERAL:b,SLASH_LITERAL:x,ONE_CHAR:S,DOTS_SLASH:C,NO_DOT:w,NO_DOT_SLASH:T,NO_DOTS_SLASH:E,QMARK:D,QMARK_NO_DOT:O,STAR:k,START_ANCHOR:te}=_,A=e=>`(${ee}(?:(?!${te}${e.dot?C:y}).)*?)`,j=f.dot?``:w,ne=f.dot?D:O,M=f.bash===!0?A(f):k;f.capture&&(M=`(${M})`),typeof f.noext==`boolean`&&(f.noextglob=f.noext);let N={input:e,index:-1,start:0,dot:f.dot===!0,consumed:``,output:``,prefix:``,backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:g};e=r.removePrefix(e,N),m=e.length;let P=[],F=[],I=[],L=h,R,z=()=>N.index===m-1,B=N.peek=(t=1)=>e[N.index+t],V=N.advance=()=>e[++N.index]||``,H=()=>e.slice(N.index+1),U=(e=``,t=0)=>{N.consumed+=e,N.index+=t},W=e=>{N.output+=e.output==null?e.value:e.output,U(e.value)},re=()=>{let e=1;for(;B()===`!`&&(B(2)!==`(`||B(3)===`?`);)V(),N.start++,e++;return e%2==0?!1:(N.negated=!0,N.start++,!0)},G=e=>{N[e]++,I.push(e)},K=e=>{N[e]--,I.pop()},q=e=>{if(L.type===`globstar`){let t=N.braces>0&&(e.type===`comma`||e.type===`brace`),n=e.extglob===!0||P.length&&(e.type===`pipe`||e.type===`paren`);e.type!==`slash`&&e.type!==`paren`&&!t&&!n&&(N.output=N.output.slice(0,-L.output.length),L.type=`star`,L.value=`*`,L.output=M,N.output+=L.output)}if(P.length&&e.type!==`paren`&&(P[P.length-1].inner+=e.value),(e.value||e.output)&&W(e),L&&L.type===`text`&&e.type===`text`){L.output=(L.output||L.value)+e.value,L.value+=e.value;return}e.prev=L,g.push(e),L=e},ie=(e,t)=>{let n={...v[t],conditions:1,inner:``};n.prev=L,n.parens=N.parens,n.output=N.output;let r=(f.capture?`(`:``)+n.open;G(`parens`),q({type:e,value:t,output:N.output?``:S}),q({type:`paren`,extglob:!0,value:V(),output:r}),P.push(n)},ae=e=>{let n=e.close+(f.capture?`)`:``),r;if(e.type===`negate`){let i=M;e.inner&&e.inner.length>1&&e.inner.includes(`/`)&&(i=A(f)),(i!==M||z()||/^\)+$/.test(H()))&&(n=e.close=`)$))${i}`),e.inner.includes(`*`)&&(r=H())&&/^\.[^\\/.]+$/.test(r)&&(n=e.close=`)${d(r,{...t,fastpaths:!1}).output})${i})`),e.prev.type===`bos`&&(N.negatedExtglob=!0)}q({type:`paren`,extglob:!0,value:R,output:n}),K(`parens`)};if(f.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(e)){let n=!1,i=e.replace(s,(e,t,r,i,a,o)=>i===`\\`?(n=!0,e):i===`?`?t?t+i+(a?D.repeat(a.length):``):o===0?ne+(a?D.repeat(a.length):``):D.repeat(r.length):i===`.`?y.repeat(r.length):i===`*`?t?t+i+(a?M:``):M:t?e:`\\${e}`);return n===!0&&(i=f.unescape===!0?i.replace(/\\/g,``):i.replace(/\\+/g,e=>e.length%2==0?`\\\\`:e?`\\`:``)),i===e&&f.contains===!0?(N.output=e,N):(N.output=r.wrapOutput(i,N,t),N)}for(;!z();){if(R=V(),R===`\0`)continue;if(R===`\\`){let e=B();if(e===`/`&&f.bash!==!0||e===`.`||e===`;`)continue;if(!e){R+=`\\`,q({type:`text`,value:R});continue}let t=/^\\+/.exec(H()),n=0;if(t&&t[0].length>2&&(n=t[0].length,N.index+=n,n%2!=0&&(R+=`\\`)),f.unescape===!0?R=V():R+=V(),N.brackets===0){q({type:`text`,value:R});continue}}if(N.brackets>0&&(R!==`]`||L.value===`[`||L.value===`[^`)){if(f.posix!==!1&&R===`:`){let e=L.value.slice(1);if(e.includes(`[`)&&(L.posix=!0,e.includes(`:`))){let e=L.value.lastIndexOf(`[`),t=L.value.slice(0,e),n=a[L.value.slice(e+2)];if(n){L.value=t+n,N.backtrack=!0,V(),!h.output&&g.indexOf(L)===1&&(h.output=S);continue}}}(R===`[`&&B()!==`:`||R===`-`&&B()===`]`)&&(R=`\\${R}`),R===`]`&&(L.value===`[`||L.value===`[^`)&&(R=`\\${R}`),f.posix===!0&&R===`!`&&L.value===`[`&&(R=`^`),L.value+=R,W({value:R});continue}if(N.quotes===1&&R!==`"`){R=r.escapeRegex(R),L.value+=R,W({value:R});continue}if(R===`"`){N.quotes=N.quotes===1?0:1,f.keepQuotes===!0&&q({type:`text`,value:R});continue}if(R===`(`){G(`parens`),q({type:`paren`,value:R});continue}if(R===`)`){if(N.parens===0&&f.strictBrackets===!0)throw SyntaxError(u(`opening`,`(`));let e=P[P.length-1];if(e&&N.parens===e.parens+1){ae(P.pop());continue}q({type:`paren`,value:R,output:N.parens?`)`:`\\)`}),K(`parens`);continue}if(R===`[`){if(f.nobracket===!0||!H().includes(`]`)){if(f.nobracket!==!0&&f.strictBrackets===!0)throw SyntaxError(u(`closing`,`]`));R=`\\${R}`}else G(`brackets`);q({type:`bracket`,value:R});continue}if(R===`]`){if(f.nobracket===!0||L&&L.type===`bracket`&&L.value.length===1){q({type:`text`,value:R,output:`\\${R}`});continue}if(N.brackets===0){if(f.strictBrackets===!0)throw SyntaxError(u(`opening`,`[`));q({type:`text`,value:R,output:`\\${R}`});continue}K(`brackets`);let e=L.value.slice(1);if(L.posix!==!0&&e[0]===`^`&&!e.includes(`/`)&&(R=`/${R}`),L.value+=R,W({value:R}),f.literalBrackets===!1||r.hasRegexChars(e))continue;let t=r.escapeRegex(L.value);if(N.output=N.output.slice(0,-L.value.length),f.literalBrackets===!0){N.output+=t,L.value=t;continue}L.value=`(${ee}${t}|${L.value})`,N.output+=L.value;continue}if(R===`{`&&f.nobrace!==!0){G(`braces`);let e={type:`brace`,value:R,output:`(`,outputIndex:N.output.length,tokensIndex:N.tokens.length};F.push(e),q(e);continue}if(R===`}`){let e=F[F.length-1];if(f.nobrace===!0||!e){q({type:`text`,value:R,output:R});continue}let t=`)`;if(e.dots===!0){let e=g.slice(),n=[];for(let t=e.length-1;t>=0&&(g.pop(),e[t].type!==`brace`);t--)e[t].type!==`dots`&&n.unshift(e[t].value);t=l(n,f),N.backtrack=!0}if(e.comma!==!0&&e.dots!==!0){let n=N.output.slice(0,e.outputIndex),r=N.tokens.slice(e.tokensIndex);e.value=e.output=`\\{`,R=t=`\\}`,N.output=n;for(let e of r)N.output+=e.output||e.value}q({type:`brace`,value:R,output:t}),K(`braces`),F.pop();continue}if(R===`|`){P.length>0&&P[P.length-1].conditions++,q({type:`text`,value:R});continue}if(R===`,`){let e=R,t=F[F.length-1];t&&I[I.length-1]===`braces`&&(t.comma=!0,e=`|`),q({type:`comma`,value:R,output:e});continue}if(R===`/`){if(L.type===`dot`&&N.index===N.start+1){N.start=N.index+1,N.consumed=``,N.output=``,g.pop(),L=h;continue}q({type:`slash`,value:R,output:x});continue}if(R===`.`){if(N.braces>0&&L.type===`dot`){L.value===`.`&&(L.output=y);let e=F[F.length-1];L.type=`dots`,L.output+=R,L.value+=R,e.dots=!0;continue}if(N.braces+N.parens===0&&L.type!==`bos`&&L.type!==`slash`){q({type:`text`,value:R,output:y});continue}q({type:`dot`,value:R,output:y});continue}if(R===`?`){if(!(L&&L.value===`(`)&&f.noextglob!==!0&&B()===`(`&&B(2)!==`?`){ie(`qmark`,R);continue}if(L&&L.type===`paren`){let e=B(),t=R;(L.value===`(`&&!/[!=<:]/.test(e)||e===`<`&&!/<([!=]|\w+>)/.test(H()))&&(t=`\\${R}`),q({type:`text`,value:R,output:t});continue}if(f.dot!==!0&&(L.type===`slash`||L.type===`bos`)){q({type:`qmark`,value:R,output:O});continue}q({type:`qmark`,value:R,output:D});continue}if(R===`!`){if(f.noextglob!==!0&&B()===`(`&&(B(2)!==`?`||!/[!=<:]/.test(B(3)))){ie(`negate`,R);continue}if(f.nonegate!==!0&&N.index===0){re();continue}}if(R===`+`){if(f.noextglob!==!0&&B()===`(`&&B(2)!==`?`){ie(`plus`,R);continue}if(L&&L.value===`(`||f.regex===!1){q({type:`plus`,value:R,output:b});continue}if(L&&(L.type===`bracket`||L.type===`paren`||L.type===`brace`)||N.parens>0){q({type:`plus`,value:R});continue}q({type:`plus`,value:b});continue}if(R===`@`){if(f.noextglob!==!0&&B()===`(`&&B(2)!==`?`){q({type:`at`,extglob:!0,value:R,output:``});continue}q({type:`text`,value:R});continue}if(R!==`*`){(R===`$`||R===`^`)&&(R=`\\${R}`);let e=o.exec(H());e&&(R+=e[0],N.index+=e[0].length),q({type:`text`,value:R});continue}if(L&&(L.type===`globstar`||L.star===!0)){L.type=`star`,L.star=!0,L.value+=R,L.output=M,N.backtrack=!0,N.globstar=!0,U(R);continue}let t=H();if(f.noextglob!==!0&&/^\([^?]/.test(t)){ie(`star`,R);continue}if(L.type===`star`){if(f.noglobstar===!0){U(R);continue}let n=L.prev,r=n.prev,i=n.type===`slash`||n.type===`bos`,a=r&&(r.type===`star`||r.type===`globstar`);if(f.bash===!0&&(!i||t[0]&&t[0]!==`/`)){q({type:`star`,value:R,output:``});continue}let o=N.braces>0&&(n.type===`comma`||n.type===`brace`),s=P.length&&(n.type===`pipe`||n.type===`paren`);if(!i&&n.type!==`paren`&&!o&&!s){q({type:`star`,value:R,output:``});continue}for(;t.slice(0,3)===`/**`;){let n=e[N.index+4];if(n&&n!==`/`)break;t=t.slice(3),U(`/**`,3)}if(n.type===`bos`&&z()){L.type=`globstar`,L.value+=R,L.output=A(f),N.output=L.output,N.globstar=!0,U(R);continue}if(n.type===`slash`&&n.prev.type!==`bos`&&!a&&z()){N.output=N.output.slice(0,-(n.output+L.output).length),n.output=`(?:${n.output}`,L.type=`globstar`,L.output=A(f)+(f.strictSlashes?`)`:`|$)`),L.value+=R,N.globstar=!0,N.output+=n.output+L.output,U(R);continue}if(n.type===`slash`&&n.prev.type!==`bos`&&t[0]===`/`){let e=t[1]===void 0?``:`|$`;N.output=N.output.slice(0,-(n.output+L.output).length),n.output=`(?:${n.output}`,L.type=`globstar`,L.output=`${A(f)}${x}|${x}${e})`,L.value+=R,N.output+=n.output+L.output,N.globstar=!0,U(R+V()),q({type:`slash`,value:`/`,output:``});continue}if(n.type===`bos`&&t[0]===`/`){L.type=`globstar`,L.value+=R,L.output=`(?:^|${x}|${A(f)}${x})`,N.output=L.output,N.globstar=!0,U(R+V()),q({type:`slash`,value:`/`,output:``});continue}N.output=N.output.slice(0,-L.output.length),L.type=`globstar`,L.output=A(f),L.value+=R,N.output+=L.output,N.globstar=!0,U(R);continue}let n={type:`star`,value:R,output:M};if(f.bash===!0){n.output=`.*?`,(L.type===`bos`||L.type===`slash`)&&(n.output=j+n.output),q(n);continue}if(L&&(L.type===`bracket`||L.type===`paren`)&&f.regex===!0){n.output=R,q(n);continue}(N.index===N.start||L.type===`slash`||L.type===`dot`)&&(L.type===`dot`?(N.output+=T,L.output+=T):f.dot===!0?(N.output+=E,L.output+=E):(N.output+=j,L.output+=j),B()!==`*`&&(N.output+=S,L.output+=S)),q(n)}for(;N.brackets>0;){if(f.strictBrackets===!0)throw SyntaxError(u(`closing`,`]`));N.output=r.escapeLast(N.output,`[`),K(`brackets`)}for(;N.parens>0;){if(f.strictBrackets===!0)throw SyntaxError(u(`closing`,`)`));N.output=r.escapeLast(N.output,`(`),K(`parens`)}for(;N.braces>0;){if(f.strictBrackets===!0)throw SyntaxError(u(`closing`,`}`));N.output=r.escapeLast(N.output,`{`),K(`braces`)}if(f.strictSlashes!==!0&&(L.type===`star`||L.type===`bracket`)&&q({type:`maybe_slash`,value:``,output:`${x}?`}),N.backtrack===!0){N.output=``;for(let e of N.tokens)N.output+=e.output==null?e.value:e.output,e.suffix&&(N.output+=e.suffix)}return N};d.fastpaths=(e,t)=>{let a={...t},o=typeof a.maxLength==`number`?Math.min(i,a.maxLength):i,s=e.length;if(s>o)throw SyntaxError(`Input length: ${s}, exceeds maximum allowed length: ${o}`);e=c[e]||e;let{DOT_LITERAL:l,SLASH_LITERAL:u,ONE_CHAR:d,DOTS_SLASH:f,NO_DOT:p,NO_DOTS:m,NO_DOTS_SLASH:h,STAR:g,START_ANCHOR:ee}=n.globChars(a.windows),_=a.dot?m:p,v=a.dot?h:p,y=a.capture?``:`?:`,b={negated:!1,prefix:``},x=a.bash===!0?`.*?`:g;a.capture&&(x=`(${x})`);let S=e=>e.noglobstar===!0?x:`(${y}(?:(?!${ee}${e.dot?f:l}).)*?)`,C=e=>{switch(e){case`*`:return`${_}${d}${x}`;case`.*`:return`${l}${d}${x}`;case`*.*`:return`${_}${x}${l}${d}${x}`;case`*/*`:return`${_}${x}${u}${d}${v}${x}`;case`**`:return _+S(a);case`**/*`:return`(?:${_}${S(a)}${u})?${v}${d}${x}`;case`**/*.*`:return`(?:${_}${S(a)}${u})?${v}${x}${l}${d}${x}`;case`**/.*`:return`(?:${_}${S(a)}${u})?${l}${d}${x}`;default:{let t=/^(.*?)\.(\w+)$/.exec(e);if(!t)return;let n=C(t[1]);return n?n+l+t[2]:void 0}}},w=C(r.removePrefix(e,b));return w&&a.strictSlashes!==!0&&(w+=`${u}?`),w},t.exports=d})),Qe=O(((e,t)=>{let n=Xe(),r=Ze(),i=Ye(),a=Je(),o=e=>e&&typeof e==`object`&&!Array.isArray(e),s=(e,t,n=!1)=>{if(Array.isArray(e)){let r=e.map(e=>s(e,t,n));return e=>{for(let t of r){let n=t(e);if(n)return n}return!1}}let r=o(e)&&e.tokens&&e.input;if(e===``||typeof e!=`string`&&!r)throw TypeError(`Expected pattern to be a non-empty string`);let i=t||{},a=i.windows,c=r?s.compileRe(e,t):s.makeRe(e,t,!1,!0),l=c.state;delete c.state;let u=()=>!1;if(i.ignore){let e={...t,ignore:null,onMatch:null,onResult:null};u=s(i.ignore,e,n)}let d=(n,r=!1)=>{let{isMatch:o,match:d,output:f}=s.test(n,c,t,{glob:e,posix:a}),p={glob:e,state:l,regex:c,posix:a,input:n,output:f,match:d,isMatch:o};return typeof i.onResult==`function`&&i.onResult(p),o===!1?(p.isMatch=!1,r?p:!1):u(n)?(typeof i.onIgnore==`function`&&i.onIgnore(p),p.isMatch=!1,r?p:!1):(typeof i.onMatch==`function`&&i.onMatch(p),r?p:!0)};return n&&(d.state=l),d};s.test=(e,t,n,{glob:r,posix:a}={})=>{if(typeof e!=`string`)throw TypeError(`Expected input to be a string`);if(e===``)return{isMatch:!1,output:``};let o=n||{},c=o.format||(a?i.toPosixSlashes:null),l=e===r,u=l&&c?c(e):e;return l===!1&&(u=c?c(e):e,l=u===r),(l===!1||o.capture===!0)&&(l=o.matchBase===!0||o.basename===!0?s.matchBase(e,t,n,a):t.exec(u)),{isMatch:!!l,match:l,output:u}},s.matchBase=(e,t,n)=>(t instanceof RegExp?t:s.makeRe(t,n)).test(i.basename(e)),s.isMatch=(e,t,n)=>s(t,n)(e),s.parse=(e,t)=>Array.isArray(e)?e.map(e=>s.parse(e,t)):r(e,{...t,fastpaths:!1}),s.scan=(e,t)=>n(e,t),s.compileRe=(e,t,n=!1,r=!1)=>{if(n===!0)return e.output;let i=t||{},a=i.contains?``:`^`,o=i.contains?``:`$`,c=`${a}(?:${e.output})${o}`;e&&e.negated===!0&&(c=`^(?!${c}).*$`);let l=s.toRegex(c,t);return r===!0&&(l.state=e),l},s.makeRe=(e,t={},n=!1,i=!1)=>{if(!e||typeof e!=`string`)throw TypeError(`Expected a non-empty string`);let a={negated:!1,fastpaths:!0};return t.fastpaths!==!1&&(e[0]===`.`||e[0]===`*`)&&(a.output=r.fastpaths(e,t)),a.output||(a=r(e,t)),s.compileRe(a,t,n,i)},s.toRegex=(e,t)=>{try{let n=t||{};return new RegExp(e,n.flags||(n.nocase?`i`:``))}catch(e){if(t&&t.debug===!0)throw e;return/$^/}},s.constants=a,t.exports=s})),J=te(O(((e,t)=>{let n=Qe(),r=Ye();function i(e,t,i=!1){return t&&(t.windows===null||t.windows===void 0)&&(t={...t,windows:r.isWindows()}),n(e,t,i)}Object.assign(i,n),t.exports=i}))(),1);const $e=Array.isArray,et=process.platform===`win32`,tt=/^(\/?\.\.)+$/;function nt(e,t={}){let n=e.length,r=Array(n),i=Array(n),a=!t.noglobstar;for(let a=0;a<n;a++){let n=ct(e[a]);r[a]=n;let o=n.length,s=Array(o);for(let e=0;e<o;e++)s[e]=(0,J.default)(n[e],t);i[a]=s}return t=>{let n=t.split(`/`);if(n[0]===`..`&&tt.test(t))return!0;for(let t=0;t<e.length;t++){let e=r[t],o=i[t],s=n.length,c=Math.min(s,e.length),l=0;for(;l<c;){let t=e[l];if(t.includes(`/`))return!0;if(!o[l](n[l]))break;if(a&&t===`**`)return!0;l++}if(l===s)return!0}return!1}}const rt=/^[A-Z]:\/$/i,it=et?e=>rt.test(e):e=>e===`/`;function at(e,t,n){if(e===t||t.startsWith(`${e}/`)){if(n){let t=it(e)?e.length:e.length+1;return(e,n)=>e.slice(t,n?-1:void 0)||`.`}let r=t.slice(e.length+1);return r?(e,t)=>{if(e===`.`)return r;let n=`${r}/${e}`;return t?n.slice(0,-1):n}:(e,t)=>t&&e!==`.`?e.slice(0,-1):e}return n?t=>g.relative(e,t)||`.`:n=>g.relative(e,`${t}/${n}`)||`.`}function ot(e,t){if(t.startsWith(`${e}/`)){let n=t.slice(e.length+1);return e=>`${n}/${e}`}return n=>{let r=g.relative(e,`${t}/${n}`);return n.endsWith(`/`)&&r!==``?`${r}/`:r||`.`}}const st={parts:!0};function ct(e){let t=J.default.scan(e,st);return t.parts?.length?t.parts:[e]}const lt=/(?<!\\)([()[\]{}*?|]|^!|[!+@](?=\()|\\(?![()[\]{}!*+?@|]))/g,ut=/(?<!\\)([()[\]{}]|^!|[!+@](?=\())/g,dt=et?e=>e.replace(ut,`\\$&`):e=>e.replace(lt,`\\$&`);function ft(e,t){if(t?.caseSensitiveMatch===!1)return!0;let n=J.default.scan(e);return n.isGlob||n.negated}function Y(...e){console.log(`[tinyglobby ${new Date().toLocaleTimeString(`es`)}]`,...e)}const pt=/^(\/?\.\.)+/,mt=/\\(?=[()[\]{}!*+?@|])/g,ht=/\\/g;function gt(e,t,n,r,i){let a=e;e.endsWith(`/`)&&(a=e.slice(0,-1)),!a.endsWith(`*`)&&t&&(a+=`/**`);let o=dt(n);a=f.isAbsolute(a.replace(mt,``))?g.relative(o,a):g.normalize(a);let s=pt.exec(a),c=ct(a);if(s?.[0]){let e=(s[0].length+1)/3,t=0,i=o.split(`/`);for(;t<e&&c[t+e]===i[i.length+t-e];)a=a.slice(0,(e-t-1)*3)+a.slice((e-t)*3+c[t+e].length+1)||`.`,t++;let l=g.join(n,s[0].slice(t*3));!l.startsWith(`.`)&&r.root.length>l.length&&(r.root=l,r.depthOffset=-e+t)}if(!i&&r.depthOffset>=0){r.commonPath??(r.commonPath=c);let e=[],t=Math.min(r.commonPath.length,c.length);for(let n=0;n<t;n++){let t=c[n];if(t===`**`&&!c[n+1]){e.pop();break}if(t!==r.commonPath[n]||ft(t)||n===c.length-1)break;e.push(t)}r.depthOffset=e.length,r.commonPath=e,r.root=e.length>0?g.join(n,...e):n}return a}function _t({patterns:e=[`**/*`],ignore:t=[],expandDirectories:n=!0},r,i){typeof e==`string`&&(e=[e]),typeof t==`string`&&(t=[t]);let a=[],o=[];for(let e of t)e&&(e[0]!==`!`||e[1]===`(`)&&o.push(gt(e,n,r,i,!0));for(let t of e)t&&(t[0]!==`!`||t[1]===`(`?a.push(gt(t,n,r,i,!1)):(t[1]!==`!`||t[2]===`(`)&&o.push(gt(t.slice(1),n,r,i,!0)));return{match:a,ignore:o}}function vt(e,t){for(let n=e.length-1;n>=0;n--){let r=e[n];e[n]=t(r)}return e}function yt(e){return e?e instanceof URL?y(e).replace(ht,`/`):f.resolve(e).replace(ht,`/`):process.cwd().replace(ht,`/`)}function bt(e,t={}){let n=process.env.TINYGLOBBY_DEBUG?{...t,debug:!0}:t,r=yt(n.cwd);if(n.debug&&Y(`globbing with:`,{patterns:e,options:n,cwd:r}),Array.isArray(e)&&e.length===0)return[{sync:()=>[],withPromise:async()=>[]},!1];let i={root:r,commonPath:null,depthOffset:0},a=_t({...n,patterns:e},r,i);n.debug&&Y(`internal processing patterns:`,a);let o={dot:n.dot,nobrace:n.braceExpansion===!1,nocase:n.caseSensitiveMatch===!1,noextglob:n.extglob===!1,noglobstar:n.globstar===!1,posix:!0},s=(0,J.default)(a.match,{...o,ignore:a.ignore}),c=(0,J.default)(a.ignore,o),l=nt(a.match,o),u=at(r,i.root,n.absolute),f=n.absolute?u:at(r,i.root,!0),p={filters:[n.debug?(e,t)=>{let n=u(e,t),r=s(n);return r&&Y(`matched ${n}`),r}:(e,t)=>s(u(e,t))],exclude:n.debug?(e,t)=>{let n=f(t,!0),r=n!==`.`&&!l(n)||c(n);return Y(r?`skipped ${t}`:`crawling ${t}`),r}:(e,t)=>{let n=f(t,!0);return n!==`.`&&!l(n)||c(n)},fs:n.fs?{readdir:n.fs.readdir||d.readdir,readdirSync:n.fs.readdirSync||d.readdirSync,realpath:n.fs.realpath||d.realpath,realpathSync:n.fs.realpathSync||d.realpathSync,stat:n.fs.stat||d.stat,statSync:n.fs.statSync||d.statSync}:void 0,pathSeparator:`/`,relativePaths:!0,resolveSymlinks:!0,signal:n.signal};n.deep!==void 0&&(p.maxDepth=Math.round(n.deep-i.depthOffset)),n.absolute&&(p.relativePaths=!1,p.resolvePaths=!0,p.includeBasePath=!0),n.followSymbolicLinks===!1&&(p.resolveSymlinks=!1,p.excludeSymlinks=!0),n.onlyDirectories?(p.excludeFiles=!0,p.includeDirs=!0):n.onlyFiles===!1&&(p.includeDirs=!0),i.root=i.root.replace(ht,``);let m=i.root;n.debug&&Y(`internal properties:`,i);let h=r!==m&&!n.absolute&&ot(r,i.root);return[new qe(p).crawl(m),h]}async function xt(e,t){if(e&&t?.patterns)throw Error(`Cannot pass patterns as both an argument and an option`);let n=$e(e)||typeof e==`string`,r=n?t:e,[i,a]=bt(n?e:e.patterns,r);return a?vt(await i.withPromise(),a):i.withPromise()}let St={};function Ct(){return St}function wt(e){St=e}function Tt(e){let t=JSON.stringify(e);return St.configHash!==t}async function Et(e){return{css:r(await n(e.source),e),dependencies:e.source}}const X={active:`●`,done:`✓`,error:`✗`,processing:`◉`,waiting:`○`};function Dt(){process.stdout.isTTY&&process.stdout.write(`\x1B[2K\x1B[0G`)}function Z(e,t,n=`stdout`){let r=`${e} ${t}`;n===`stderr`?process.stderr.write(`${r}\n`):process.stdout.write(`${r}\n`)}function Ot(e){return Z(X.waiting,e),{succeed:e=>{Dt(),Z(X.done,e)},fail:e=>{Dt(),Z(X.error,e,`stderr`)},stop:()=>{Dt()}}}function kt(e,t=``){if(e.length===0)return;let n=e.slice(0,10),r=e.length-10;n.forEach((e,i)=>{Z(i===n.length-1&&r<=0?`└`:`├`,t?e.replace(t,``).replace(/^[/\\]/,``):e)}),r>0&&Z(``,`+ ${r} more files`)}const Q={header(e){process.stdout.write(`${X.active} Yumma CSS ${e}\n`)},fail(e){Z(X.error,e,`stderr`)},build:{start(){return Ot(`Collecting classes...`)},success(e,t){return`Collected ${t.toLocaleString()} classes in ${e}ms`},fail(e){return`Something went wrong. ${e instanceof Error?e.message:`Check your files & try again.`}`},compiling(e){return Z(X.processing,`Compiling CSS...`),kt(e),{success:(e,t)=>{Z(X.done,`Generated ${e} (${(t/1024).toFixed(1)}KB)`)},fail:e=>`Compilation failed. ${e instanceof Error?e.message:`Check your files & try again.`}`}},written(e){return`Done in ${e}ms`}},watch:{start(){return Ot(`Collecting classes...`)},success(e){return`Watching for changes. (${e.toLocaleString()} classes)`},fail(){return`Something went wrong. Check your files & try again.`},compiling(e){return Z(X.processing,`Compiling CSS...`),kt(e),{success:(e,t)=>{Z(X.done,`${e} (${(t/1024).toFixed(1)}KB)`)},fail:()=>{Z(X.error,`Failed to compile. Check your files.`)}}}},init:{start(){return Ot(`Initializing...`)},success(e){return`Created ${e}`},fail(){return`Something went wrong. Check the docs & try again.`},notFound(){return`No config found. Run 'yummacss init' to create one.`},invalid(){return`Invalid config. Check the syntax & try again.`}}};async function At(){let n=x(l(process.cwd(),t)).href;try{let{default:t}=await import(n);return e.parse(t)}catch{return i(t)?(Q.fail(Q.init.invalid()),process.exit(1)):(Q.fail(Q.init.notFound()),process.exit(1))}}async function jt(e,t=!1){let n=Q.build.start(),r=Date.now();try{let i=e||await At(),o=Ct(),l=Tt(i),u;if(t||l||!o.css){let e=await Et(i);u=e.css,e.dependencies,wt({configHash:JSON.stringify(i),css:e.css,dependencies:e.dependencies})}else u=o.css??``,o.dependencies;let d=await xt(i.source??[]),f=Array.from(d).length;if(n.succeed(Q.build.success(Date.now()-r,f)),!i.output)throw Error(`No output path specified in config.`);let p=Q.build.compiling(d),m=Date.now();a(c(i.output),{recursive:!0}),s(i.output,u),p.success(i.output,Buffer.byteLength(u,`utf-8`)),process.stdout.write(`${Q.build.written(Date.now()-m)}\n`)}catch(e){n.fail(Q.build.fail(e)),process.exit(1)}}function Mt(){return{filename:t,content:`export default {
2
+ import{configName as e,extractor as t,generator as n,loadConfig as r}from"@yummacss/nitro";import{existsSync as i,mkdirSync as a,watch as o,writeFileSync as s}from"node:fs";import{dirname as c}from"node:path";import*as l from"fs";import u from"fs";import d,{basename as f,dirname as p,normalize as m,posix as h,relative as g,resolve as ee,sep as _}from"path";import{fileURLToPath as v}from"url";import{createRequire as y}from"module";var b=Object.create,x=Object.defineProperty,S=Object.getOwnPropertyDescriptor,C=Object.getOwnPropertyNames,w=Object.getPrototypeOf,T=Object.prototype.hasOwnProperty,E=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),D=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(var i=C(t),a=0,o=i.length,s;a<o;a++)s=i[a],!T.call(e,s)&&s!==n&&x(e,s,{get:(e=>t[e]).bind(null,s),enumerable:!(r=S(t,s))||r.enumerable});return e},O=(e,t,n)=>(n=e==null?{}:b(w(e)),D(t||!e||!e.__esModule?x(n,`default`,{value:e,enumerable:!0}):n,e)),k=`3.26.0`;function A(e){"@babel/helpers - typeof";return A=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},A(e)}function j(e,t){if(A(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(A(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function M(e){var t=j(e,`string`);return A(t)==`symbol`?t:t+``}function N(e,t,n){return(t=M(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var P=y(import.meta.url);function F(e){let t=m(e);return t.length>1&&t[t.length-1]===_&&(t=t.substring(0,t.length-1)),t}const I=/[\\/]/g;function L(e,t){return e.replace(I,t)}const R=/^[a-z]:[\\/]$/i;function z(e){return e===`/`||R.test(e)}function B(e,t){let{resolvePaths:n,normalizePath:r,pathSeparator:i}=t,a=process.platform===`win32`&&e.includes(`/`)||e.startsWith(`.`);return n&&(e=ee(e)),(r||a)&&(e=F(e)),e===`.`?``:L(e[e.length-1]===i?e:e+i,i)}function V(e,t){return t+e}function H(e,t){return function(n,r){return r.startsWith(e)?r.slice(e.length)+n:L(g(e,r),t.pathSeparator)+t.pathSeparator+n}}function U(e){return e}function W(e,t,n){return t+e+n}function G(e,t){let{relativePaths:n,includeBasePath:r}=t;return n&&e?H(e,t):r?V:U}function K(e){return function(t,n){n.push(t.substring(e.length)||`.`)}}function te(e){return function(t,n,r){let i=t.substring(e.length)||`.`;r.every(e=>e(i,!0))&&n.push(i)}}const q=(e,t)=>{t.push(e||`.`)},J=(e,t,n)=>{let r=e||`.`;n.every(e=>e(r,!0))&&t.push(r)},Y=()=>{};function ne(e,t){let{includeDirs:n,filters:r,relativePaths:i}=t;return n?i?r&&r.length?te(e):K(e):r&&r.length?J:q:Y}const re=(e,t,n,r)=>{r.every(t=>t(e,!1))&&n.files++},ie=(e,t,n,r)=>{r.every(t=>t(e,!1))&&t.push(e)},ae=(e,t,n,r)=>{n.files++},oe=(e,t)=>{t.push(e)},se=()=>{};function ce(e){let{excludeFiles:t,filters:n,onlyCounts:r}=e;return t?se:n&&n.length?r?re:ie:r?ae:oe}const le=e=>e,ue=()=>[``].slice(0,0);function de(e){return e.group?ue:le}const fe=(e,t,n)=>{e.push({directory:t,files:n,dir:t})},pe=()=>{};function me(e){return e.group?fe:pe}const he=function(e,t,n){let{queue:r,fs:i,options:{suppressErrors:a}}=t;r.enqueue(),i.realpath(e,(o,s)=>{if(o)return r.dequeue(a?null:o,t);i.stat(s,(i,o)=>{if(i)return r.dequeue(a?null:i,t);if(o.isDirectory()&&ve(e,s,t))return r.dequeue(null,t);n(o,s),r.dequeue(null,t)})})},ge=function(e,t,n){let{queue:r,fs:i,options:{suppressErrors:a}}=t;r.enqueue();try{let r=i.realpathSync(e),a=i.statSync(r);if(a.isDirectory()&&ve(e,r,t))return;n(a,r)}catch(e){if(!a)throw e}};function _e(e,t){return!e.resolveSymlinks||e.excludeSymlinks?null:t?ge:he}function ve(e,t,n){if(n.options.useRealPaths)return ye(t,n);let r=p(e),i=1;for(;r!==n.root&&i<2;){let e=n.symlinks.get(r);e&&(e===t||e.startsWith(t)||t.startsWith(e))?i++:r=p(r)}return n.symlinks.set(e,t),i>1}function ye(e,t){return t.visited.includes(e+t.options.pathSeparator)}const be=e=>e.counts,xe=e=>e.groups,Se=e=>e.paths,Ce=e=>e.paths.slice(0,e.options.maxFiles),we=(e,t,n)=>(Oe(t,n,e.counts,e.options.suppressErrors),null),Te=(e,t,n)=>(Oe(t,n,e.paths,e.options.suppressErrors),null),Ee=(e,t,n)=>(Oe(t,n,e.paths.slice(0,e.options.maxFiles),e.options.suppressErrors),null),De=(e,t,n)=>(Oe(t,n,e.groups,e.options.suppressErrors),null);function Oe(e,t,n,r){t(e&&!r?e:null,n)}function ke(e,t){let{onlyCounts:n,group:r,maxFiles:i}=e;return n?t?be:we:r?t?xe:De:i?t?Ce:Ee:t?Se:Te}const Ae={withFileTypes:!0},je=(e,t,n,r,i)=>{if(e.queue.enqueue(),r<0)return e.queue.dequeue(null,e);let{fs:a}=e;e.visited.push(t),e.counts.directories++,a.readdir(t||`.`,Ae,(t,a=[])=>{i(a,n,r),e.queue.dequeue(e.options.suppressErrors?null:t,e)})},Me=(e,t,n,r,i)=>{let{fs:a}=e;if(r<0)return;e.visited.push(t),e.counts.directories++;let o=[];try{o=a.readdirSync(t||`.`,Ae)}catch(t){if(!e.options.suppressErrors)throw t}i(o,n,r)};function Ne(e){return e?Me:je}var Pe=class{constructor(e){N(this,`count`,0),this.onQueueEmpty=e}enqueue(){return this.count++,this.count}dequeue(e,t){this.onQueueEmpty&&(--this.count<=0||e)&&(this.onQueueEmpty(e,t),e&&(t.controller.abort(),this.onQueueEmpty=void 0))}},Fe=class{constructor(){N(this,`_files`,0),N(this,`_directories`,0)}set files(e){this._files=e}get files(){return this._files}set directories(e){this._directories=e}get directories(){return this._directories}get dirs(){return this._directories}},Ie=class{constructor(){N(this,`aborted`,!1)}abort(){this.aborted=!0}},Le=class{constructor(e,t,n){N(this,`root`,void 0),N(this,`isSynchronous`,void 0),N(this,`state`,void 0),N(this,`joinPath`,void 0),N(this,`pushDirectory`,void 0),N(this,`pushFile`,void 0),N(this,`getArray`,void 0),N(this,`groupFiles`,void 0),N(this,`resolveSymlink`,void 0),N(this,`walkDirectory`,void 0),N(this,`callbackInvoker`,void 0),N(this,`walk`,(e,t,n)=>{let{paths:r,options:{filters:i,resolveSymlinks:a,excludeSymlinks:o,exclude:s,maxFiles:c,signal:l,useRealPaths:u,pathSeparator:d},controller:m}=this.state;if(m.aborted||l&&l.aborted||c&&r.length>c)return;let h=this.getArray(this.state.paths);for(let c=0;c<e.length;++c){let l=e[c];if(l.isFile()||l.isSymbolicLink()&&!a&&!o){let e=this.joinPath(l.name,t);this.pushFile(e,h,this.state.counts,i)}else if(l.isDirectory()){let e=W(l.name,t,this.state.options.pathSeparator);if(s&&s(l.name,e))continue;this.pushDirectory(e,r,i),this.walkDirectory(this.state,e,e,n-1,this.walk)}else if(this.resolveSymlink&&l.isSymbolicLink()){let e=V(l.name,t);this.resolveSymlink(e,this.state,(t,r)=>{if(t.isDirectory()){if(r=B(r,this.state.options),s&&s(l.name,u?r:e+d))return;this.walkDirectory(this.state,r,u?r:e+d,n-1,this.walk)}else{r=u?r:e;let t=f(r),n=B(p(r),this.state.options);r=this.joinPath(t,n),this.pushFile(r,h,this.state.counts,i)}})}}this.groupFiles(this.state.groups,t,h)}),this.isSynchronous=!n,this.callbackInvoker=ke(t,this.isSynchronous),this.root=B(e,t),this.state={root:z(this.root)?this.root:this.root.slice(0,-1),paths:[``].slice(0,0),groups:[],counts:new Fe,options:t,queue:new Pe((e,t)=>this.callbackInvoker(t,e,n)),symlinks:new Map,visited:[``].slice(0,0),controller:new Ie,fs:t.fs||l},this.joinPath=G(this.root,t),this.pushDirectory=ne(this.root,t),this.pushFile=ce(t),this.getArray=de(t),this.groupFiles=me(t),this.resolveSymlink=_e(t,this.isSynchronous),this.walkDirectory=Ne(this.isSynchronous)}start(){return this.pushDirectory(this.root,this.state.paths,this.state.options.filters),this.walkDirectory(this.state,this.root,this.root,this.state.options.maxDepth,this.walk),this.isSynchronous?this.callbackInvoker(this.state,null):null}};function Re(e,t){return new Promise((n,r)=>{ze(e,t,(e,t)=>{if(e)return r(e);n(t)})})}function ze(e,t,n){new Le(e,t,n).start()}function Be(e,t){return new Le(e,t).start()}var Ve=class{constructor(e,t){this.root=e,this.options=t}withPromise(){return Re(this.root,this.options)}withCallback(e){ze(this.root,this.options,e)}sync(){return Be(this.root,this.options)}};let He=null;try{P.resolve(`picomatch`),He=P(`picomatch`)}catch{}var Ue=class{constructor(e){N(this,`globCache`,{}),N(this,`options`,{maxDepth:1/0,suppressErrors:!0,pathSeparator:_,filters:[]}),N(this,`globFunction`,void 0),this.options={...this.options,...e},this.globFunction=this.options.globFunction}group(){return this.options.group=!0,this}withPathSeparator(e){return this.options.pathSeparator=e,this}withBasePath(){return this.options.includeBasePath=!0,this}withRelativePaths(){return this.options.relativePaths=!0,this}withDirs(){return this.options.includeDirs=!0,this}withMaxDepth(e){return this.options.maxDepth=e,this}withMaxFiles(e){return this.options.maxFiles=e,this}withFullPaths(){return this.options.resolvePaths=!0,this.options.includeBasePath=!0,this}withErrors(){return this.options.suppressErrors=!1,this}withSymlinks({resolvePaths:e=!0}={}){return this.options.resolveSymlinks=!0,this.options.useRealPaths=e,this.withFullPaths()}withAbortSignal(e){return this.options.signal=e,this}normalize(){return this.options.normalizePath=!0,this}filter(e){return this.options.filters.push(e),this}onlyDirs(){return this.options.excludeFiles=!0,this.options.includeDirs=!0,this}exclude(e){return this.options.exclude=e,this}onlyCounts(){return this.options.onlyCounts=!0,this}crawl(e){return new Ve(e||`.`,this.options)}withGlobFunction(e){return this.globFunction=e,this}crawlWithOptions(e,t){return this.options={...this.options,...t},new Ve(e||`.`,this.options)}glob(...e){return this.globFunction?this.globWithOptions(e):this.globWithOptions(e,{dot:!0})}globWithOptions(e,...t){let n=this.globFunction||He;if(!n)throw Error(`Please specify a glob function to use glob matching.`);var r=this.globCache[e.join(`\0`)];return r||(r=n(e,...t),this.globCache[e.join(`\0`)]=r),this.options.filters.push(e=>r(e)),this}},We=E(((e,t)=>{let n=`[^\\\\/]`,r=`[^/]`,i=`(?:\\/|$)`,a=`(?:^|\\/)`,o=`\\.{1,2}${i}`,s={DOT_LITERAL:`\\.`,PLUS_LITERAL:`\\+`,QMARK_LITERAL:`\\?`,SLASH_LITERAL:`\\/`,ONE_CHAR:`(?=.)`,QMARK:r,END_ANCHOR:i,DOTS_SLASH:o,NO_DOT:`(?!\\.)`,NO_DOTS:`(?!${a}${o})`,NO_DOT_SLASH:`(?!\\.{0,1}${i})`,NO_DOTS_SLASH:`(?!${o})`,QMARK_NO_DOT:`[^.\\/]`,STAR:`${r}*?`,START_ANCHOR:a,SEP:`/`},c={...s,SLASH_LITERAL:`[\\\\/]`,QMARK:n,STAR:`${n}*?`,DOTS_SLASH:`\\.{1,2}(?:[\\\\/]|$)`,NO_DOT:`(?!\\.)`,NO_DOTS:`(?!(?:^|[\\\\/])\\.{1,2}(?:[\\\\/]|$))`,NO_DOT_SLASH:`(?!\\.{0,1}(?:[\\\\/]|$))`,NO_DOTS_SLASH:`(?!\\.{1,2}(?:[\\\\/]|$))`,QMARK_NO_DOT:`[^.\\\\/]`,START_ANCHOR:`(?:^|[\\\\/])`,END_ANCHOR:`(?:[\\\\/]|$)`,SEP:`\\`};t.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE:{alnum:`a-zA-Z0-9`,alpha:`a-zA-Z`,ascii:`\\x00-\\x7F`,blank:` \\t`,cntrl:`\\x00-\\x1F\\x7F`,digit:`0-9`,graph:`\\x21-\\x7E`,lower:`a-z`,print:`\\x20-\\x7E `,punct:`\\-!"#$%&'()\\*+,./:;<=>?@[\\]^_\`{|}~`,space:` \\t\\r\\n\\v\\f`,upper:`A-Z`,word:`A-Za-z0-9_`,xdigit:`A-Fa-f0-9`},REGEX_BACKSLASH:/\\(?![*+?^${}(|)[\]])/g,REGEX_NON_SPECIAL_CHARS:/^[^@![\].,$*+?^{}()|\\/]+/,REGEX_SPECIAL_CHARS:/[-*+?.^${}(|)[\]]/,REGEX_SPECIAL_CHARS_BACKREF:/(\\?)((\W)(\3*))/g,REGEX_SPECIAL_CHARS_GLOBAL:/([-*+?.^${}(|)[\]])/g,REGEX_REMOVE_BACKSLASH:/(?:\[.*?[^\\]\]|\\(?=.))/g,REPLACEMENTS:{__proto__:null,"***":`*`,"**/**":`**`,"**/**/**":`**`},CHAR_0:48,CHAR_9:57,CHAR_UPPERCASE_A:65,CHAR_LOWERCASE_A:97,CHAR_UPPERCASE_Z:90,CHAR_LOWERCASE_Z:122,CHAR_LEFT_PARENTHESES:40,CHAR_RIGHT_PARENTHESES:41,CHAR_ASTERISK:42,CHAR_AMPERSAND:38,CHAR_AT:64,CHAR_BACKWARD_SLASH:92,CHAR_CARRIAGE_RETURN:13,CHAR_CIRCUMFLEX_ACCENT:94,CHAR_COLON:58,CHAR_COMMA:44,CHAR_DOT:46,CHAR_DOUBLE_QUOTE:34,CHAR_EQUAL:61,CHAR_EXCLAMATION_MARK:33,CHAR_FORM_FEED:12,CHAR_FORWARD_SLASH:47,CHAR_GRAVE_ACCENT:96,CHAR_HASH:35,CHAR_HYPHEN_MINUS:45,CHAR_LEFT_ANGLE_BRACKET:60,CHAR_LEFT_CURLY_BRACE:123,CHAR_LEFT_SQUARE_BRACKET:91,CHAR_LINE_FEED:10,CHAR_NO_BREAK_SPACE:160,CHAR_PERCENT:37,CHAR_PLUS:43,CHAR_QUESTION_MARK:63,CHAR_RIGHT_ANGLE_BRACKET:62,CHAR_RIGHT_CURLY_BRACE:125,CHAR_RIGHT_SQUARE_BRACKET:93,CHAR_SEMICOLON:59,CHAR_SINGLE_QUOTE:39,CHAR_SPACE:32,CHAR_TAB:9,CHAR_UNDERSCORE:95,CHAR_VERTICAL_LINE:124,CHAR_ZERO_WIDTH_NOBREAK_SPACE:65279,extglobChars(e){return{"!":{type:`negate`,open:`(?:(?!(?:`,close:`))${e.STAR})`},"?":{type:`qmark`,open:`(?:`,close:`)?`},"+":{type:`plus`,open:`(?:`,close:`)+`},"*":{type:`star`,open:`(?:`,close:`)*`},"@":{type:`at`,open:`(?:`,close:`)`}}},globChars(e){return e===!0?c:s}}})),Ge=E((e=>{let{REGEX_BACKSLASH:t,REGEX_REMOVE_BACKSLASH:n,REGEX_SPECIAL_CHARS:r,REGEX_SPECIAL_CHARS_GLOBAL:i}=We();e.isObject=e=>typeof e==`object`&&!!e&&!Array.isArray(e),e.hasRegexChars=e=>r.test(e),e.isRegexChar=t=>t.length===1&&e.hasRegexChars(t),e.escapeRegex=e=>e.replace(i,`\\$1`),e.toPosixSlashes=e=>e.replace(t,`/`),e.isWindows=()=>{if(typeof navigator<`u`&&navigator.platform){let e=navigator.platform.toLowerCase();return e===`win32`||e===`windows`}return typeof process<`u`&&process.platform?process.platform===`win32`:!1},e.removeBackslashes=e=>e.replace(n,e=>e===`\\`?``:e),e.escapeLast=(t,n,r)=>{let i=t.lastIndexOf(n,r);return i===-1?t:t[i-1]===`\\`?e.escapeLast(t,n,i-1):`${t.slice(0,i)}\\${t.slice(i)}`},e.removePrefix=(e,t={})=>{let n=e;return n.startsWith(`./`)&&(n=n.slice(2),t.prefix=`./`),n},e.wrapOutput=(e,t={},n={})=>{let r=`${n.contains?``:`^`}(?:${e})${n.contains?``:`$`}`;return t.negated===!0&&(r=`(?:^(?!${r}).*$)`),r},e.basename=(e,{windows:t}={})=>{let n=e.split(t?/[\\/]/:`/`),r=n[n.length-1];return r===``?n[n.length-2]:r}})),Ke=E(((e,t)=>{let n=Ge(),{CHAR_ASTERISK:r,CHAR_AT:i,CHAR_BACKWARD_SLASH:a,CHAR_COMMA:o,CHAR_DOT:s,CHAR_EXCLAMATION_MARK:c,CHAR_FORWARD_SLASH:l,CHAR_LEFT_CURLY_BRACE:u,CHAR_LEFT_PARENTHESES:d,CHAR_LEFT_SQUARE_BRACKET:f,CHAR_PLUS:p,CHAR_QUESTION_MARK:m,CHAR_RIGHT_CURLY_BRACE:h,CHAR_RIGHT_PARENTHESES:g,CHAR_RIGHT_SQUARE_BRACKET:ee}=We(),_=e=>e===l||e===a,v=e=>{e.isPrefix!==!0&&(e.depth=e.isGlobstar?1/0:1)};t.exports=(e,t)=>{let y=t||{},b=e.length-1,x=y.parts===!0||y.scanToEnd===!0,S=[],C=[],w=[],T=e,E=-1,D=0,O=0,k=!1,A=!1,j=!1,M=!1,N=!1,P=!1,F=!1,I=!1,L=!1,R=!1,z=0,B,V,H={value:``,depth:0,isGlob:!1},U=()=>E>=b,W=()=>T.charCodeAt(E+1),G=()=>(B=V,T.charCodeAt(++E));for(;E<b;){V=G();let e;if(V===a){F=H.backslashes=!0,V=G(),V===u&&(P=!0);continue}if(P===!0||V===u){for(z++;U()!==!0&&(V=G());){if(V===a){F=H.backslashes=!0,G();continue}if(V===u){z++;continue}if(P!==!0&&V===s&&(V=G())===s){if(k=H.isBrace=!0,j=H.isGlob=!0,R=!0,x===!0)continue;break}if(P!==!0&&V===o){if(k=H.isBrace=!0,j=H.isGlob=!0,R=!0,x===!0)continue;break}if(V===h&&(z--,z===0)){P=!1,k=H.isBrace=!0,R=!0;break}}if(x===!0)continue;break}if(V===l){if(S.push(E),C.push(H),H={value:``,depth:0,isGlob:!1},R===!0)continue;if(B===s&&E===D+1){D+=2;continue}O=E+1;continue}if(y.noext!==!0&&(V===p||V===i||V===r||V===m||V===c)&&W()===d){if(j=H.isGlob=!0,M=H.isExtglob=!0,R=!0,V===c&&E===D&&(L=!0),x===!0){for(;U()!==!0&&(V=G());){if(V===a){F=H.backslashes=!0,V=G();continue}if(V===g){j=H.isGlob=!0,R=!0;break}}continue}break}if(V===r){if(B===r&&(N=H.isGlobstar=!0),j=H.isGlob=!0,R=!0,x===!0)continue;break}if(V===m){if(j=H.isGlob=!0,R=!0,x===!0)continue;break}if(V===f){for(;U()!==!0&&(e=G());){if(e===a){F=H.backslashes=!0,G();continue}if(e===ee){A=H.isBracket=!0,j=H.isGlob=!0,R=!0;break}}if(x===!0)continue;break}if(y.nonegate!==!0&&V===c&&E===D){I=H.negated=!0,D++;continue}if(y.noparen!==!0&&V===d){if(j=H.isGlob=!0,x===!0){for(;U()!==!0&&(V=G());){if(V===d){F=H.backslashes=!0,V=G();continue}if(V===g){R=!0;break}}continue}break}if(j===!0){if(R=!0,x===!0)continue;break}}y.noext===!0&&(M=!1,j=!1);let K=T,te=``,q=``;D>0&&(te=T.slice(0,D),T=T.slice(D),O-=D),K&&j===!0&&O>0?(K=T.slice(0,O),q=T.slice(O)):j===!0?(K=``,q=T):K=T,K&&K!==``&&K!==`/`&&K!==T&&_(K.charCodeAt(K.length-1))&&(K=K.slice(0,-1)),y.unescape===!0&&(q&&(q=n.removeBackslashes(q)),K&&F===!0&&(K=n.removeBackslashes(K)));let J={prefix:te,input:e,start:D,base:K,glob:q,isBrace:k,isBracket:A,isGlob:j,isExtglob:M,isGlobstar:N,negated:I,negatedExtglob:L};if(y.tokens===!0&&(J.maxDepth=0,_(V)||C.push(H),J.tokens=C),y.parts===!0||y.tokens===!0){let t;for(let n=0;n<S.length;n++){let r=t?t+1:D,i=S[n],a=e.slice(r,i);y.tokens&&(n===0&&D!==0?(C[n].isPrefix=!0,C[n].value=te):C[n].value=a,v(C[n]),J.maxDepth+=C[n].depth),(n!==0||a!==``)&&w.push(a),t=i}if(t&&t+1<e.length){let n=e.slice(t+1);w.push(n),y.tokens&&(C[C.length-1].value=n,v(C[C.length-1]),J.maxDepth+=C[C.length-1].depth)}J.slashes=S,J.parts=w}return J}})),qe=E(((e,t)=>{let n=We(),r=Ge(),{MAX_LENGTH:i,POSIX_REGEX_SOURCE:a,REGEX_NON_SPECIAL_CHARS:o,REGEX_SPECIAL_CHARS_BACKREF:s,REPLACEMENTS:c}=n,l=(e,t)=>{if(typeof t.expandRange==`function`)return t.expandRange(...e,t);e.sort();let n=`[${e.join(`-`)}]`;try{new RegExp(n)}catch{return e.map(e=>r.escapeRegex(e)).join(`..`)}return n},u=(e,t)=>`Missing ${e}: "${t}" - use "\\\\${t}" to match literal characters`,d=(e,t)=>{if(typeof e!=`string`)throw TypeError(`Expected a string`);e=c[e]||e;let f={...t},p=typeof f.maxLength==`number`?Math.min(i,f.maxLength):i,m=e.length;if(m>p)throw SyntaxError(`Input length: ${m}, exceeds maximum allowed length: ${p}`);let h={type:`bos`,value:``,output:f.prepend||``},g=[h],ee=f.capture?``:`?:`,_=n.globChars(f.windows),v=n.extglobChars(_),{DOT_LITERAL:y,PLUS_LITERAL:b,SLASH_LITERAL:x,ONE_CHAR:S,DOTS_SLASH:C,NO_DOT:w,NO_DOT_SLASH:T,NO_DOTS_SLASH:E,QMARK:D,QMARK_NO_DOT:O,STAR:k,START_ANCHOR:A}=_,j=e=>`(${ee}(?:(?!${A}${e.dot?C:y}).)*?)`,M=f.dot?``:w,N=f.dot?D:O,P=f.bash===!0?j(f):k;f.capture&&(P=`(${P})`),typeof f.noext==`boolean`&&(f.noextglob=f.noext);let F={input:e,index:-1,start:0,dot:f.dot===!0,consumed:``,output:``,prefix:``,backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens:g};e=r.removePrefix(e,F),m=e.length;let I=[],L=[],R=[],z=h,B,V=()=>F.index===m-1,H=F.peek=(t=1)=>e[F.index+t],U=F.advance=()=>e[++F.index]||``,W=()=>e.slice(F.index+1),G=(e=``,t=0)=>{F.consumed+=e,F.index+=t},K=e=>{F.output+=e.output==null?e.value:e.output,G(e.value)},te=()=>{let e=1;for(;H()===`!`&&(H(2)!==`(`||H(3)===`?`);)U(),F.start++,e++;return e%2==0?!1:(F.negated=!0,F.start++,!0)},q=e=>{F[e]++,R.push(e)},J=e=>{F[e]--,R.pop()},Y=e=>{if(z.type===`globstar`){let t=F.braces>0&&(e.type===`comma`||e.type===`brace`),n=e.extglob===!0||I.length&&(e.type===`pipe`||e.type===`paren`);e.type!==`slash`&&e.type!==`paren`&&!t&&!n&&(F.output=F.output.slice(0,-z.output.length),z.type=`star`,z.value=`*`,z.output=P,F.output+=z.output)}if(I.length&&e.type!==`paren`&&(I[I.length-1].inner+=e.value),(e.value||e.output)&&K(e),z&&z.type===`text`&&e.type===`text`){z.output=(z.output||z.value)+e.value,z.value+=e.value;return}e.prev=z,g.push(e),z=e},ne=(e,t)=>{let n={...v[t],conditions:1,inner:``};n.prev=z,n.parens=F.parens,n.output=F.output;let r=(f.capture?`(`:``)+n.open;q(`parens`),Y({type:e,value:t,output:F.output?``:S}),Y({type:`paren`,extglob:!0,value:U(),output:r}),I.push(n)},re=e=>{let n=e.close+(f.capture?`)`:``),r;if(e.type===`negate`){let i=P;e.inner&&e.inner.length>1&&e.inner.includes(`/`)&&(i=j(f)),(i!==P||V()||/^\)+$/.test(W()))&&(n=e.close=`)$))${i}`),e.inner.includes(`*`)&&(r=W())&&/^\.[^\\/.]+$/.test(r)&&(n=e.close=`)${d(r,{...t,fastpaths:!1}).output})${i})`),e.prev.type===`bos`&&(F.negatedExtglob=!0)}Y({type:`paren`,extglob:!0,value:B,output:n}),J(`parens`)};if(f.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(e)){let n=!1,i=e.replace(s,(e,t,r,i,a,o)=>i===`\\`?(n=!0,e):i===`?`?t?t+i+(a?D.repeat(a.length):``):o===0?N+(a?D.repeat(a.length):``):D.repeat(r.length):i===`.`?y.repeat(r.length):i===`*`?t?t+i+(a?P:``):P:t?e:`\\${e}`);return n===!0&&(i=f.unescape===!0?i.replace(/\\/g,``):i.replace(/\\+/g,e=>e.length%2==0?`\\\\`:e?`\\`:``)),i===e&&f.contains===!0?(F.output=e,F):(F.output=r.wrapOutput(i,F,t),F)}for(;!V();){if(B=U(),B===`\0`)continue;if(B===`\\`){let e=H();if(e===`/`&&f.bash!==!0||e===`.`||e===`;`)continue;if(!e){B+=`\\`,Y({type:`text`,value:B});continue}let t=/^\\+/.exec(W()),n=0;if(t&&t[0].length>2&&(n=t[0].length,F.index+=n,n%2!=0&&(B+=`\\`)),f.unescape===!0?B=U():B+=U(),F.brackets===0){Y({type:`text`,value:B});continue}}if(F.brackets>0&&(B!==`]`||z.value===`[`||z.value===`[^`)){if(f.posix!==!1&&B===`:`){let e=z.value.slice(1);if(e.includes(`[`)&&(z.posix=!0,e.includes(`:`))){let e=z.value.lastIndexOf(`[`),t=z.value.slice(0,e),n=a[z.value.slice(e+2)];if(n){z.value=t+n,F.backtrack=!0,U(),!h.output&&g.indexOf(z)===1&&(h.output=S);continue}}}(B===`[`&&H()!==`:`||B===`-`&&H()===`]`)&&(B=`\\${B}`),B===`]`&&(z.value===`[`||z.value===`[^`)&&(B=`\\${B}`),f.posix===!0&&B===`!`&&z.value===`[`&&(B=`^`),z.value+=B,K({value:B});continue}if(F.quotes===1&&B!==`"`){B=r.escapeRegex(B),z.value+=B,K({value:B});continue}if(B===`"`){F.quotes=F.quotes===1?0:1,f.keepQuotes===!0&&Y({type:`text`,value:B});continue}if(B===`(`){q(`parens`),Y({type:`paren`,value:B});continue}if(B===`)`){if(F.parens===0&&f.strictBrackets===!0)throw SyntaxError(u(`opening`,`(`));let e=I[I.length-1];if(e&&F.parens===e.parens+1){re(I.pop());continue}Y({type:`paren`,value:B,output:F.parens?`)`:`\\)`}),J(`parens`);continue}if(B===`[`){if(f.nobracket===!0||!W().includes(`]`)){if(f.nobracket!==!0&&f.strictBrackets===!0)throw SyntaxError(u(`closing`,`]`));B=`\\${B}`}else q(`brackets`);Y({type:`bracket`,value:B});continue}if(B===`]`){if(f.nobracket===!0||z&&z.type===`bracket`&&z.value.length===1){Y({type:`text`,value:B,output:`\\${B}`});continue}if(F.brackets===0){if(f.strictBrackets===!0)throw SyntaxError(u(`opening`,`[`));Y({type:`text`,value:B,output:`\\${B}`});continue}J(`brackets`);let e=z.value.slice(1);if(z.posix!==!0&&e[0]===`^`&&!e.includes(`/`)&&(B=`/${B}`),z.value+=B,K({value:B}),f.literalBrackets===!1||r.hasRegexChars(e))continue;let t=r.escapeRegex(z.value);if(F.output=F.output.slice(0,-z.value.length),f.literalBrackets===!0){F.output+=t,z.value=t;continue}z.value=`(${ee}${t}|${z.value})`,F.output+=z.value;continue}if(B===`{`&&f.nobrace!==!0){q(`braces`);let e={type:`brace`,value:B,output:`(`,outputIndex:F.output.length,tokensIndex:F.tokens.length};L.push(e),Y(e);continue}if(B===`}`){let e=L[L.length-1];if(f.nobrace===!0||!e){Y({type:`text`,value:B,output:B});continue}let t=`)`;if(e.dots===!0){let e=g.slice(),n=[];for(let t=e.length-1;t>=0&&(g.pop(),e[t].type!==`brace`);t--)e[t].type!==`dots`&&n.unshift(e[t].value);t=l(n,f),F.backtrack=!0}if(e.comma!==!0&&e.dots!==!0){let n=F.output.slice(0,e.outputIndex),r=F.tokens.slice(e.tokensIndex);e.value=e.output=`\\{`,B=t=`\\}`,F.output=n;for(let e of r)F.output+=e.output||e.value}Y({type:`brace`,value:B,output:t}),J(`braces`),L.pop();continue}if(B===`|`){I.length>0&&I[I.length-1].conditions++,Y({type:`text`,value:B});continue}if(B===`,`){let e=B,t=L[L.length-1];t&&R[R.length-1]===`braces`&&(t.comma=!0,e=`|`),Y({type:`comma`,value:B,output:e});continue}if(B===`/`){if(z.type===`dot`&&F.index===F.start+1){F.start=F.index+1,F.consumed=``,F.output=``,g.pop(),z=h;continue}Y({type:`slash`,value:B,output:x});continue}if(B===`.`){if(F.braces>0&&z.type===`dot`){z.value===`.`&&(z.output=y);let e=L[L.length-1];z.type=`dots`,z.output+=B,z.value+=B,e.dots=!0;continue}if(F.braces+F.parens===0&&z.type!==`bos`&&z.type!==`slash`){Y({type:`text`,value:B,output:y});continue}Y({type:`dot`,value:B,output:y});continue}if(B===`?`){if(!(z&&z.value===`(`)&&f.noextglob!==!0&&H()===`(`&&H(2)!==`?`){ne(`qmark`,B);continue}if(z&&z.type===`paren`){let e=H(),t=B;(z.value===`(`&&!/[!=<:]/.test(e)||e===`<`&&!/<([!=]|\w+>)/.test(W()))&&(t=`\\${B}`),Y({type:`text`,value:B,output:t});continue}if(f.dot!==!0&&(z.type===`slash`||z.type===`bos`)){Y({type:`qmark`,value:B,output:O});continue}Y({type:`qmark`,value:B,output:D});continue}if(B===`!`){if(f.noextglob!==!0&&H()===`(`&&(H(2)!==`?`||!/[!=<:]/.test(H(3)))){ne(`negate`,B);continue}if(f.nonegate!==!0&&F.index===0){te();continue}}if(B===`+`){if(f.noextglob!==!0&&H()===`(`&&H(2)!==`?`){ne(`plus`,B);continue}if(z&&z.value===`(`||f.regex===!1){Y({type:`plus`,value:B,output:b});continue}if(z&&(z.type===`bracket`||z.type===`paren`||z.type===`brace`)||F.parens>0){Y({type:`plus`,value:B});continue}Y({type:`plus`,value:b});continue}if(B===`@`){if(f.noextglob!==!0&&H()===`(`&&H(2)!==`?`){Y({type:`at`,extglob:!0,value:B,output:``});continue}Y({type:`text`,value:B});continue}if(B!==`*`){(B===`$`||B===`^`)&&(B=`\\${B}`);let e=o.exec(W());e&&(B+=e[0],F.index+=e[0].length),Y({type:`text`,value:B});continue}if(z&&(z.type===`globstar`||z.star===!0)){z.type=`star`,z.star=!0,z.value+=B,z.output=P,F.backtrack=!0,F.globstar=!0,G(B);continue}let t=W();if(f.noextglob!==!0&&/^\([^?]/.test(t)){ne(`star`,B);continue}if(z.type===`star`){if(f.noglobstar===!0){G(B);continue}let n=z.prev,r=n.prev,i=n.type===`slash`||n.type===`bos`,a=r&&(r.type===`star`||r.type===`globstar`);if(f.bash===!0&&(!i||t[0]&&t[0]!==`/`)){Y({type:`star`,value:B,output:``});continue}let o=F.braces>0&&(n.type===`comma`||n.type===`brace`),s=I.length&&(n.type===`pipe`||n.type===`paren`);if(!i&&n.type!==`paren`&&!o&&!s){Y({type:`star`,value:B,output:``});continue}for(;t.slice(0,3)===`/**`;){let n=e[F.index+4];if(n&&n!==`/`)break;t=t.slice(3),G(`/**`,3)}if(n.type===`bos`&&V()){z.type=`globstar`,z.value+=B,z.output=j(f),F.output=z.output,F.globstar=!0,G(B);continue}if(n.type===`slash`&&n.prev.type!==`bos`&&!a&&V()){F.output=F.output.slice(0,-(n.output+z.output).length),n.output=`(?:${n.output}`,z.type=`globstar`,z.output=j(f)+(f.strictSlashes?`)`:`|$)`),z.value+=B,F.globstar=!0,F.output+=n.output+z.output,G(B);continue}if(n.type===`slash`&&n.prev.type!==`bos`&&t[0]===`/`){let e=t[1]===void 0?``:`|$`;F.output=F.output.slice(0,-(n.output+z.output).length),n.output=`(?:${n.output}`,z.type=`globstar`,z.output=`${j(f)}${x}|${x}${e})`,z.value+=B,F.output+=n.output+z.output,F.globstar=!0,G(B+U()),Y({type:`slash`,value:`/`,output:``});continue}if(n.type===`bos`&&t[0]===`/`){z.type=`globstar`,z.value+=B,z.output=`(?:^|${x}|${j(f)}${x})`,F.output=z.output,F.globstar=!0,G(B+U()),Y({type:`slash`,value:`/`,output:``});continue}F.output=F.output.slice(0,-z.output.length),z.type=`globstar`,z.output=j(f),z.value+=B,F.output+=z.output,F.globstar=!0,G(B);continue}let n={type:`star`,value:B,output:P};if(f.bash===!0){n.output=`.*?`,(z.type===`bos`||z.type===`slash`)&&(n.output=M+n.output),Y(n);continue}if(z&&(z.type===`bracket`||z.type===`paren`)&&f.regex===!0){n.output=B,Y(n);continue}(F.index===F.start||z.type===`slash`||z.type===`dot`)&&(z.type===`dot`?(F.output+=T,z.output+=T):f.dot===!0?(F.output+=E,z.output+=E):(F.output+=M,z.output+=M),H()!==`*`&&(F.output+=S,z.output+=S)),Y(n)}for(;F.brackets>0;){if(f.strictBrackets===!0)throw SyntaxError(u(`closing`,`]`));F.output=r.escapeLast(F.output,`[`),J(`brackets`)}for(;F.parens>0;){if(f.strictBrackets===!0)throw SyntaxError(u(`closing`,`)`));F.output=r.escapeLast(F.output,`(`),J(`parens`)}for(;F.braces>0;){if(f.strictBrackets===!0)throw SyntaxError(u(`closing`,`}`));F.output=r.escapeLast(F.output,`{`),J(`braces`)}if(f.strictSlashes!==!0&&(z.type===`star`||z.type===`bracket`)&&Y({type:`maybe_slash`,value:``,output:`${x}?`}),F.backtrack===!0){F.output=``;for(let e of F.tokens)F.output+=e.output==null?e.value:e.output,e.suffix&&(F.output+=e.suffix)}return F};d.fastpaths=(e,t)=>{let a={...t},o=typeof a.maxLength==`number`?Math.min(i,a.maxLength):i,s=e.length;if(s>o)throw SyntaxError(`Input length: ${s}, exceeds maximum allowed length: ${o}`);e=c[e]||e;let{DOT_LITERAL:l,SLASH_LITERAL:u,ONE_CHAR:d,DOTS_SLASH:f,NO_DOT:p,NO_DOTS:m,NO_DOTS_SLASH:h,STAR:g,START_ANCHOR:ee}=n.globChars(a.windows),_=a.dot?m:p,v=a.dot?h:p,y=a.capture?``:`?:`,b={negated:!1,prefix:``},x=a.bash===!0?`.*?`:g;a.capture&&(x=`(${x})`);let S=e=>e.noglobstar===!0?x:`(${y}(?:(?!${ee}${e.dot?f:l}).)*?)`,C=e=>{switch(e){case`*`:return`${_}${d}${x}`;case`.*`:return`${l}${d}${x}`;case`*.*`:return`${_}${x}${l}${d}${x}`;case`*/*`:return`${_}${x}${u}${d}${v}${x}`;case`**`:return _+S(a);case`**/*`:return`(?:${_}${S(a)}${u})?${v}${d}${x}`;case`**/*.*`:return`(?:${_}${S(a)}${u})?${v}${x}${l}${d}${x}`;case`**/.*`:return`(?:${_}${S(a)}${u})?${l}${d}${x}`;default:{let t=/^(.*?)\.(\w+)$/.exec(e);if(!t)return;let n=C(t[1]);return n?n+l+t[2]:void 0}}},w=C(r.removePrefix(e,b));return w&&a.strictSlashes!==!0&&(w+=`${u}?`),w},t.exports=d})),Je=E(((e,t)=>{let n=Ke(),r=qe(),i=Ge(),a=We(),o=e=>e&&typeof e==`object`&&!Array.isArray(e),s=(e,t,n=!1)=>{if(Array.isArray(e)){let r=e.map(e=>s(e,t,n));return e=>{for(let t of r){let n=t(e);if(n)return n}return!1}}let r=o(e)&&e.tokens&&e.input;if(e===``||typeof e!=`string`&&!r)throw TypeError(`Expected pattern to be a non-empty string`);let i=t||{},a=i.windows,c=r?s.compileRe(e,t):s.makeRe(e,t,!1,!0),l=c.state;delete c.state;let u=()=>!1;if(i.ignore){let e={...t,ignore:null,onMatch:null,onResult:null};u=s(i.ignore,e,n)}let d=(n,r=!1)=>{let{isMatch:o,match:d,output:f}=s.test(n,c,t,{glob:e,posix:a}),p={glob:e,state:l,regex:c,posix:a,input:n,output:f,match:d,isMatch:o};return typeof i.onResult==`function`&&i.onResult(p),o===!1?(p.isMatch=!1,r?p:!1):u(n)?(typeof i.onIgnore==`function`&&i.onIgnore(p),p.isMatch=!1,r?p:!1):(typeof i.onMatch==`function`&&i.onMatch(p),r?p:!0)};return n&&(d.state=l),d};s.test=(e,t,n,{glob:r,posix:a}={})=>{if(typeof e!=`string`)throw TypeError(`Expected input to be a string`);if(e===``)return{isMatch:!1,output:``};let o=n||{},c=o.format||(a?i.toPosixSlashes:null),l=e===r,u=l&&c?c(e):e;return l===!1&&(u=c?c(e):e,l=u===r),(l===!1||o.capture===!0)&&(l=o.matchBase===!0||o.basename===!0?s.matchBase(e,t,n,a):t.exec(u)),{isMatch:!!l,match:l,output:u}},s.matchBase=(e,t,n)=>(t instanceof RegExp?t:s.makeRe(t,n)).test(i.basename(e)),s.isMatch=(e,t,n)=>s(t,n)(e),s.parse=(e,t)=>Array.isArray(e)?e.map(e=>s.parse(e,t)):r(e,{...t,fastpaths:!1}),s.scan=(e,t)=>n(e,t),s.compileRe=(e,t,n=!1,r=!1)=>{if(n===!0)return e.output;let i=t||{},a=i.contains?``:`^`,o=i.contains?``:`$`,c=`${a}(?:${e.output})${o}`;e&&e.negated===!0&&(c=`^(?!${c}).*$`);let l=s.toRegex(c,t);return r===!0&&(l.state=e),l},s.makeRe=(e,t={},n=!1,i=!1)=>{if(!e||typeof e!=`string`)throw TypeError(`Expected a non-empty string`);let a={negated:!1,fastpaths:!0};return t.fastpaths!==!1&&(e[0]===`.`||e[0]===`*`)&&(a.output=r.fastpaths(e,t)),a.output||(a=r(e,t)),s.compileRe(a,t,n,i)},s.toRegex=(e,t)=>{try{let n=t||{};return new RegExp(e,n.flags||(n.nocase?`i`:``))}catch(e){if(t&&t.debug===!0)throw e;return/$^/}},s.constants=a,t.exports=s})),Ye=O(E(((e,t)=>{let n=Je(),r=Ge();function i(e,t,i=!1){return t&&(t.windows===null||t.windows===void 0)&&(t={...t,windows:r.isWindows()}),n(e,t,i)}Object.assign(i,n),t.exports=i}))(),1);const Xe=Array.isArray,Ze=process.platform===`win32`,Qe=/^(\/?\.\.)+$/;function $e(e,t={}){let n=e.length,r=Array(n),i=Array(n),a=!t.noglobstar;for(let a=0;a<n;a++){let n=at(e[a]);r[a]=n;let o=n.length,s=Array(o);for(let e=0;e<o;e++)s[e]=(0,Ye.default)(n[e],t);i[a]=s}return t=>{let n=t.split(`/`);if(n[0]===`..`&&Qe.test(t))return!0;for(let t=0;t<e.length;t++){let e=r[t],o=i[t],s=n.length,c=Math.min(s,e.length),l=0;for(;l<c;){let t=e[l];if(t.includes(`/`))return!0;if(!o[l](n[l]))break;if(a&&t===`**`)return!0;l++}if(l===s)return!0}return!1}}const et=/^[A-Z]:\/$/i,tt=Ze?e=>et.test(e):e=>e===`/`;function nt(e,t,n){if(e===t||t.startsWith(`${e}/`)){if(n){let t=tt(e)?e.length:e.length+1;return(e,n)=>e.slice(t,n?-1:void 0)||`.`}let r=t.slice(e.length+1);return r?(e,t)=>{if(e===`.`)return r;let n=`${r}/${e}`;return t?n.slice(0,-1):n}:(e,t)=>t&&e!==`.`?e.slice(0,-1):e}return n?t=>h.relative(e,t)||`.`:n=>h.relative(e,`${t}/${n}`)||`.`}function rt(e,t){if(t.startsWith(`${e}/`)){let n=t.slice(e.length+1);return e=>`${n}/${e}`}return n=>{let r=h.relative(e,`${t}/${n}`);return n.endsWith(`/`)&&r!==``?`${r}/`:r||`.`}}const it={parts:!0};function at(e){let t=Ye.default.scan(e,it);return t.parts?.length?t.parts:[e]}const ot=/(?<!\\)([()[\]{}*?|]|^!|[!+@](?=\()|\\(?![()[\]{}!*+?@|]))/g,st=/(?<!\\)([()[\]{}]|^!|[!+@](?=\())/g,ct=Ze?e=>e.replace(st,`\\$&`):e=>e.replace(ot,`\\$&`);function lt(e,t){if(t?.caseSensitiveMatch===!1)return!0;let n=Ye.default.scan(e);return n.isGlob||n.negated}function ut(...e){console.log(`[tinyglobby ${new Date().toLocaleTimeString(`es`)}]`,...e)}const dt=/^(\/?\.\.)+/,ft=/\\(?=[()[\]{}!*+?@|])/g,pt=/\\/g;function mt(e,t,n,r,i){let a=e;e.endsWith(`/`)&&(a=e.slice(0,-1)),!a.endsWith(`*`)&&t&&(a+=`/**`);let o=ct(n);a=d.isAbsolute(a.replace(ft,``))?h.relative(o,a):h.normalize(a);let s=dt.exec(a),c=at(a);if(s?.[0]){let e=(s[0].length+1)/3,t=0,i=o.split(`/`);for(;t<e&&c[t+e]===i[i.length+t-e];)a=a.slice(0,(e-t-1)*3)+a.slice((e-t)*3+c[t+e].length+1)||`.`,t++;let l=h.join(n,s[0].slice(t*3));!l.startsWith(`.`)&&r.root.length>l.length&&(r.root=l,r.depthOffset=-e+t)}if(!i&&r.depthOffset>=0){r.commonPath??(r.commonPath=c);let e=[],t=Math.min(r.commonPath.length,c.length);for(let n=0;n<t;n++){let t=c[n];if(t===`**`&&!c[n+1]){e.pop();break}if(t!==r.commonPath[n]||lt(t)||n===c.length-1)break;e.push(t)}r.depthOffset=e.length,r.commonPath=e,r.root=e.length>0?h.join(n,...e):n}return a}function ht({patterns:e=[`**/*`],ignore:t=[],expandDirectories:n=!0},r,i){typeof e==`string`&&(e=[e]),typeof t==`string`&&(t=[t]);let a=[],o=[];for(let e of t)e&&(e[0]!==`!`||e[1]===`(`)&&o.push(mt(e,n,r,i,!0));for(let t of e)t&&(t[0]!==`!`||t[1]===`(`?a.push(mt(t,n,r,i,!1)):(t[1]!==`!`||t[2]===`(`)&&o.push(mt(t.slice(1),n,r,i,!0)));return{match:a,ignore:o}}function gt(e,t){for(let n=e.length-1;n>=0;n--){let r=e[n];e[n]=t(r)}return e}function _t(e){return e?e instanceof URL?v(e).replace(pt,`/`):d.resolve(e).replace(pt,`/`):process.cwd().replace(pt,`/`)}function vt(e,t={}){let n=process.env.TINYGLOBBY_DEBUG?{...t,debug:!0}:t,r=_t(n.cwd);if(n.debug&&ut(`globbing with:`,{patterns:e,options:n,cwd:r}),Array.isArray(e)&&e.length===0)return[{sync:()=>[],withPromise:async()=>[]},!1];let i={root:r,commonPath:null,depthOffset:0},a=ht({...n,patterns:e},r,i);n.debug&&ut(`internal processing patterns:`,a);let o={dot:n.dot,nobrace:n.braceExpansion===!1,nocase:n.caseSensitiveMatch===!1,noextglob:n.extglob===!1,noglobstar:n.globstar===!1,posix:!0},s=(0,Ye.default)(a.match,{...o,ignore:a.ignore}),c=(0,Ye.default)(a.ignore,o),l=$e(a.match,o),d=nt(r,i.root,n.absolute),f=n.absolute?d:nt(r,i.root,!0),p={filters:[n.debug?(e,t)=>{let n=d(e,t),r=s(n);return r&&ut(`matched ${n}`),r}:(e,t)=>s(d(e,t))],exclude:n.debug?(e,t)=>{let n=f(t,!0),r=n!==`.`&&!l(n)||c(n);return ut(r?`skipped ${t}`:`crawling ${t}`),r}:(e,t)=>{let n=f(t,!0);return n!==`.`&&!l(n)||c(n)},fs:n.fs?{readdir:n.fs.readdir||u.readdir,readdirSync:n.fs.readdirSync||u.readdirSync,realpath:n.fs.realpath||u.realpath,realpathSync:n.fs.realpathSync||u.realpathSync,stat:n.fs.stat||u.stat,statSync:n.fs.statSync||u.statSync}:void 0,pathSeparator:`/`,relativePaths:!0,resolveSymlinks:!0,signal:n.signal};n.deep!==void 0&&(p.maxDepth=Math.round(n.deep-i.depthOffset)),n.absolute&&(p.relativePaths=!1,p.resolvePaths=!0,p.includeBasePath=!0),n.followSymbolicLinks===!1&&(p.resolveSymlinks=!1,p.excludeSymlinks=!0),n.onlyDirectories?(p.excludeFiles=!0,p.includeDirs=!0):n.onlyFiles===!1&&(p.includeDirs=!0),i.root=i.root.replace(pt,``);let m=i.root;n.debug&&ut(`internal properties:`,i);let h=r!==m&&!n.absolute&&rt(r,i.root);return[new Ue(p).crawl(m),h]}async function yt(e,t){if(e&&t?.patterns)throw Error(`Cannot pass patterns as both an argument and an option`);let n=Xe(e)||typeof e==`string`,r=n?t:e,[i,a]=vt(n?e:e.patterns,r);return a?gt(await i.withPromise(),a):i.withPromise()}let bt={};function xt(){return bt}function St(e){bt=e}function Ct(e){let t=JSON.stringify(e);return bt.configHash!==t}async function wt(e){return{css:n(await t(e.source),e),dependencies:e.source}}const X={active:`●`,done:`✓`,error:`✗`,processing:`◉`,waiting:`○`};function Tt(){process.stdout.isTTY&&process.stdout.write(`\x1B[2K\x1B[0G`)}function Z(e,t,n=`stdout`){let r=`${e} ${t}`;n===`stderr`?process.stderr.write(`${r}\n`):process.stdout.write(`${r}\n`)}function Et(e){return Z(X.waiting,e),{succeed:e=>{Tt(),Z(X.done,e)},fail:e=>{Tt(),Z(X.error,e,`stderr`)},stop:()=>{Tt()}}}function Dt(e,t=``){if(e.length===0)return;let n=e.slice(0,10),r=e.length-10;n.forEach((e,i)=>{Z(i===n.length-1&&r<=0?`└`:`├`,t?e.replace(t,``).replace(/^[/\\]/,``):e)}),r>0&&Z(``,`+ ${r} more files`)}const Q={header(e){process.stdout.write(`${X.active} Yumma CSS ${e}\n`)},fail(e){Z(X.error,e,`stderr`)},build:{start(){return Et(`Collecting classes...`)},success(e,t){return`Collected ${t.toLocaleString()} classes in ${e}ms`},fail(e){return`Something went wrong. ${e instanceof Error?e.message:`Check your files & try again.`}`},compiling(e){return Z(X.processing,`Compiling CSS...`),Dt(e),{success:(e,t)=>{Z(X.done,`Generated ${e} (${(t/1024).toFixed(1)}KB)`)},fail:e=>`Compilation failed. ${e instanceof Error?e.message:`Check your files & try again.`}`}},written(e){return`Done in ${e}ms`}},watch:{start(){return Et(`Collecting classes...`)},success(e){return`Watching for changes. (${e.toLocaleString()} classes)`},fail(){return`Something went wrong. Check your files & try again.`},compiling(e){return Z(X.processing,`Compiling CSS...`),Dt(e),{success:(e,t)=>{Z(X.done,`${e} (${(t/1024).toFixed(1)}KB)`)},fail:()=>{Z(X.error,`Failed to compile. Check your files.`)}}}},init:{start(){return Et(`Initializing...`)},success(e){return`Created ${e}`},fail(){return`Something went wrong. Check the docs & try again.`},notFound(){return`No config found. Run 'yummacss init' to create one.`},invalid(){return`Invalid config. Check the syntax & try again.`}}};async function Ot(){try{let{config:e}=await r();return e}catch{return i(e)?(Q.fail(Q.init.invalid()),process.exit(1)):(Q.fail(Q.init.notFound()),process.exit(1))}}async function kt(e,t=!1){let n=Q.build.start(),r=Date.now();try{let i=e||await Ot(),o=xt(),l=Ct(i),u;if(t||l||!o.css){let e=await wt(i);u=e.css,e.dependencies,St({configHash:JSON.stringify(i),css:e.css,dependencies:e.dependencies})}else u=o.css??``,o.dependencies;let d=await yt(i.source??[]),f=Array.from(d).length;if(n.succeed(Q.build.success(Date.now()-r,f)),!i.output)throw Error(`No output path specified in config.`);let p=Q.build.compiling(d),m=Date.now();a(c(i.output),{recursive:!0}),s(i.output,u),p.success(i.output,Buffer.byteLength(u,`utf-8`)),process.stdout.write(`${Q.build.written(Date.now()-m)}\n`)}catch(e){n.fail(Q.build.fail(e)),process.exit(1)}}function At(){return{filename:e,content:`export default {
3
3
  source: [""],
4
4
  output: "",
5
5
  };
6
- `}}function Nt(){let e=Q.init.start();try{let{filename:t,content:n}=Mt();s(t,n),e.succeed(Q.init.success(t))}catch{e.fail(Q.init.fail()),process.exit(1)}}let $,Pt=null;const Ft=new Set;function It(e,t){Ft.add(e),Pt&&clearTimeout(Pt),Pt=setTimeout(async()=>{Ft.size>0&&(await jt($,!0),Ft.clear()),Pt=null},500)}async function Lt(){try{$=await At();let e=Q.watch.start();try{let t=Ct(),n=Tt($),r;if(n||!t.css){let e=await Et($);r=e.css,wt({configHash:JSON.stringify($),css:e.css,dependencies:e.dependencies})}else r=t.css??``;let i=Array.from(await xt($.source??[])).length;if(e.succeed(Q.watch.success(i)),!$.output)throw Error(`No output path specified in config.`);let o=await xt($.source??[]),l=Q.watch.compiling(o);a(c($.output),{recursive:!0}),s($.output,r),l.success($.output,Buffer.byteLength(r,`utf-8`))}catch{e.fail(Q.watch.fail()),process.exit(1)}if(!$.source)throw Error(`No source patterns specified in config.`);let t=await xt($.source);for(let e of t)o(e,t=>{It(e,t)})}catch{Q.fail(Q.watch.fail()),process.exit(1)}}switch(process.argv.slice(2)[0]){case`init`:case`i`:Nt();break;case`build`:case`b`:Q.header(A),jt().catch(()=>process.exit(1));break;case`watch`:case`w`:Q.header(A),Lt().catch(()=>process.exit(1));break;default:Q.header(A),console.log(`Commands:
6
+ `}}function jt(){let e=Q.init.start();try{let{filename:t,content:n}=At();s(t,n),e.succeed(Q.init.success(t))}catch{e.fail(Q.init.fail()),process.exit(1)}}let $,Mt=null;const Nt=new Set;function Pt(e,t){Nt.add(e),Mt&&clearTimeout(Mt),Mt=setTimeout(async()=>{Nt.size>0&&(await kt($,!0),Nt.clear()),Mt=null},500)}async function Ft(){try{$=await Ot();let e=Q.watch.start();try{let t=xt(),n=Ct($),r;if(n||!t.css){let e=await wt($);r=e.css,St({configHash:JSON.stringify($),css:e.css,dependencies:e.dependencies})}else r=t.css??``;let i=Array.from(await yt($.source??[])).length;if(e.succeed(Q.watch.success(i)),!$.output)throw Error(`No output path specified in config.`);let o=await yt($.source??[]),l=Q.watch.compiling(o);a(c($.output),{recursive:!0}),s($.output,r),l.success($.output,Buffer.byteLength(r,`utf-8`))}catch{e.fail(Q.watch.fail()),process.exit(1)}if(!$.source)throw Error(`No source patterns specified in config.`);let t=await yt($.source);for(let e of t)o(e,t=>{Pt(e,t)})}catch{Q.fail(Q.watch.fail()),process.exit(1)}}switch(process.argv.slice(2)[0]){case`init`:case`i`:jt();break;case`build`:case`b`:Q.header(k),kt().catch(()=>process.exit(1));break;case`watch`:case`w`:Q.header(k),Ft().catch(()=>process.exit(1));break;default:Q.header(k),console.log(`Commands:
7
7
  init, i Initialize the configuration.
8
8
  build, b Build the styles once.
9
9
  watch, w Watch for file changes continuously.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "yummacss",
3
- "version": "3.24.17",
4
- "description": "The ergonomic CSS framework",
3
+ "version": "3.26.0",
4
+ "description": "Utility CSS with no new vocabulary. Class names are derived from CSS property names, so if you know CSS, you already know Yumma.",
5
5
  "keywords": [
6
6
  "css-framework",
7
7
  "typescript",
@@ -29,14 +29,14 @@
29
29
  "dist"
30
30
  ],
31
31
  "dependencies": {
32
- "@yummacss/nitro": "3.24.17"
32
+ "@yummacss/nitro": "3.26.0"
33
33
  },
34
34
  "devDependencies": {
35
35
  "tinyglobby": "^0.2.15"
36
36
  },
37
37
  "publishConfig": {
38
38
  "access": "public",
39
- "provenance": false
39
+ "provenance": true
40
40
  },
41
41
  "scripts": {
42
42
  "build": "tsdown",