UNPKG

@storybook/addon-docs

Version:
13 lines (9 loc) • 882 kB
'use strict'; var default2 = require('path'); var default3 = require('process'); var url = require('url'); var nodeLogger = require('storybook/internal/node-logger'); function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; } var default2__default = /*#__PURE__*/_interopDefault(default2); var default3__default = /*#__PURE__*/_interopDefault(default3); var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __require=(x=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(x,{get:(a,b)=>(typeof require<"u"?require:a)[b]}):x)(function(x){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+x+'" is not supported')});var __esm=(fn,res)=>function(){return fn&&(res=(0, fn[__getOwnPropNames(fn)[0]])(fn=0)),res};var __commonJS=(cb,mod)=>function(){return mod||(0, cb[__getOwnPropNames(cb)[0]])((mod={exports:{}}).exports,mod),mod.exports};var __export=(target,all4)=>{for(var name2 in all4)__defProp(target,name2,{get:all4[name2],enumerable:!0});},__copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod)),__toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod);var regex,init_regex=__esm({"../../node_modules/github-slugger/regex.js"(){regex=/[\0-\x1F!-,\.\/:-@\[-\^`\{-\xA9\xAB-\xB4\xB6-\xB9\xBB-\xBF\xD7\xF7\u02C2-\u02C5\u02D2-\u02DF\u02E5-\u02EB\u02ED\u02EF-\u02FF\u0375\u0378\u0379\u037E\u0380-\u0385\u0387\u038B\u038D\u03A2\u03F6\u0482\u0530\u0557\u0558\u055A-\u055F\u0589-\u0590\u05BE\u05C0\u05C3\u05C6\u05C8-\u05CF\u05EB-\u05EE\u05F3-\u060F\u061B-\u061F\u066A-\u066D\u06D4\u06DD\u06DE\u06E9\u06FD\u06FE\u0700-\u070F\u074B\u074C\u07B2-\u07BF\u07F6-\u07F9\u07FB\u07FC\u07FE\u07FF\u082E-\u083F\u085C-\u085F\u086B-\u089F\u08B5\u08C8-\u08D2\u08E2\u0964\u0965\u0970\u0984\u098D\u098E\u0991\u0992\u09A9\u09B1\u09B3-\u09B5\u09BA\u09BB\u09C5\u09C6\u09C9\u09CA\u09CF-\u09D6\u09D8-\u09DB\u09DE\u09E4\u09E5\u09F2-\u09FB\u09FD\u09FF\u0A00\u0A04\u0A0B-\u0A0E\u0A11\u0A12\u0A29\u0A31\u0A34\u0A37\u0A3A\u0A3B\u0A3D\u0A43-\u0A46\u0A49\u0A4A\u0A4E-\u0A50\u0A52-\u0A58\u0A5D\u0A5F-\u0A65\u0A76-\u0A80\u0A84\u0A8E\u0A92\u0AA9\u0AB1\u0AB4\u0ABA\u0ABB\u0AC6\u0ACA\u0ACE\u0ACF\u0AD1-\u0ADF\u0AE4\u0AE5\u0AF0-\u0AF8\u0B00\u0B04\u0B0D\u0B0E\u0B11\u0B12\u0B29\u0B31\u0B34\u0B3A\u0B3B\u0B45\u0B46\u0B49\u0B4A\u0B4E-\u0B54\u0B58-\u0B5B\u0B5E\u0B64\u0B65\u0B70\u0B72-\u0B81\u0B84\u0B8B-\u0B8D\u0B91\u0B96-\u0B98\u0B9B\u0B9D\u0BA0-\u0BA2\u0BA5-\u0BA7\u0BAB-\u0BAD\u0BBA-\u0BBD\u0BC3-\u0BC5\u0BC9\u0BCE\u0BCF\u0BD1-\u0BD6\u0BD8-\u0BE5\u0BF0-\u0BFF\u0C0D\u0C11\u0C29\u0C3A-\u0C3C\u0C45\u0C49\u0C4E-\u0C54\u0C57\u0C5B-\u0C5F\u0C64\u0C65\u0C70-\u0C7F\u0C84\u0C8D\u0C91\u0CA9\u0CB4\u0CBA\u0CBB\u0CC5\u0CC9\u0CCE-\u0CD4\u0CD7-\u0CDD\u0CDF\u0CE4\u0CE5\u0CF0\u0CF3-\u0CFF\u0D0D\u0D11\u0D45\u0D49\u0D4F-\u0D53\u0D58-\u0D5E\u0D64\u0D65\u0D70-\u0D79\u0D80\u0D84\u0D97-\u0D99\u0DB2\u0DBC\u0DBE\u0DBF\u0DC7-\u0DC9\u0DCB-\u0DCE\u0DD5\u0DD7\u0DE0-\u0DE5\u0DF0\u0DF1\u0DF4-\u0E00\u0E3B-\u0E3F\u0E4F\u0E5A-\u0E80\u0E83\u0E85\u0E8B\u0EA4\u0EA6\u0EBE\u0EBF\u0EC5\u0EC7\u0ECE\u0ECF\u0EDA\u0EDB\u0EE0-\u0EFF\u0F01-\u0F17\u0F1A-\u0F1F\u0F2A-\u0F34\u0F36\u0F38\u0F3A-\u0F3D\u0F48\u0F6D-\u0F70\u0F85\u0F98\u0FBD-\u0FC5\u0FC7-\u0FFF\u104A-\u104F\u109E\u109F\u10C6\u10C8-\u10CC\u10CE\u10CF\u10FB\u1249\u124E\u124F\u1257\u1259\u125E\u125F\u1289\u128E\u128F\u12B1\u12B6\u12B7\u12BF\u12C1\u12C6\u12C7\u12D7\u1311\u1316\u1317\u135B\u135C\u1360-\u137F\u1390-\u139F\u13F6\u13F7\u13FE-\u1400\u166D\u166E\u1680\u169B-\u169F\u16EB-\u16ED\u16F9-\u16FF\u170D\u1715-\u171F\u1735-\u173F\u1754-\u175F\u176D\u1771\u1774-\u177F\u17D4-\u17D6\u17D8-\u17DB\u17DE\u17DF\u17EA-\u180A\u180E\u180F\u181A-\u181F\u1879-\u187F\u18AB-\u18AF\u18F6-\u18FF\u191F\u192C-\u192F\u193C-\u1945\u196E\u196F\u1975-\u197F\u19AC-\u19AF\u19CA-\u19CF\u19DA-\u19FF\u1A1C-\u1A1F\u1A5F\u1A7D\u1A7E\u1A8A-\u1A8F\u1A9A-\u1AA6\u1AA8-\u1AAF\u1AC1-\u1AFF\u1B4C-\u1B4F\u1B5A-\u1B6A\u1B74-\u1B7F\u1BF4-\u1BFF\u1C38-\u1C3F\u1C4A-\u1C4C\u1C7E\u1C7F\u1C89-\u1C8F\u1CBB\u1CBC\u1CC0-\u1CCF\u1CD3\u1CFB-\u1CFF\u1DFA\u1F16\u1F17\u1F1E\u1F1F\u1F46\u1F47\u1F4E\u1F4F\u1F58\u1F5A\u1F5C\u1F5E\u1F7E\u1F7F\u1FB5\u1FBD\u1FBF-\u1FC1\u1FC5\u1FCD-\u1FCF\u1FD4\u1FD5\u1FDC-\u1FDF\u1FED-\u1FF1\u1FF5\u1FFD-\u203E\u2041-\u2053\u2055-\u2070\u2072-\u207E\u2080-\u208F\u209D-\u20CF\u20F1-\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211E-\u2123\u2125\u2127\u2129\u212E\u213A\u213B\u2140-\u2144\u214A-\u214D\u214F-\u215F\u2189-\u24B5\u24EA-\u2BFF\u2C2F\u2C5F\u2CE5-\u2CEA\u2CF4-\u2CFF\u2D26\u2D28-\u2D2C\u2D2E\u2D2F\u2D68-\u2D6E\u2D70-\u2D7E\u2D97-\u2D9F\u2DA7\u2DAF\u2DB7\u2DBF\u2DC7\u2DCF\u2DD7\u2DDF\u2E00-\u2E2E\u2E30-\u3004\u3008-\u3020\u3030\u3036\u3037\u303D-\u3040\u3097\u3098\u309B\u309C\u30A0\u30FB\u3100-\u3104\u3130\u318F-\u319F\u31C0-\u31EF\u3200-\u33FF\u4DC0-\u4DFF\u9FFD-\u9FFF\uA48D-\uA4CF\uA4FE\uA4FF\uA60D-\uA60F\uA62C-\uA63F\uA673\uA67E\uA6F2-\uA716\uA720\uA721\uA789\uA78A\uA7C0\uA7C1\uA7CB-\uA7F4\uA828-\uA82B\uA82D-\uA83F\uA874-\u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1-\uDFFF]|\uD87E[\uDE1E-\uDFFF]|\uD884[\uDF4B-\uDFFF]|\uDB40[\uDC00-\uDCFF\uDDF0-\uDFFF]/g;}});function slug(value,maintainCase){return typeof value!="string"?"":(maintainCase||(value=value.toLowerCase()),value.replace(regex,"").replace(/ /g,"-"))}var own,BananaSlug,init_github_slugger=__esm({"../../node_modules/github-slugger/index.js"(){init_regex();own=Object.hasOwnProperty,BananaSlug=class{constructor(){this.occurrences,this.reset();}slug(value,maintainCase){let self2=this,result=slug(value,maintainCase===!0),originalSlug=result;for(;own.call(self2.occurrences,result);)self2.occurrences[originalSlug]++,result=originalSlug+"-"+self2.occurrences[originalSlug];return self2.occurrences[result]=0,result}reset(){this.occurrences=Object.create(null);}};}});function headingRank(node2){let name2=node2.type==="element"?node2.tagName.toLowerCase():"",code2=name2.length===2&&name2.charCodeAt(0)===104?name2.charCodeAt(1):0;return code2>48&&code2<55?code2-48:void 0}var init_lib=__esm({"../../node_modules/hast-util-heading-rank/lib/index.js"(){}});var init_hast_util_heading_rank=__esm({"../../node_modules/hast-util-heading-rank/index.js"(){init_lib();}});function toString(node2){return "children"in node2?all(node2):"value"in node2?node2.value:""}function one(node2){return node2.type==="text"?node2.value:"children"in node2?all(node2):""}function all(node2){let index2=-1,result=[];for(;++index2<node2.children.length;)result[index2]=one(node2.children[index2]);return result.join("")}var init_lib2=__esm({"../../node_modules/hast-util-to-string/lib/index.js"(){}});var init_hast_util_to_string=__esm({"../../node_modules/hast-util-to-string/index.js"(){init_lib2();}});function anyFactory(tests){let checks2=[],index2=-1;for(;++index2<tests.length;)checks2[index2]=convert(tests[index2]);return castFactory(any);function any(...parameters){let index3=-1;for(;++index3<checks2.length;)if(checks2[index3].apply(this,parameters))return !0;return !1}}function propsFactory(check){let checkAsRecord=check;return castFactory(all4);function all4(node2){let nodeAsRecord=node2,key;for(key in check)if(nodeAsRecord[key]!==checkAsRecord[key])return !1;return !0}}function typeFactory(check){return castFactory(type);function type(node2){return node2&&node2.type===check}}function castFactory(testFunction){return check;function check(value,index2,parent){return !!(looksLikeANode(value)&&testFunction.call(this,value,typeof index2=="number"?index2:void 0,parent||void 0))}}function ok(){return !0}function looksLikeANode(value){return value!==null&&typeof value=="object"&&"type"in value}var convert,init_lib3=__esm({"../../node_modules/unist-util-is/lib/index.js"(){convert=function(test){if(test==null)return ok;if(typeof test=="function")return castFactory(test);if(typeof test=="object")return Array.isArray(test)?anyFactory(test):propsFactory(test);if(typeof test=="string")return typeFactory(test);throw new Error("Expected function, string, or object as test")};}});var init_unist_util_is=__esm({"../../node_modules/unist-util-is/index.js"(){init_lib3();}});function color(d){return "\x1B[33m"+d+"\x1B[39m"}var init_color_node=__esm({"../../node_modules/unist-util-visit-parents/lib/color.node.js"(){}});function visitParents(tree,test,visitor,reverse){let check;typeof test=="function"&&typeof visitor!="function"?(reverse=visitor,visitor=test):check=test;let is2=convert(check),step=reverse?-1:1;factory(tree,void 0,[])();function factory(node2,index2,parents){let value=node2&&typeof node2=="object"?node2:{};if(typeof value.type=="string"){let name2=typeof value.tagName=="string"?value.tagName:typeof value.name=="string"?value.name:void 0;Object.defineProperty(visit3,"name",{value:"node ("+color(node2.type+(name2?"<"+name2+">":""))+")"});}return visit3;function visit3(){let result=empty,subresult,offset3,grandparents;if((!test||is2(node2,index2,parents[parents.length-1]||void 0))&&(result=toResult(visitor(node2,parents)),result[0]===EXIT))return result;if("children"in node2&&node2.children){let nodeAsParent=node2;if(nodeAsParent.children&&result[0]!==SKIP)for(offset3=(reverse?nodeAsParent.children.length:-1)+step,grandparents=parents.concat(nodeAsParent);offset3>-1&&offset3<nodeAsParent.children.length;){let child=nodeAsParent.children[offset3];if(subresult=factory(child,offset3,grandparents)(),subresult[0]===EXIT)return subresult;offset3=typeof subresult[1]=="number"?subresult[1]:offset3+step;}}return result}}}function toResult(value){return Array.isArray(value)?value:typeof value=="number"?[CONTINUE,value]:value==null?empty:[value]}var empty,CONTINUE,EXIT,SKIP,init_lib4=__esm({"../../node_modules/unist-util-visit-parents/lib/index.js"(){init_unist_util_is();init_color_node();empty=[],CONTINUE=!0,EXIT=!1,SKIP="skip";}});var init_unist_util_visit_parents=__esm({"../../node_modules/unist-util-visit-parents/index.js"(){init_lib4();}});function visit(tree,testOrVisitor,visitorOrReverse,maybeReverse){let reverse,test,visitor;typeof testOrVisitor=="function"&&typeof visitorOrReverse!="function"?(test=void 0,visitor=testOrVisitor,reverse=visitorOrReverse):(test=testOrVisitor,visitor=visitorOrReverse,reverse=maybeReverse),visitParents(tree,test,overload,reverse);function overload(node2,parents){let parent=parents[parents.length-1],index2=parent?parent.children.indexOf(node2):void 0;return visitor(node2,index2,parent)}}var init_lib5=__esm({"../../node_modules/unist-util-visit/lib/index.js"(){init_unist_util_visit_parents();}});var init_unist_util_visit=__esm({"../../node_modules/unist-util-visit/index.js"(){init_lib5();}});function rehypeSlug(options){let prefix=(options||emptyOptions).prefix||"";return function(tree){slugs.reset(),visit(tree,"element",function(node2){headingRank(node2)&&!node2.properties.id&&(node2.properties.id=prefix+slugs.slug(toString(node2)));});}}var emptyOptions,slugs,init_lib6=__esm({"../../node_modules/rehype-slug/lib/index.js"(){init_github_slugger();init_hast_util_heading_rank();init_hast_util_to_string();init_unist_util_visit();emptyOptions={},slugs=new BananaSlug;}});var rehype_slug_exports={};__export(rehype_slug_exports,{default:()=>rehypeSlug});var init_rehype_slug=__esm({"../../node_modules/rehype-slug/index.js"(){init_lib6();}});var env,deserializer,deserialize,init_deserialize=__esm({"../../node_modules/@ungap/structured-clone/esm/deserialize.js"(){env=typeof self=="object"?self:globalThis,deserializer=($,_)=>{let as=(out,index2)=>($.set(index2,out),out),unpair=index2=>{if($.has(index2))return $.get(index2);let[type,value]=_[index2];switch(type){case 0:case-1:return as(value,index2);case 1:{let arr=as([],index2);for(let index3 of value)arr.push(unpair(index3));return arr}case 2:{let object=as({},index2);for(let[key,index3]of value)object[unpair(key)]=unpair(index3);return object}case 3:return as(new Date(value),index2);case 4:{let{source,flags}=value;return as(new RegExp(source,flags),index2)}case 5:{let map=as(new Map,index2);for(let[key,index3]of value)map.set(unpair(key),unpair(index3));return map}case 6:{let set=as(new Set,index2);for(let index3 of value)set.add(unpair(index3));return set}case 7:{let{name:name2,message}=value;return as(new env[name2](message),index2)}case 8:return as(BigInt(value),index2);case"BigInt":return as(Object(BigInt(value)),index2);case"ArrayBuffer":return as(new Uint8Array(value).buffer,value);case"DataView":{let{buffer}=new Uint8Array(value);return as(new DataView(buffer),value)}}return as(new env[type](value),index2)};return unpair},deserialize=serialized=>deserializer(new Map,serialized)(0);}});var EMPTY,toString2,keys,typeOf,shouldSkip,serializer,serialize,init_serialize=__esm({"../../node_modules/@ungap/structured-clone/esm/serialize.js"(){EMPTY="",{toString:toString2}={},{keys}=Object,typeOf=value=>{let type=typeof value;if(type!=="object"||!value)return [0,type];let asString=toString2.call(value).slice(8,-1);switch(asString){case"Array":return [1,EMPTY];case"Object":return [2,EMPTY];case"Date":return [3,EMPTY];case"RegExp":return [4,EMPTY];case"Map":return [5,EMPTY];case"Set":return [6,EMPTY];case"DataView":return [1,asString]}return asString.includes("Array")?[1,asString]:asString.includes("Error")?[7,asString]:[2,asString]},shouldSkip=([TYPE,type])=>TYPE===0&&(type==="function"||type==="symbol"),serializer=(strict,json,$,_)=>{let as=(out,value)=>{let index2=_.push(out)-1;return $.set(value,index2),index2},pair=value=>{if($.has(value))return $.get(value);let[TYPE,type]=typeOf(value);switch(TYPE){case 0:{let entry=value;switch(type){case"bigint":TYPE=8,entry=value.toString();break;case"function":case"symbol":if(strict)throw new TypeError("unable to serialize "+type);entry=null;break;case"undefined":return as([-1],value)}return as([TYPE,entry],value)}case 1:{if(type){let spread=value;return type==="DataView"?spread=new Uint8Array(value.buffer):type==="ArrayBuffer"&&(spread=new Uint8Array(value)),as([type,[...spread]],value)}let arr=[],index2=as([TYPE,arr],value);for(let entry of value)arr.push(pair(entry));return index2}case 2:{if(type)switch(type){case"BigInt":return as([type,value.toString()],value);case"Boolean":case"Number":case"String":return as([type,value.valueOf()],value)}if(json&&"toJSON"in value)return pair(value.toJSON());let entries=[],index2=as([TYPE,entries],value);for(let key of keys(value))(strict||!shouldSkip(typeOf(value[key])))&&entries.push([pair(key),pair(value[key])]);return index2}case 3:return as([TYPE,value.toISOString()],value);case 4:{let{source,flags}=value;return as([TYPE,{source,flags}],value)}case 5:{let entries=[],index2=as([TYPE,entries],value);for(let[key,entry]of value)(strict||!(shouldSkip(typeOf(key))||shouldSkip(typeOf(entry))))&&entries.push([pair(key),pair(entry)]);return index2}case 6:{let entries=[],index2=as([TYPE,entries],value);for(let entry of value)(strict||!shouldSkip(typeOf(entry)))&&entries.push(pair(entry));return index2}}let{message}=value;return as([TYPE,{name:type,message}],value)};return pair},serialize=(value,{json,lossy}={})=>{let _=[];return serializer(!(json||lossy),!!json,new Map,_)(value),_};}});var esm_default,init_esm=__esm({"../../node_modules/@ungap/structured-clone/esm/index.js"(){init_deserialize();init_serialize();esm_default=typeof structuredClone=="function"?(any,options)=>options&&("json"in options||"lossy"in options)?deserialize(serialize(any,options)):structuredClone(any):(any,options)=>deserialize(serialize(any,options));}});function anyFactory2(tests){let checks2=[],index2=-1;for(;++index2<tests.length;)checks2[index2]=convertElement(tests[index2]);return castFactory2(any);function any(...parameters){let index3=-1;for(;++index3<checks2.length;)if(checks2[index3].apply(this,parameters))return !0;return !1}}function tagNameFactory(check){return castFactory2(tagName);function tagName(element3){return element3.tagName===check}}function castFactory2(testFunction){return check;function check(value,index2,parent){return !!(looksLikeAnElement(value)&&testFunction.call(this,value,typeof index2=="number"?index2:void 0,parent||void 0))}}function element(element3){return !!(element3&&typeof element3=="object"&&"type"in element3&&element3.type==="element"&&"tagName"in element3&&typeof element3.tagName=="string")}function looksLikeAnElement(value){return value!==null&&typeof value=="object"&&"type"in value&&"tagName"in value}var convertElement,init_lib7=__esm({"../../node_modules/hast-util-is-element/lib/index.js"(){convertElement=function(test){if(test==null)return element;if(typeof test=="string")return tagNameFactory(test);if(typeof test=="object")return anyFactory2(test);if(typeof test=="function")return castFactory2(test);throw new Error("Expected function, string, or array as `test`")};}});var init_hast_util_is_element=__esm({"../../node_modules/hast-util-is-element/index.js"(){init_lib7();}});function isAbsoluteUrl(url){if(typeof url!="string")throw new TypeError(`Expected a \`string\`, got \`${typeof url}\``);return WINDOWS_PATH_REGEX.test(url)?!1:ABSOLUTE_URL_REGEX.test(url)}var ABSOLUTE_URL_REGEX,WINDOWS_PATH_REGEX,init_is_absolute_url=__esm({"../../node_modules/is-absolute-url/index.js"(){ABSOLUTE_URL_REGEX=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,WINDOWS_PATH_REGEX=/^[a-zA-Z]:\\/;}});function parse(value){let input=String(value||"").trim();return input?input.split(/[ \t\n\r\f]+/g):[]}function stringify(values){return values.join(" ").trim()}var init_space_separated_tokens=__esm({"../../node_modules/space-separated-tokens/index.js"(){}});function rehypeExternalLinks(options){let settings=options||emptyOptions2,protocols=settings.protocols||defaultProtocols,is2=convertElement(settings.test);return function(tree){visit(tree,"element",function(node2,index2,parent){if(node2.tagName==="a"&&typeof node2.properties.href=="string"&&is2(node2,index2,parent)){let url=node2.properties.href;if(isAbsoluteUrl(url)?protocols.includes(url.slice(0,url.indexOf(":"))):url.startsWith("//")){let contentRaw=createIfNeeded(settings.content,node2),content3=contentRaw&&!Array.isArray(contentRaw)?[contentRaw]:contentRaw,relRaw=createIfNeeded(settings.rel,node2)||defaultRel,rel=typeof relRaw=="string"?parse(relRaw):relRaw,target=createIfNeeded(settings.target,node2),properties=createIfNeeded(settings.properties,node2);if(properties&&Object.assign(node2.properties,esm_default(properties)),rel.length>0&&(node2.properties.rel=[...rel]),target&&(node2.properties.target=target),content3){let properties2=createIfNeeded(settings.contentProperties,node2)||{};node2.children.push({type:"element",tagName:"span",properties:esm_default(properties2),children:esm_default(content3)});}}}});}}function createIfNeeded(value,element3){return typeof value=="function"?value(element3):value}var defaultProtocols,defaultRel,emptyOptions2,init_lib8=__esm({"../../node_modules/rehype-external-links/lib/index.js"(){init_esm();init_hast_util_is_element();init_is_absolute_url();init_space_separated_tokens();init_unist_util_visit();defaultProtocols=["http","https"],defaultRel=["nofollow"],emptyOptions2={};}});var rehype_external_links_exports={};__export(rehype_external_links_exports,{default:()=>rehypeExternalLinks});var init_rehype_external_links=__esm({"../../node_modules/rehype-external-links/index.js"(){init_lib8();}});var init_estree_walker=__esm({"../../node_modules/@rollup/pluginutils/node_modules/estree-walker/dist/esm/estree-walker.js"(){}});var require_constants=__commonJS({"../../node_modules/@rollup/pluginutils/node_modules/picomatch/lib/constants.js"(exports,module){var WIN_SLASH="\\\\/",WIN_NO_SLASH=`[^${WIN_SLASH}]`,DOT_LITERAL="\\.",PLUS_LITERAL="\\+",QMARK_LITERAL="\\?",SLASH_LITERAL="\\/",ONE_CHAR="(?=.)",QMARK="[^/]",END_ANCHOR=`(?:${SLASH_LITERAL}|$)`,START_ANCHOR=`(?:^|${SLASH_LITERAL})`,DOTS_SLASH=`${DOT_LITERAL}{1,2}${END_ANCHOR}`,NO_DOT=`(?!${DOT_LITERAL})`,NO_DOTS=`(?!${START_ANCHOR}${DOTS_SLASH})`,NO_DOT_SLASH=`(?!${DOT_LITERAL}{0,1}${END_ANCHOR})`,NO_DOTS_SLASH=`(?!${DOTS_SLASH})`,QMARK_NO_DOT=`[^.${SLASH_LITERAL}]`,STAR=`${QMARK}*?`,SEP="/",POSIX_CHARS={DOT_LITERAL,PLUS_LITERAL,QMARK_LITERAL,SLASH_LITERAL,ONE_CHAR,QMARK,END_ANCHOR,DOTS_SLASH,NO_DOT,NO_DOTS,NO_DOT_SLASH,NO_DOTS_SLASH,QMARK_NO_DOT,STAR,START_ANCHOR,SEP},WINDOWS_CHARS={...POSIX_CHARS,SLASH_LITERAL:`[${WIN_SLASH}]`,QMARK:WIN_NO_SLASH,STAR:`${WIN_NO_SLASH}*?`,DOTS_SLASH:`${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$)`,NO_DOT:`(?!${DOT_LITERAL})`,NO_DOTS:`(?!(?:^|[${WIN_SLASH}])${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`,NO_DOT_SLASH:`(?!${DOT_LITERAL}{0,1}(?:[${WIN_SLASH}]|$))`,NO_DOTS_SLASH:`(?!${DOT_LITERAL}{1,2}(?:[${WIN_SLASH}]|$))`,QMARK_NO_DOT:`[^.${WIN_SLASH}]`,START_ANCHOR:`(?:^|[${WIN_SLASH}])`,END_ANCHOR:`(?:[${WIN_SLASH}]|$)`,SEP:"\\"},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"};module.exports={MAX_LENGTH:1024*64,POSIX_REGEX_SOURCE,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:{"***":"*","**/**":"**","**/**/**":"**"},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(chars){return {"!":{type:"negate",open:"(?:(?!(?:",close:`))${chars.STAR})`},"?":{type:"qmark",open:"(?:",close:")?"},"+":{type:"plus",open:"(?:",close:")+"},"*":{type:"star",open:"(?:",close:")*"},"@":{type:"at",open:"(?:",close:")"}}},globChars(win322){return win322===!0?WINDOWS_CHARS:POSIX_CHARS}};}});var require_utils=__commonJS({"../../node_modules/@rollup/pluginutils/node_modules/picomatch/lib/utils.js"(exports){var{REGEX_BACKSLASH,REGEX_REMOVE_BACKSLASH,REGEX_SPECIAL_CHARS,REGEX_SPECIAL_CHARS_GLOBAL}=require_constants();exports.isObject=val=>val!==null&&typeof val=="object"&&!Array.isArray(val);exports.hasRegexChars=str=>REGEX_SPECIAL_CHARS.test(str);exports.isRegexChar=str=>str.length===1&&exports.hasRegexChars(str);exports.escapeRegex=str=>str.replace(REGEX_SPECIAL_CHARS_GLOBAL,"\\$1");exports.toPosixSlashes=str=>str.replace(REGEX_BACKSLASH,"/");exports.isWindows=()=>{if(typeof navigator<"u"&&navigator.platform){let platform=navigator.platform.toLowerCase();return platform==="win32"||platform==="windows"}return typeof process<"u"&&process.platform?process.platform==="win32":!1};exports.removeBackslashes=str=>str.replace(REGEX_REMOVE_BACKSLASH,match=>match==="\\"?"":match);exports.escapeLast=(input,char,lastIdx)=>{let idx=input.lastIndexOf(char,lastIdx);return idx===-1?input:input[idx-1]==="\\"?exports.escapeLast(input,char,idx-1):`${input.slice(0,idx)}\\${input.slice(idx)}`};exports.removePrefix=(input,state={})=>{let output=input;return output.startsWith("./")&&(output=output.slice(2),state.prefix="./"),output};exports.wrapOutput=(input,state={},options={})=>{let prepend=options.contains?"":"^",append=options.contains?"":"$",output=`${prepend}(?:${input})${append}`;return state.negated===!0&&(output=`(?:^(?!${output}).*$)`),output};exports.basename=(path,{windows}={})=>{let segs=path.split(windows?/[\\/]/:"/"),last=segs[segs.length-1];return last===""?segs[segs.length-2]:last};}});var require_scan=__commonJS({"../../node_modules/@rollup/pluginutils/node_modules/picomatch/lib/scan.js"(exports,module){var utils=require_utils(),{CHAR_ASTERISK,CHAR_AT,CHAR_BACKWARD_SLASH,CHAR_COMMA,CHAR_DOT,CHAR_EXCLAMATION_MARK,CHAR_FORWARD_SLASH,CHAR_LEFT_CURLY_BRACE,CHAR_LEFT_PARENTHESES,CHAR_LEFT_SQUARE_BRACKET,CHAR_PLUS,CHAR_QUESTION_MARK,CHAR_RIGHT_CURLY_BRACE,CHAR_RIGHT_PARENTHESES,CHAR_RIGHT_SQUARE_BRACKET}=require_constants(),isPathSeparator=code2=>code2===CHAR_FORWARD_SLASH||code2===CHAR_BACKWARD_SLASH,depth=token=>{token.isPrefix!==!0&&(token.depth=token.isGlobstar?1/0:1);},scan=(input,options)=>{let opts=options||{},length=input.length-1,scanToEnd=opts.parts===!0||opts.scanToEnd===!0,slashes=[],tokens=[],parts=[],str=input,index2=-1,start2=0,lastIndex=0,isBrace=!1,isBracket=!1,isGlob=!1,isExtglob=!1,isGlobstar=!1,braceEscaped=!1,backslashes=!1,negated=!1,negatedExtglob=!1,finished=!1,braces=0,prev,code2,token={value:"",depth:0,isGlob:!1},eos=()=>index2>=length,peek=()=>str.charCodeAt(index2+1),advance3=()=>(prev=code2,str.charCodeAt(++index2));for(;index2<length;){code2=advance3();let next;if(code2===CHAR_BACKWARD_SLASH){backslashes=token.backslashes=!0,code2=advance3(),code2===CHAR_LEFT_CURLY_BRACE&&(braceEscaped=!0);continue}if(braceEscaped===!0||code2===CHAR_LEFT_CURLY_BRACE){for(braces++;eos()!==!0&&(code2=advance3());){if(code2===CHAR_BACKWARD_SLASH){backslashes=token.backslashes=!0,advance3();continue}if(code2===CHAR_LEFT_CURLY_BRACE){braces++;continue}if(braceEscaped!==!0&&code2===CHAR_DOT&&(code2=advance3())===CHAR_DOT){if(isBrace=token.isBrace=!0,isGlob=token.isGlob=!0,finished=!0,scanToEnd===!0)continue;break}if(braceEscaped!==!0&&code2===CHAR_COMMA){if(isBrace=token.isBrace=!0,isGlob=token.isGlob=!0,finished=!0,scanToEnd===!0)continue;break}if(code2===CHAR_RIGHT_CURLY_BRACE&&(braces--,braces===0)){braceEscaped=!1,isBrace=token.isBrace=!0,finished=!0;break}}if(scanToEnd===!0)continue;break}if(code2===CHAR_FORWARD_SLASH){if(slashes.push(index2),tokens.push(token),token={value:"",depth:0,isGlob:!1},finished===!0)continue;if(prev===CHAR_DOT&&index2===start2+1){start2+=2;continue}lastIndex=index2+1;continue}if(opts.noext!==!0&&(code2===CHAR_PLUS||code2===CHAR_AT||code2===CHAR_ASTERISK||code2===CHAR_QUESTION_MARK||code2===CHAR_EXCLAMATION_MARK)===!0&&peek()===CHAR_LEFT_PARENTHESES){if(isGlob=token.isGlob=!0,isExtglob=token.isExtglob=!0,finished=!0,code2===CHAR_EXCLAMATION_MARK&&index2===start2&&(negatedExtglob=!0),scanToEnd===!0){for(;eos()!==!0&&(code2=advance3());){if(code2===CHAR_BACKWARD_SLASH){backslashes=token.backslashes=!0,code2=advance3();continue}if(code2===CHAR_RIGHT_PARENTHESES){isGlob=token.isGlob=!0,finished=!0;break}}continue}break}if(code2===CHAR_ASTERISK){if(prev===CHAR_ASTERISK&&(isGlobstar=token.isGlobstar=!0),isGlob=token.isGlob=!0,finished=!0,scanToEnd===!0)continue;break}if(code2===CHAR_QUESTION_MARK){if(isGlob=token.isGlob=!0,finished=!0,scanToEnd===!0)continue;break}if(code2===CHAR_LEFT_SQUARE_BRACKET){for(;eos()!==!0&&(next=advance3());){if(next===CHAR_BACKWARD_SLASH){backslashes=token.backslashes=!0,advance3();continue}if(next===CHAR_RIGHT_SQUARE_BRACKET){isBracket=token.isBracket=!0,isGlob=token.isGlob=!0,finished=!0;break}}if(scanToEnd===!0)continue;break}if(opts.nonegate!==!0&&code2===CHAR_EXCLAMATION_MARK&&index2===start2){negated=token.negated=!0,start2++;continue}if(opts.noparen!==!0&&code2===CHAR_LEFT_PARENTHESES){if(isGlob=token.isGlob=!0,scanToEnd===!0){for(;eos()!==!0&&(code2=advance3());){if(code2===CHAR_LEFT_PARENTHESES){backslashes=token.backslashes=!0,code2=advance3();continue}if(code2===CHAR_RIGHT_PARENTHESES){finished=!0;break}}continue}break}if(isGlob===!0){if(finished=!0,scanToEnd===!0)continue;break}}opts.noext===!0&&(isExtglob=!1,isGlob=!1);let base=str,prefix="",glob="";start2>0&&(prefix=str.slice(0,start2),str=str.slice(start2),lastIndex-=start2),base&&isGlob===!0&&lastIndex>0?(base=str.slice(0,lastIndex),glob=str.slice(lastIndex)):isGlob===!0?(base="",glob=str):base=str,base&&base!==""&&base!=="/"&&base!==str&&isPathSeparator(base.charCodeAt(base.length-1))&&(base=base.slice(0,-1)),opts.unescape===!0&&(glob&&(glob=utils.removeBackslashes(glob)),base&&backslashes===!0&&(base=utils.removeBackslashes(base)));let state={prefix,input,start:start2,base,glob,isBrace,isBracket,isGlob,isExtglob,isGlobstar,negated,negatedExtglob};if(opts.tokens===!0&&(state.maxDepth=0,isPathSeparator(code2)||tokens.push(token),state.tokens=tokens),opts.parts===!0||opts.tokens===!0){let prevIndex;for(let idx=0;idx<slashes.length;idx++){let n=prevIndex?prevIndex+1:start2,i=slashes[idx],value=input.slice(n,i);opts.tokens&&(idx===0&&start2!==0?(tokens[idx].isPrefix=!0,tokens[idx].value=prefix):tokens[idx].value=value,depth(tokens[idx]),state.maxDepth+=tokens[idx].depth),(idx!==0||value!=="")&&parts.push(value),prevIndex=i;}if(prevIndex&&prevIndex+1<input.length){let value=input.slice(prevIndex+1);parts.push(value),opts.tokens&&(tokens[tokens.length-1].value=value,depth(tokens[tokens.length-1]),state.maxDepth+=tokens[tokens.length-1].depth);}state.slashes=slashes,state.parts=parts;}return state};module.exports=scan;}});var require_parse=__commonJS({"../../node_modules/@rollup/pluginutils/node_modules/picomatch/lib/parse.js"(exports,module){var constants=require_constants(),utils=require_utils(),{MAX_LENGTH,POSIX_REGEX_SOURCE,REGEX_NON_SPECIAL_CHARS,REGEX_SPECIAL_CHARS_BACKREF,REPLACEMENTS}=constants,expandRange=(args,options)=>{if(typeof options.expandRange=="function")return options.expandRange(...args,options);args.sort();let value=`[${args.join("-")}]`;try{new RegExp(value);}catch{return args.map(v=>utils.escapeRegex(v)).join("..")}return value},syntaxError=(type,char)=>`Missing ${type}: "${char}" - use "\\\\${char}" to match literal characters`,parse8=(input,options)=>{if(typeof input!="string")throw new TypeError("Expected a string");input=REPLACEMENTS[input]||input;let opts={...options},max=typeof opts.maxLength=="number"?Math.min(MAX_LENGTH,opts.maxLength):MAX_LENGTH,len=input.length;if(len>max)throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);let bos={type:"bos",value:"",output:opts.prepend||""},tokens=[bos],capture=opts.capture?"":"?:",PLATFORM_CHARS=constants.globChars(opts.windows),EXTGLOB_CHARS=constants.extglobChars(PLATFORM_CHARS),{DOT_LITERAL,PLUS_LITERAL,SLASH_LITERAL,ONE_CHAR,DOTS_SLASH,NO_DOT,NO_DOT_SLASH,NO_DOTS_SLASH,QMARK,QMARK_NO_DOT,STAR,START_ANCHOR}=PLATFORM_CHARS,globstar=opts2=>`(${capture}(?:(?!${START_ANCHOR}${opts2.dot?DOTS_SLASH:DOT_LITERAL}).)*?)`,nodot=opts.dot?"":NO_DOT,qmarkNoDot=opts.dot?QMARK:QMARK_NO_DOT,star=opts.bash===!0?globstar(opts):STAR;opts.capture&&(star=`(${star})`),typeof opts.noext=="boolean"&&(opts.noextglob=opts.noext);let state={input,index:-1,start:0,dot:opts.dot===!0,consumed:"",output:"",prefix:"",backtrack:!1,negated:!1,brackets:0,braces:0,parens:0,quotes:0,globstar:!1,tokens};input=utils.removePrefix(input,state),len=input.length;let extglobs=[],braces=[],stack=[],prev=bos,value,eos=()=>state.index===len-1,peek=state.peek=(n=1)=>input[state.index+n],advance3=state.advance=()=>input[++state.index]||"",remaining=()=>input.slice(state.index+1),consume=(value2="",num=0)=>{state.consumed+=value2,state.index+=num;},append=token=>{state.output+=token.output!=null?token.output:token.value,consume(token.value);},negate=()=>{let count=1;for(;peek()==="!"&&(peek(2)!=="("||peek(3)==="?");)advance3(),state.start++,count++;return count%2===0?!1:(state.negated=!0,state.start++,!0)},increment2=type=>{state[type]++,stack.push(type);},decrement=type=>{state[type]--,stack.pop();},push2=tok=>{if(prev.type==="globstar"){let isBrace=state.braces>0&&(tok.type==="comma"||tok.type==="brace"),isExtglob=tok.extglob===!0||extglobs.length&&(tok.type==="pipe"||tok.type==="paren");tok.type!=="slash"&&tok.type!=="paren"&&!isBrace&&!isExtglob&&(state.output=state.output.slice(0,-prev.output.length),prev.type="star",prev.value="*",prev.output=star,state.output+=prev.output);}if(extglobs.length&&tok.type!=="paren"&&(extglobs[extglobs.length-1].inner+=tok.value),(tok.value||tok.output)&&append(tok),prev&&prev.type==="text"&&tok.type==="text"){prev.output=(prev.output||prev.value)+tok.value,prev.value+=tok.value;return}tok.prev=prev,tokens.push(tok),prev=tok;},extglobOpen=(type,value2)=>{let token={...EXTGLOB_CHARS[value2],conditions:1,inner:""};token.prev=prev,token.parens=state.parens,token.output=state.output;let output=(opts.capture?"(":"")+token.open;increment2("parens"),push2({type,value:value2,output:state.output?"":ONE_CHAR}),push2({type:"paren",extglob:!0,value:advance3(),output}),extglobs.push(token);},extglobClose=token=>{let output=token.close+(opts.capture?")":""),rest;if(token.type==="negate"){let extglobStar=star;if(token.inner&&token.inner.length>1&&token.inner.includes("/")&&(extglobStar=globstar(opts)),(extglobStar!==star||eos()||/^\)+$/.test(remaining()))&&(output=token.close=`)$))${extglobStar}`),token.inner.includes("*")&&(rest=remaining())&&/^\.[^\\/.]+$/.test(rest)){let expression=parse8(rest,{...options,fastpaths:!1}).output;output=token.close=`)${expression})${extglobStar})`;}token.prev.type==="bos"&&(state.negatedExtglob=!0);}push2({type:"paren",extglob:!0,value,output}),decrement("parens");};if(opts.fastpaths!==!1&&!/(^[*!]|[/()[\]{}"])/.test(input)){let backslashes=!1,output=input.replace(REGEX_SPECIAL_CHARS_BACKREF,(m,esc,chars,first,rest,index2)=>first==="\\"?(backslashes=!0,m):first==="?"?esc?esc+first+(rest?QMARK.repeat(rest.length):""):index2===0?qmarkNoDot+(rest?QMARK.repeat(rest.length):""):QMARK.repeat(chars.length):first==="."?DOT_LITERAL.repeat(chars.length):first==="*"?esc?esc+first+(rest?star:""):star:esc?m:`\\${m}`);return backslashes===!0&&(opts.unescape===!0?output=output.replace(/\\/g,""):output=output.replace(/\\+/g,m=>m.length%2===0?"\\\\":m?"\\":"")),output===input&&opts.contains===!0?(state.output=input,state):(state.output=utils.wrapOutput(output,state,options),state)}for(;!eos();){if(value=advance3(),value==="\0")continue;if(value==="\\"){let next=peek();if(next==="/"&&opts.bash!==!0||next==="."||next===";")continue;if(!next){value+="\\",push2({type:"text",value});continue}let match=/^\\+/.exec(remaining()),slashes=0;if(match&&match[0].length>2&&(slashes=match[0].length,state.index+=slashes,slashes%2!==0&&(value+="\\")),opts.unescape===!0?value=advance3():value+=advance3(),state.brackets===0){push2({type:"text",value});continue}}if(state.brackets>0&&(value!=="]"||prev.value==="["||prev.value==="[^")){if(opts.posix!==!1&&value===":"){let inner=prev.value.slice(1);if(inner.includes("[")&&(prev.posix=!0,inner.includes(":"))){let idx=prev.value.lastIndexOf("["),pre=prev.value.slice(0,idx),rest2=prev.value.slice(idx+2),posix2=POSIX_REGEX_SOURCE[rest2];if(posix2){prev.value=pre+posix2,state.backtrack=!0,advance3(),!bos.output&&tokens.indexOf(prev)===1&&(bos.output=ONE_CHAR);continue}}}(value==="["&&peek()!==":"||value==="-"&&peek()==="]")&&(value=`\\${value}`),value==="]"&&(prev.value==="["||prev.value==="[^")&&(value=`\\${value}`),opts.posix===!0&&value==="!"&&prev.value==="["&&(value="^"),prev.value+=value,append({value});continue}if(state.quotes===1&&value!=='"'){value=utils.escapeRegex(value),prev.value+=value,append({value});continue}if(value==='"'){state.quotes=state.quotes===1?0:1,opts.keepQuotes===!0&&push2({type:"text",value});continue}if(value==="("){increment2("parens"),push2({type:"paren",value});continue}if(value===")"){if(state.parens===0&&opts.strictBrackets===!0)throw new SyntaxError(syntaxError("opening","("));let extglob=extglobs[extglobs.length-1];if(extglob&&state.parens===extglob.parens+1){extglobClose(extglobs.pop());continue}push2({type:"paren",value,output:state.parens?")":"\\)"}),decrement("parens");continue}if(value==="["){if(opts.nobracket===!0||!remaining().includes("]")){if(opts.nobracket!==!0&&opts.strictBrackets===!0)throw new SyntaxError(syntaxError("closing","]"));value=`\\${value}`;}else increment2("brackets");push2({type:"bracket",value});continue}if(value==="]"){if(opts.nobracket===!0||prev&&prev.type==="bracket"&&prev.value.length===1){push2({type:"text",value,output:`\\${value}`});continue}if(state.brackets===0){if(opts.strictBrackets===!0)throw new SyntaxError(syntaxError("opening","["));push2({type:"text",value,output:`\\${value}`});continue}decrement("brackets");let prevValue=prev.value.slice(1);if(prev.posix!==!0&&prevValue[0]==="^"&&!prevValue.includes("/")&&(value=`/${value}`),prev.value+=value,append({value}),opts.literalBrackets===!1||utils.hasRegexChars(prevValue))continue;let escaped=utils.escapeRegex(prev.value);if(state.output=state.output.slice(0,-prev.value.length),opts.literalBrackets===!0){state.output+=escaped,prev.value=escaped;continue}prev.value=`(${capture}${escaped}|${prev.value})`,state.output+=prev.value;continue}if(value==="{"&&opts.nobrace!==!0){increment2("braces");let open={type:"brace",value,output:"(",outputIndex:state.output.length,tokensIndex:state.tokens.length};braces.push(open),push2(open);continue}if(value==="}"){let brace=braces[braces.length-1];if(opts.nobrace===!0||!brace){push2({type:"text",value,output:value});continue}let output=")";if(brace.dots===!0){let arr=tokens.slice(),range=[];for(let i=arr.length-1;i>=0&&(tokens.pop(),arr[i].type!=="brace");i--)arr[i].type!=="dots"&&range.unshift(arr[i].value);output=expandRange(range,opts),state.backtrack=!0;}if(brace.comma!==!0&&brace.dots!==!0){let out=state.output.slice(0,brace.outputIndex),toks=state.tokens.slice(brace.tokensIndex);brace.value=brace.output="\\{",value=output="\\}",state.output=out;for(let t of toks)state.output+=t.output||t.value;}push2({type:"brace",value,output}),decrement("braces"),braces.pop();continue}if(value==="|"){extglobs.length>0&&extglobs[extglobs.length-1].conditions++,push2({type:"text",value});continue}if(value===","){let output=value,brace=braces[braces.length-1];brace&&stack[stack.length-1]==="braces"&&(brace.comma=!0,output="|"),push2({type:"comma",value,output});continue}if(value==="/"){if(prev.type==="dot"&&state.index===state.start+1){state.start=state.index+1,state.consumed="",state.output="",tokens.pop(),prev=bos;continue}push2({type:"slash",value,output:SLASH_LITERAL});continue}if(value==="."){if(state.braces>0&&prev.type==="dot"){prev.value==="."&&(prev.output=DOT_LITERAL);let brace=braces[braces.length-1];prev.type="dots",prev.output+=value,prev.value+=value,brace.dots=!0;continue}if(state.braces+state.parens===0&&prev.type!=="bos"&&prev.type!=="slash"){push2({type:"text",value,output:DOT_LITERAL});continue}push2({type:"dot",value,output:DOT_LITERAL});continue}if(value==="?"){if(!(prev&&prev.value==="(")&&opts.noextglob!==!0&&peek()==="("&&peek(2)!=="?"){extglobOpen("qmark",value);continue}if(prev&&prev.type==="paren"){let next=peek(),output=value;(prev.value==="("&&!/[!=<:]/.test(next)||next==="<"&&!/<([!=]|\w+>)/.test(remaining()))&&(output=`\\${value}`),push2({type:"text",value,output});continue}if(opts.dot!==!0&&(prev.type==="slash"||prev.type==="bos")){push2({type:"qmark",value,output:QMARK_NO_DOT});continue}push2({type:"qmark",value,output:QMARK});continue}if(value==="!"){if(opts.noextglob!==!0&&peek()==="("&&(peek(2)!=="?"||!/[!=<:]/.test(peek(3)))){extglobOpen("negate",value);continue}if(opts.nonegate!==!0&&state.index===0){negate();continue}}if(value==="+"){if(opts.noextglob!==!0&&peek()==="("&&peek(2)!=="?"){extglobOpen("plus",value);continue}if(prev&&prev.value==="("||opts.regex===!1){push2({type:"plus",value,output:PLUS_LITERAL});continue}if(prev&&(prev.type==="bracket"||prev.type==="paren"||prev.type==="brace")||state.parens>0){push2({type:"plus",value});continue}push2({type:"plus",value:PLUS_LITERAL});continue}if(value==="@"){if(opts.noextglob!==!0&&peek()==="("&&peek(2)!=="?"){push2({type:"at",extglob:!0,value,output:""});continue}push2({type:"text",value});continue}if(value!=="*"){(value==="$"||value==="^")&&(value=`\\${value}`);let match=REGEX_NON_SPECIAL_CHARS.exec(remaining());match&&(value+=match[0],state.index+=match[0].length),push2({type:"text",value});continue}if(prev&&(prev.type==="globstar"||prev.star===!0)){prev.type="star",prev.star=!0,prev.value+=value,prev.output=star,state.backtrack=!0,state.globstar=!0,consume(value);continue}let rest=remaining();if(opts.noextglob!==!0&&/^\([^?]/.test(rest)){extglobOpen("star",value);continue}if(prev.type==="star"){if(opts.noglobstar===!0){consume(value);continue}let prior=prev.prev,before=prior.prev,isStart=prior.type==="slash"||prior.type==="bos",afterStar=before&&(before.type==="star"||before.type==="globstar");if(opts.bash===!0&&(!isStart||rest[0]&&rest[0]!=="/")){push2({type:"star",value,output:""});continue}let isBrace=state.braces>0&&(prior.type==="comma"||prior.type==="brace"),isExtglob=extglobs.length&&(prior.type==="pipe"||prior.type==="paren");if(!isStart&&prior.type!=="paren"&&!isBrace&&!isExtglob){push2({type:"star",value,output:""});continue}for(;rest.slice(0,3)==="/**";){let after=input[state.index+4];if(after&&after!=="/")break;rest=rest.slice(3),consume("/**",3);}if(prior.type==="bos"&&eos()){prev.type="globstar",prev.value+=value,prev.output=globstar(opts),state.output=prev.output,state.globstar=!0,consume(value);continue}if(prior.type==="slash"&&prior.prev.type!=="bos"&&!afterStar&&eos()){state.output=state.output.slice(0,-(prior.output+prev.output).length),prior.output=`(?:${prior.output}`,prev.type="globstar",prev.output=globstar(opts)+(opts.strictSlashes?")":"|$)"),prev.value+=value,state.globstar=!0,state.output+=prior.output+prev.output,consume(value);continue}if(prior.type==="slash"&&prior.prev.type!=="bos"&&rest[0]==="/"){let end=rest[1]!==void 0?"|$":"";state.output=state.output.slice(0,-(prior.output+prev.output).length),prior.output=`(?:${prior.output}`,prev.type="globstar",prev.output=`${globstar(opts)}${SLASH_LITERAL}|${SLASH_LITERAL}${end})`,prev.value+=value,state.output+=prior.output+prev.output,state.globstar=!0,consume(value+advance3()),push2({type:"slash",value:"/",output:""});continue}if(prior.type==="bos"&&rest[0]==="/"){prev.type="globstar",prev.value+=value,prev.output=`(?:^|${SLASH_LITERAL}|${globstar(opts)}${SLASH_LITERAL})`,state.output=prev.output,state.globstar=!0,consume(value+advance3()),push2({type:"slash",value:"/",output:""});continue}state.output=state.output.slice(0,-prev.output.length),prev.type="globstar",prev.output=globstar(opts),prev.value+=value,state.output+=prev.output,state.globstar=!0,consume(value);continue}let token={type:"star",value,output:star};if(opts.bash===!0){token.output=".*?",(prev.type==="bos"||prev.type==="slash")&&(token.output=nodot+token.output),push2(token);continue}if(prev&&(prev.type==="bracket"||prev.type==="paren")&&opts.regex===!0){token.output=value,push2(token);continue}(state.index===state.start||prev.type==="slash"||prev.type==="dot")&&(prev.type==="dot"?(state.output+=NO_DOT_SLASH,prev.output+=NO_DOT_SLASH):opts.dot===!0?(state.output+=NO_DOTS_SLASH,prev.output+=NO_DOTS_SLASH):(state.output+=nodot,prev.output+=nodot),peek()!=="*"&&(state.output+=ONE_CHAR,prev.output+=ONE_CHAR)),push2(token);}for(;state.brackets>0;){if(opts.strictBrackets===!0)throw new SyntaxError(syntaxError("closing","]"));state.output=utils.escapeLast(state.output,"["),decrement("brackets");}for(;state.parens>0;){if(opts.strictBrackets===!0)throw new SyntaxError(syntaxError("closing",")"));state.output=utils.escapeLast(state.output,"("),decrement("parens");}for(;state.braces>0;){if(opts.strictBrackets===!0)throw new SyntaxError(syntaxError("closing","}"));state.output=utils.escapeLast(state.output,"{"),decrement("braces");}if(opts.strictSlashes!==!0&&(prev.type==="star"||prev.type==="bracket")&&push2({type:"maybe_slash",value:"",output:`${SLASH_LITERAL}?`}),state.backtrack===!0){state.output="";for(let token of state.tokens)state.output+=token.output!=null?token.output:token.value,token.suffix&&(state.output+=token.suffix);}return state};parse8.fastpaths=(input,options)=>{let opts={...options},max=typeof opts.maxLength=="number"?Math.min(MAX_LENGTH,opts.maxLength):MAX_LENGTH,len=input.length;if(len>max)throw new SyntaxError(`Input length: ${len}, exceeds maximum allowed length: ${max}`);input=REPLACEMENTS[input]||input;let{DOT_LITERAL,SLASH_LITERAL,ONE_CHAR,DOTS_SLASH,NO_DOT,NO_DOTS,NO_DOTS_SLASH,STAR,START_ANCHOR}=constants.globChars(opts.windows),nodot=opts.dot?NO_DOTS:NO_DOT,slashDot=opts.dot?NO_DOTS_SLASH:NO_DOT,capture=opts.capture?"":"?:",state={negated:!1,prefix:""},star=opts.bash===!0?".*?":STAR;opts.capture&&(star=`(${star})`);let globstar=opts2=>opts2.noglobstar===!0?star:`(${capture}(?:(?!${START_ANCHOR}${opts2.dot?DOTS_SLASH:DOT_LITERAL}).)*?)`,create4=str=>{switch(str){case"*":return `${nodot}${ONE_CHAR}${star}`;case".*":return `${DOT_LITERAL}${ONE_CHAR}${star}`;case"*.*":return `${nodot}${star}${DOT_LITERAL}${ONE_CHAR}${star}`;case"*/*":return `${nodot}${star}${SLASH_LITERAL}${ONE_CHAR}${slash