@storybook/addon-docs 9.0.11 → 9.0.12

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.
Files changed (2) hide show
  1. package/dist/preset.js +1 -1
  2. package/package.json +4 -4
package/dist/preset.js CHANGED
@@ -68,7 +68,7 @@ Defaulting to 2020, but this will stop working in the future.`)),options.ecmaVer
68
68
  `});++index2<nodes.length;)index2&&result.push({type:"text",value:`
69
69
  `}),result.push(nodes[index2]);return loose&&nodes.length>0&&result.push({type:"text",value:`
70
70
  `}),result}function trimMarkdownSpaceStart(value){let index2=0,code2=value.charCodeAt(index2);for(;code2===9||code2===32;)index2++,code2=value.charCodeAt(index2);return value.slice(index2)}var own9,emptyOptions7,init_state2=__esm({"../../node_modules/mdast-util-to-hast/lib/state.js"(){init_esm();init_unist_util_visit();init_unist_util_position();init_handlers2();own9={}.hasOwnProperty,emptyOptions7={};}});function toHast(tree,options){let state=createState2(tree,options),node2=state.one(tree,void 0),foot=footer(state),result=Array.isArray(node2)?{type:"root",children:node2}:node2||{type:"root",children:[]};return foot&&(result.children.push({type:"text",value:`
71
- `},foot)),result}var init_lib36=__esm({"../../node_modules/mdast-util-to-hast/lib/index.js"(){init_footer();init_state2();}});var init_mdast_util_to_hast=__esm({"../../node_modules/mdast-util-to-hast/index.js"(){init_lib36();}});function remarkRehype(destination,options){return destination&&"run"in destination?async function(tree,file){let hastTree=toHast(tree,{file,...options});await destination.run(hastTree,file);}:function(tree,file){return toHast(tree,{file,...destination||options})}}var init_lib37=__esm({"../../node_modules/remark-rehype/lib/index.js"(){init_mdast_util_to_hast();}});var init_remark_rehype=__esm({"../../node_modules/remark-rehype/index.js"(){init_lib37();}});function bail(error){if(error)throw error}var init_bail=__esm({"../../node_modules/bail/index.js"(){}});var require_extend=__commonJS({"../../node_modules/extend/index.js"(exports,module){var hasOwn2=Object.prototype.hasOwnProperty,toStr=Object.prototype.toString,defineProperty=Object.defineProperty,gOPD=Object.getOwnPropertyDescriptor,isArray4=function(arr){return typeof Array.isArray=="function"?Array.isArray(arr):toStr.call(arr)==="[object Array]"},isPlainObject2=function(obj){if(!obj||toStr.call(obj)!=="[object Object]")return !1;var hasOwnConstructor=hasOwn2.call(obj,"constructor"),hasIsPrototypeOf=obj.constructor&&obj.constructor.prototype&&hasOwn2.call(obj.constructor.prototype,"isPrototypeOf");if(obj.constructor&&!hasOwnConstructor&&!hasIsPrototypeOf)return !1;var key;for(key in obj);return typeof key>"u"||hasOwn2.call(obj,key)},setProperty=function(target,options){defineProperty&&options.name==="__proto__"?defineProperty(target,options.name,{enumerable:!0,configurable:!0,value:options.newValue,writable:!0}):target[options.name]=options.newValue;},getProperty=function(obj,name2){if(name2==="__proto__")if(hasOwn2.call(obj,name2)){if(gOPD)return gOPD(obj,name2).value}else return;return obj[name2]};module.exports=function extend4(){var options,name2,src,copy,copyIsArray,clone,target=arguments[0],i=1,length=arguments.length,deep=!1;for(typeof target=="boolean"&&(deep=target,target=arguments[1]||{},i=2),(target==null||typeof target!="object"&&typeof target!="function")&&(target={});i<length;++i)if(options=arguments[i],options!=null)for(name2 in options)src=getProperty(target,name2),copy=getProperty(options,name2),target!==copy&&(deep&&copy&&(isPlainObject2(copy)||(copyIsArray=isArray4(copy)))?(copyIsArray?(copyIsArray=!1,clone=src&&isArray4(src)?src:[]):clone=src&&isPlainObject2(src)?src:{},setProperty(target,{name:name2,newValue:extend4(deep,clone,copy)})):typeof copy<"u"&&setProperty(target,{name:name2,newValue:copy}));return target};}});function isPlainObject(value){if(typeof value!="object"||value===null)return !1;let prototype=Object.getPrototypeOf(value);return (prototype===null||prototype===Object.prototype||Object.getPrototypeOf(prototype)===null)&&!(Symbol.toStringTag in value)&&!(Symbol.iterator in value)}var init_is_plain_obj=__esm({"../../node_modules/is-plain-obj/index.js"(){}});function trough(){let fns=[],pipeline={run,use};return pipeline;function run(...values){let middlewareIndex=-1,callback=values.pop();if(typeof callback!="function")throw new TypeError("Expected function as last argument, not "+callback);next(null,...values);function next(error,...output){let fn=fns[++middlewareIndex],index2=-1;if(error){callback(error);return}for(;++index2<values.length;)(output[index2]===null||output[index2]===void 0)&&(output[index2]=values[index2]);values=output,fn?wrap2(fn,next)(...output):callback(null,...output);}}function use(middelware){if(typeof middelware!="function")throw new TypeError("Expected `middelware` to be a function, not "+middelware);return fns.push(middelware),pipeline}}function wrap2(middleware,callback){let called;return wrapped;function wrapped(...parameters){let fnExpectsCallback=middleware.length>parameters.length,result;fnExpectsCallback&&parameters.push(done);try{result=middleware.apply(this,parameters);}catch(error){let exception=error;if(fnExpectsCallback&&called)throw exception;return done(exception)}fnExpectsCallback||(result&&result.then&&typeof result.then=="function"?result.then(then,done):result instanceof Error?done(result):then(result));}function done(error,...output){called||(called=!0,callback(error,...output));}function then(value){done(null,value);}}var init_lib38=__esm({"../../node_modules/trough/lib/index.js"(){}});var init_trough=__esm({"../../node_modules/trough/index.js"(){init_lib38();}});var CallableInstance,init_callable_instance=__esm({"../../node_modules/unified/lib/callable-instance.js"(){CallableInstance=function(property){let proto=this.constructor.prototype,value=proto[property],apply=function(){return value.apply(apply,arguments)};return Object.setPrototypeOf(apply,proto),apply};}});function assertParser(name2,value){if(typeof value!="function")throw new TypeError("Cannot `"+name2+"` without `parser`")}function assertCompiler(name2,value){if(typeof value!="function")throw new TypeError("Cannot `"+name2+"` without `compiler`")}function assertUnfrozen(name2,frozen){if(frozen)throw new Error("Cannot call `"+name2+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function assertNode(node2){if(!isPlainObject(node2)||typeof node2.type!="string")throw new TypeError("Expected node, got `"+node2+"`")}function assertDone(name2,asyncName,complete){if(!complete)throw new Error("`"+name2+"` finished async. Use `"+asyncName+"` instead")}function vfile(value){return looksLikeAVFile2(value)?value:new VFile(value)}function looksLikeAVFile2(value){return !!(value&&typeof value=="object"&&"message"in value&&"messages"in value)}function looksLikeAValue(value){return typeof value=="string"||isUint8Array2(value)}function isUint8Array2(value){return !!(value&&typeof value=="object"&&"byteLength"in value&&"byteOffset"in value)}var import_extend,own10,Processor,unified,init_lib39=__esm({"../../node_modules/unified/lib/index.js"(){init_bail();import_extend=__toESM(require_extend(),1);init_is_plain_obj();init_trough();init_vfile();init_callable_instance();own10={}.hasOwnProperty,Processor=class _Processor extends CallableInstance{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=trough();}copy(){let destination=new _Processor,index2=-1;for(;++index2<this.attachers.length;){let attacher=this.attachers[index2];destination.use(...attacher);}return destination.data((0, import_extend.default)(!0,{},this.namespace)),destination}data(key,value){return typeof key=="string"?arguments.length===2?(assertUnfrozen("data",this.frozen),this.namespace[key]=value,this):own10.call(this.namespace,key)&&this.namespace[key]||void 0:key?(assertUnfrozen("data",this.frozen),this.namespace=key,this):this.namespace}freeze(){if(this.frozen)return this;let self2=this;for(;++this.freezeIndex<this.attachers.length;){let[attacher,...options]=this.attachers[this.freezeIndex];if(options[0]===!1)continue;options[0]===!0&&(options[0]=void 0);let transformer=attacher.call(self2,...options);typeof transformer=="function"&&this.transformers.use(transformer);}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(file){this.freeze();let realFile=vfile(file),parser=this.parser||this.Parser;return assertParser("parse",parser),parser(String(realFile),realFile)}process(file,done){let self2=this;return this.freeze(),assertParser("process",this.parser||this.Parser),assertCompiler("process",this.compiler||this.Compiler),done?executor(void 0,done):new Promise(executor);function executor(resolve2,reject){let realFile=vfile(file),parseTree=self2.parse(realFile);self2.run(parseTree,realFile,function(error,tree,file2){if(error||!tree||!file2)return realDone(error);let compileTree=tree,compileResult=self2.stringify(compileTree,file2);looksLikeAValue(compileResult)?file2.value=compileResult:file2.result=compileResult,realDone(error,file2);});function realDone(error,file2){error||!file2?reject(error):resolve2?resolve2(file2):done(void 0,file2);}}}processSync(file){let complete=!1,result;return this.freeze(),assertParser("processSync",this.parser||this.Parser),assertCompiler("processSync",this.compiler||this.Compiler),this.process(file,realDone),assertDone("processSync","process",complete),result;function realDone(error,file2){complete=!0,bail(error),result=file2;}}run(tree,file,done){assertNode(tree),this.freeze();let transformers=this.transformers;return !done&&typeof file=="function"&&(done=file,file=void 0),done?executor(void 0,done):new Promise(executor);function executor(resolve2,reject){let realFile=vfile(file);transformers.run(tree,realFile,realDone);function realDone(error,outputTree,file2){let resultingTree=outputTree||tree;error?reject(error):resolve2?resolve2(resultingTree):done(void 0,resultingTree,file2);}}}runSync(tree,file){let complete=!1,result;return this.run(tree,file,realDone),assertDone("runSync","run",complete),result;function realDone(error,tree2){bail(error),result=tree2,complete=!0;}}stringify(tree,file){this.freeze();let realFile=vfile(file),compiler2=this.compiler||this.Compiler;return assertCompiler("stringify",compiler2),assertNode(tree),compiler2(tree,realFile)}use(value,...parameters){let attachers=this.attachers,namespace=this.namespace;if(assertUnfrozen("use",this.frozen),value!=null)if(typeof value=="function")addPlugin(value,parameters);else if(typeof value=="object")Array.isArray(value)?addList(value):addPreset(value);else throw new TypeError("Expected usable value, not `"+value+"`");return this;function add(value2){if(typeof value2=="function")addPlugin(value2,[]);else if(typeof value2=="object")if(Array.isArray(value2)){let[plugin,...parameters2]=value2;addPlugin(plugin,parameters2);}else addPreset(value2);else throw new TypeError("Expected usable value, not `"+value2+"`")}function addPreset(result){if(!("plugins"in result)&&!("settings"in result))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");addList(result.plugins),result.settings&&(namespace.settings=(0, import_extend.default)(!0,namespace.settings,result.settings));}function addList(plugins){let index2=-1;if(plugins!=null)if(Array.isArray(plugins))for(;++index2<plugins.length;){let thing=plugins[index2];add(thing);}else throw new TypeError("Expected a list of plugins, not `"+plugins+"`")}function addPlugin(plugin,parameters2){let index2=-1,entryIndex=-1;for(;++index2<attachers.length;)if(attachers[index2][0]===plugin){entryIndex=index2;break}if(entryIndex===-1)attachers.push([plugin,...parameters2]);else if(parameters2.length>0){let[primary,...rest]=parameters2,currentPrimary=attachers[entryIndex][1];isPlainObject(currentPrimary)&&isPlainObject(primary)&&(primary=(0, import_extend.default)(!0,currentPrimary,primary)),attachers[entryIndex]=[plugin,primary,...rest];}}}},unified=new Processor().freeze();}});var init_unified=__esm({"../../node_modules/unified/index.js"(){init_lib39();}});function create3(from,to){let fields=["start","end","loc","range"],index2=-1;for(;++index2<fields.length;){let field=fields[index2];field in from&&(to[field]=from[field]);}}var init_estree_util_create=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-create.js"(){}});function specifiersToDeclarations(specifiers,init){let index2=-1,declarations=[],otherSpecifiers=[],importNamespaceSpecifier;for(;++index2<specifiers.length;){let specifier=specifiers[index2];specifier.type==="ImportNamespaceSpecifier"?importNamespaceSpecifier=specifier:otherSpecifiers.push(specifier);}if(importNamespaceSpecifier){let declarator={type:"VariableDeclarator",id:importNamespaceSpecifier.local,init};create3(importNamespaceSpecifier,declarator),declarations.push(declarator);}return declarations.push({type:"VariableDeclarator",id:{type:"ObjectPattern",properties:otherSpecifiers.map(function(specifier){let key=specifier.type==="ImportSpecifier"?specifier.imported:specifier.type==="ExportSpecifier"?specifier.exported:{type:"Identifier",name:"default"},value=specifier.local;specifier.type==="ExportSpecifier"&&(value=key,key=specifier.local),value.type;let property={type:"Property",kind:"init",shorthand:key.type==="Identifier"&&value.type==="Identifier"&&key.name===value.name,method:!1,computed:!1,key,value};return create3(specifier,property),property})},init:importNamespaceSpecifier?{type:"Identifier",name:importNamespaceSpecifier.local.name}:init}),declarations}var init_estree_util_specifiers_to_declarations=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-specifiers-to-declarations.js"(){init_estree_util_create();}});function toIdOrMemberExpression(ids){let index2=-1,object;for(;++index2<ids.length;){let name2=ids[index2],id=typeof name2=="string"&&name(name2)?{type:"Identifier",name:name2}:{type:"Literal",value:name2};object=object?{type:"MemberExpression",object,property:id,computed:id.type==="Literal",optional:!1}:id;}return object.type,object}function toJsxIdOrMemberExpression(ids){let index2=-1,object;for(;++index2<ids.length;){let name2=ids[index2];typeof name2=="string"&&name(name2,{jsx:!0});let id={type:"JSXIdentifier",name:name2};object=object?{type:"JSXMemberExpression",object,property:id}:id;}return object}var init_estree_util_to_id_or_member_expression=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-to-id-or-member-expression.js"(){init_estree_util_is_identifier_name();}});function recmaBuildJsxTransform(options){let{outputFormat}=options||{};return function(tree){if(tree.comments&&(tree.comments=tree.comments.filter(function(d){return !d.data?._mdxIsPragmaComment})),outputFormat==="function-body"){let index2=0;for(;index2<tree.body.length;){let child=tree.body[index2];if("directive"in child&&child.directive)index2++;else break}let declaration=tree.body[index2];declaration&&declaration.type==="ImportDeclaration"&&typeof declaration.source.value=="string"&&/\/jsx-(dev-)?runtime$/.test(declaration.source.value)&&(tree.body[index2]={type:"VariableDeclaration",kind:"const",declarations:specifiersToDeclarations(declaration.specifiers,toIdOrMemberExpression(["arguments",0]))});}}}var init_recma_build_jsx_transform=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/recma-build-jsx-transform.js"(){init_estree_util_specifiers_to_declarations();init_estree_util_to_id_or_member_expression();}});function createVisitors(){let scopes=[{block:!1,defined:[]}];return {enter,exit:exit2,scopes};function enter(node2){if(node2.type==="ArrowFunctionExpression"){scopes.push({block:!1,defined:[]});for(let parameter of node2.params)definePattern(parameter,!1);}else if(node2.type==="BlockStatement"||node2.type==="DoWhileStatement"||node2.type==="ForInStatement"||node2.type==="ForOfStatement"||node2.type==="ForStatement"||node2.type==="WhileStatement")scopes.push({block:!0,defined:[]});else if(node2.type==="CatchClause")scopes.push({block:!0,defined:[]}),node2.param&&definePattern(node2.param,!0);else if(node2.type==="ClassDeclaration")defineIdentifier(node2.id.name,!1);else if(node2.type==="FunctionDeclaration"){defineIdentifier(node2.id.name,!1),scopes.push({block:!1,defined:[]});for(let parameter of node2.params)definePattern(parameter,!1);}else if(node2.type==="FunctionExpression"){node2.id&&defineIdentifier(node2.id.name,!1),scopes.push({block:!1,defined:[]});for(let parameter of node2.params)definePattern(parameter,!1);}else if(node2.type==="ImportDeclaration")for(let specifier of node2.specifiers)defineIdentifier(specifier.local.name,!1);else if(node2.type==="VariableDeclaration")for(let declaration of node2.declarations)definePattern(declaration.id,node2.kind!=="var");}function exit2(node2){if(node2.type==="ArrowFunctionExpression"||node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression"){let scope=scopes.pop();scope.block;}else if(node2.type==="BlockStatement"||node2.type==="CatchClause"||node2.type==="DoWhileStatement"||node2.type==="ForInStatement"||node2.type==="ForOfStatement"||node2.type==="ForStatement"||node2.type==="WhileStatement"){let scope=scopes.pop();scope.block;}}function defineIdentifier(id,block){let index2=scopes.length,scope;for(;index2--&&(scope=scopes[index2],!(block||!scope.block)););scope.defined.push(id);}function definePattern(pattern,block){if(pattern.type==="ArrayPattern")for(let element3 of pattern.elements)element3&&definePattern(element3,block);else if(pattern.type==="AssignmentPattern")definePattern(pattern.left,block);else if(pattern.type==="Identifier")defineIdentifier(pattern.name,block);else if(pattern.type==="ObjectPattern")for(let property of pattern.properties)property.type==="Property"?definePattern(property.value,block):(property.type,definePattern(property,block));else pattern.type,definePattern(pattern.argument,block);}}var init_lib40=__esm({"../../node_modules/estree-util-scope/lib/index.js"(){}});var init_estree_util_scope=__esm({"../../node_modules/estree-util-scope/index.js"(){init_lib40();}});function declarationToExpression(declaration){return declaration.type==="FunctionDeclaration"?{...declaration,type:"FunctionExpression"}:(declaration.type,{...declaration,type:"ClassExpression"})}var init_estree_util_declaration_to_expression=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-declaration-to-expression.js"(){}});function isDeclaration(node2){return node2.type==="FunctionDeclaration"||node2.type==="ClassDeclaration"||node2.type==="VariableDeclaration"}var init_estree_util_is_declaration=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-is-declaration.js"(){}});function recmaDocument(options){let baseUrl=options.baseUrl||void 0,baseHref=typeof baseUrl=="object"?baseUrl.href:baseUrl,outputFormat=options.outputFormat||"program",pragma=options.pragma===void 0?"React.createElement":options.pragma,pragmaFrag=options.pragmaFrag===void 0?"React.Fragment":options.pragmaFrag,pragmaImportSource=options.pragmaImportSource||"react",jsxImportSource=options.jsxImportSource||"react",jsxRuntime=options.jsxRuntime||"automatic";return function(tree,file){let exportedValues=[],replacement=[],exportAllCount=0,layout,content3,child;if(jsxRuntime==="classic"&&pragmaFrag&&injectPragma(tree,"@jsxFrag",pragmaFrag),jsxRuntime==="classic"&&pragma&&injectPragma(tree,"@jsx",pragma),jsxRuntime==="automatic"&&jsxImportSource&&injectPragma(tree,"@jsxImportSource",jsxImportSource),jsxRuntime&&injectPragma(tree,"@jsxRuntime",jsxRuntime),jsxRuntime==="classic"&&pragmaImportSource){if(!pragma)throw new Error("Missing `pragma` in classic runtime with `pragmaImportSource`");handleEsm({type:"ImportDeclaration",specifiers:[{type:"ImportDefaultSpecifier",local:{type:"Identifier",name:pragma.split(".")[0]}}],source:{type:"Literal",value:pragmaImportSource}});}for(child of tree.body)if(child.type==="ExportDefaultDeclaration")layout&&file.fail("Unexpected duplicate layout, expected a single layout (previous: "+stringifyPosition(positionFromEstree(layout))+")",{ancestors:[tree,child],place:positionFromEstree(child),ruleId:"duplicate-layout",source:"recma-document"}),layout=child,replacement.push({type:"VariableDeclaration",kind:"const",declarations:[{type:"VariableDeclarator",id:{type:"Identifier",name:"MDXLayout"},init:isDeclaration(child.declaration)?declarationToExpression(child.declaration):child.declaration}]});else if(child.type==="ExportNamedDeclaration"&&child.source){let source=child.source;child.specifiers=child.specifiers.filter(function(specifier){if(specifier.exported.type==="Identifier"&&specifier.exported.name==="default"){layout&&file.fail("Unexpected duplicate layout, expected a single layout (previous: "+stringifyPosition(positionFromEstree(layout))+")",{ancestors:[tree,child,specifier],place:positionFromEstree(child),ruleId:"duplicate-layout",source:"recma-document"}),layout=specifier;let specifiers=[];if(specifier.local.type==="Identifier"&&specifier.local.name==="default")specifiers.push({type:"ImportDefaultSpecifier",local:{type:"Identifier",name:"MDXLayout"}});else {let importSpecifier={type:"ImportSpecifier",imported:specifier.local,local:{type:"Identifier",name:"MDXLayout"}};create3(specifier.local,importSpecifier),specifiers.push(importSpecifier);}let from={type:"Literal",value:source.value};create3(source,from);let declaration={type:"ImportDeclaration",specifiers,source:from};return create3(specifier,declaration),handleEsm(declaration),!1}return !0}),child.specifiers.length>0&&handleExport(child);}else child.type==="ExportNamedDeclaration"||child.type==="ExportAllDeclaration"?handleExport(child):child.type==="ImportDeclaration"?handleEsm(child):child.type==="ExpressionStatement"&&(child.expression.type==="JSXElement"||child.expression.type==="JSXFragment")?(content3=!0,replacement.push(...createMdxContent(child.expression,outputFormat,!!layout))):replacement.push(child);content3||replacement.push(...createMdxContent(void 0,outputFormat,!!layout)),exportedValues.push(["MDXContent","default"]),outputFormat==="function-body"&&replacement.push({type:"ReturnStatement",argument:{type:"ObjectExpression",properties:[...Array.from({length:exportAllCount}).map(function(_,index2){return {type:"SpreadElement",argument:{type:"Identifier",name:"_exportAll"+(index2+1)}}}),...exportedValues.map(function(d){return {type:"Property",kind:"init",method:!1,computed:!1,shorthand:typeof d=="string",key:{type:"Identifier",name:typeof d=="string"?d:d[1]},value:{type:"Identifier",name:typeof d=="string"?d:d[0]}}})]}}),tree.body=replacement;let usesImportMetaUrlVariable=!1,usesResolveDynamicHelper=!1;(baseHref||outputFormat==="function-body")&&walk2(tree,{enter(node2){if((node2.type==="ExportAllDeclaration"||node2.type==="ExportNamedDeclaration"||node2.type==="ImportDeclaration")&&node2.source){let value=node2.source.value;try{new URL(value);}catch{(value.startsWith("/")||value.startsWith("./")||value.startsWith("../"))&&(value=new URL(value,baseHref).href);}let replacement2={type:"Literal",value};create3(node2.source,replacement2),node2.source=replacement2;return}if(node2.type==="ImportExpression"){usesResolveDynamicHelper=!0;let replacement2={type:"CallExpression",callee:{type:"Identifier",name:"_resolveDynamicMdxSpecifier"},arguments:[node2.source],optional:!1};node2.source=replacement2;return}if(node2.type==="MemberExpression"&&"object"in node2&&node2.object.type==="MetaProperty"&&node2.property.type==="Identifier"&&node2.object.meta.name==="import"&&node2.object.property.name==="meta"&&node2.property.name==="url"){usesImportMetaUrlVariable=!0;let replacement2={type:"Identifier",name:"_importMetaUrl"};create3(node2,replacement2),this.replace(replacement2);}}}),usesResolveDynamicHelper&&(baseHref||(usesImportMetaUrlVariable=!0),tree.body.push(resolveDynamicMdxSpecifier(baseHref?{type:"Literal",value:baseHref}:{type:"Identifier",name:"_importMetaUrl"}))),usesImportMetaUrlVariable&&tree.body.unshift(...createImportMetaUrlVariable());function handleExport(node2){if(node2.type==="ExportNamedDeclaration"){if(node2.declaration){let visitors=createVisitors();walk2(node2,{enter(node3){visitors.enter(node3),(node3.type==="ArrowFunctionExpression"||node3.type==="FunctionDeclaration"||node3.type==="FunctionExpression")&&(this.skip(),visitors.exit(node3));},leave:visitors.exit}),exportedValues.push(...visitors.scopes[0].defined);}for(child of node2.specifiers)child.exported.type==="Identifier"?exportedValues.push(child.exported.name):(child.exported.value,exportedValues.push(child.exported.value));}handleEsm(node2);}function handleEsm(node2){let replace,init;if(outputFormat==="function-body")if(node2.type==="ImportDeclaration"||node2.type==="ExportAllDeclaration"||node2.type==="ExportNamedDeclaration"&&node2.source){node2.source;let argument={type:"ImportExpression",source:node2.source};create3(node2,argument),init={type:"AwaitExpression",argument},(node2.type==="ImportDeclaration"||node2.type==="ExportNamedDeclaration")&&node2.specifiers.length===0?replace={type:"ExpressionStatement",expression:init}:replace={type:"VariableDeclaration",kind:"const",declarations:node2.type==="ExportAllDeclaration"?[{type:"VariableDeclarator",id:{type:"Identifier",name:"_exportAll"+ ++exportAllCount},init}]:specifiersToDeclarations(node2.specifiers,init)};}else if(node2.declaration)replace=node2.declaration;else {let declarators=[];for(let specifier of node2.specifiers)specifier.exported.type==="Identifier"&&specifier.local.type==="Identifier"&&specifier.local.name!==specifier.exported.name&&declarators.push({type:"VariableDeclarator",id:specifier.exported,init:specifier.local});declarators.length>0&&(replace={type:"VariableDeclaration",kind:"const",declarations:declarators});}else replace=node2;replace&&replacement.push(replace);}};function createMdxContent(content3,outputFormat2,hasInternalLayout){let result={type:"JSXElement",openingElement:{type:"JSXOpeningElement",name:{type:"JSXIdentifier",name:"MDXLayout"},attributes:[{type:"JSXSpreadAttribute",argument:{type:"Identifier",name:"props"}}],selfClosing:!1},closingElement:{type:"JSXClosingElement",name:{type:"JSXIdentifier",name:"MDXLayout"}},children:[{type:"JSXElement",openingElement:{type:"JSXOpeningElement",name:{type:"JSXIdentifier",name:"_createMdxContent"},attributes:[{type:"JSXSpreadAttribute",argument:{type:"Identifier",name:"props"}}],selfClosing:!0},closingElement:null,children:[]}]};hasInternalLayout||(result={type:"ConditionalExpression",test:{type:"Identifier",name:"MDXLayout"},consequent:result,alternate:{type:"CallExpression",callee:{type:"Identifier",name:"_createMdxContent"},arguments:[{type:"Identifier",name:"props"}],optional:!1}});let argument=content3||{type:"Identifier",name:"undefined"};argument.type==="JSXFragment"&&argument.children.length===1&&argument.children[0].type==="JSXElement"&&(argument=argument.children[0]);let awaitExpression=!1;walk2(argument,{enter(node2){if(node2.type==="ArrowFunctionExpression"||node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression")return this.skip();(node2.type==="AwaitExpression"||node2.type==="ForOfStatement"&&node2.await)&&(awaitExpression=!0);}});let declaration={type:"FunctionDeclaration",id:{type:"Identifier",name:"MDXContent"},params:[{type:"AssignmentPattern",left:{type:"Identifier",name:"props"},right:{type:"ObjectExpression",properties:[]}}],body:{type:"BlockStatement",body:[{type:"ReturnStatement",argument:result}]}};return [{type:"FunctionDeclaration",async:awaitExpression,id:{type:"Identifier",name:"_createMdxContent"},params:[{type:"Identifier",name:"props"}],body:{type:"BlockStatement",body:[{type:"ReturnStatement",argument}]}},outputFormat2==="program"?{type:"ExportDefaultDeclaration",declaration}:declaration]}}function injectPragma(tree,name2,value){tree.comments?.unshift({type:"Block",value:name2+" "+value,data:{_mdxIsPragmaComment:!0}});}function resolveDynamicMdxSpecifier(importMetaUrl){return {type:"FunctionDeclaration",id:{type:"Identifier",name:"_resolveDynamicMdxSpecifier"},generator:!1,async:!1,params:[{type:"Identifier",name:"d"}],body:{type:"BlockStatement",body:[{type:"IfStatement",test:{type:"BinaryExpression",left:{type:"UnaryExpression",operator:"typeof",prefix:!0,argument:{type:"Identifier",name:"d"}},operator:"!==",right:{type:"Literal",value:"string"}},consequent:{type:"ReturnStatement",argument:{type:"Identifier",name:"d"}},alternate:null},{type:"TryStatement",block:{type:"BlockStatement",body:[{type:"ExpressionStatement",expression:{type:"NewExpression",callee:{type:"Identifier",name:"URL"},arguments:[{type:"Identifier",name:"d"}]}},{type:"ReturnStatement",argument:{type:"Identifier",name:"d"}}]},handler:{type:"CatchClause",param:null,body:{type:"BlockStatement",body:[]}},finalizer:null},{type:"IfStatement",test:{type:"LogicalExpression",left:{type:"LogicalExpression",left:{type:"CallExpression",callee:toIdOrMemberExpression(["d","startsWith"]),arguments:[{type:"Literal",value:"/"}],optional:!1},operator:"||",right:{type:"CallExpression",callee:toIdOrMemberExpression(["d","startsWith"]),arguments:[{type:"Literal",value:"./"}],optional:!1}},operator:"||",right:{type:"CallExpression",callee:toIdOrMemberExpression(["d","startsWith"]),arguments:[{type:"Literal",value:"../"}],optional:!1}},consequent:{type:"ReturnStatement",argument:{type:"MemberExpression",object:{type:"NewExpression",callee:{type:"Identifier",name:"URL"},arguments:[{type:"Identifier",name:"d"},importMetaUrl]},property:{type:"Identifier",name:"href"},computed:!1,optional:!1}},alternate:null},{type:"ReturnStatement",argument:{type:"Identifier",name:"d"}}]}}}function createImportMetaUrlVariable(){return [{type:"VariableDeclaration",declarations:[{type:"VariableDeclarator",id:{type:"Identifier",name:"_importMetaUrl"},init:toIdOrMemberExpression(["arguments",0,"baseUrl"])}],kind:"const"},{type:"IfStatement",test:{type:"UnaryExpression",operator:"!",prefix:!0,argument:{type:"Identifier",name:"_importMetaUrl"}},consequent:{type:"ThrowStatement",argument:{type:"NewExpression",callee:{type:"Identifier",name:"Error"},arguments:[{type:"Literal",value:"Unexpected missing `options.baseUrl` needed to support `export \u2026 from`, `import`, or `import.meta.url` when generating `function-body`"}]}},alternate:null}]}var init_recma_document=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/recma-document.js"(){init_estree_util_scope();init_src();init_unist_util_position_from_estree();init_unist_util_stringify_position();init_estree_util_create();init_estree_util_declaration_to_expression();init_estree_util_is_declaration();init_estree_util_specifiers_to_declarations();init_estree_util_to_id_or_member_expression();}});function toBinaryAddition(expressions){let index2=-1,left;for(;++index2<expressions.length;){let right=expressions[index2];left=left?{type:"BinaryExpression",left,operator:"+",right}:right;}return left}var init_estree_util_to_binary_addition=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-to-binary-addition.js"(){}});function recmaJsxRewrite(options){let{development,outputFormat,providerImportSource}=options;return function(tree,file){let visitors=createVisitors(),functionStack=[],importProvider=!1,createErrorHelper=!1;if(walk2(tree,{enter(node2){visitors.enter(node2),(node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression"||node2.type==="ArrowFunctionExpression")&&(functionStack.push({components:[],idToInvalidComponentName:new Map,node:node2,objects:[],references:{},tags:[]}),isNamedFunction(node2,"MDXContent")&&!inScope(visitors.scopes,"MDXLayout")&&functionStack[0].components.push("MDXLayout"));let functionInfo=functionStack[0];if(!(!functionInfo||!isNamedFunction(functionInfo.node,"_createMdxContent")&&!providerImportSource)&&node2.type==="JSXElement"){let name2=node2.openingElement.name;if(name2.type==="JSXMemberExpression"){let ids=[];for(;name2.type==="JSXMemberExpression";)ids.unshift(name2.property.name),name2=name2.object;ids.unshift(name2.name);let fullId=ids.join("."),id=name2.name,isInScope=inScope(visitors.scopes,id);!Object.hasOwn(functionInfo.references,fullId)&&(!isInScope||functionStack.length===1&&functionStack[0].node.type==="FunctionDeclaration"&&isNamedFunction(functionStack[0].node,"_createMdxContent"))&&(functionInfo.references[fullId]={component:!0,node:node2}),!functionInfo.objects.includes(id)&&!isInScope&&functionInfo.objects.push(id);}else if(name2.type!=="JSXNamespacedName"){if(name(name2.name)&&!/^[a-z]/.test(name2.name)){let id=name2.name;inScope(visitors.scopes,id)||(id!=="MDXLayout"&&!Object.hasOwn(functionInfo.references,id)&&(functionInfo.references[id]={component:!0,node:node2}),functionInfo.components.includes(id)||functionInfo.components.push(id));}else if(!(node2.data&&node2.data._mdxExplicitJsx)){let id=name2.name;functionInfo.tags.includes(id)||functionInfo.tags.push(id);let jsxIdExpression=["_components",id];if(name(id)===!1){let invalidComponentName=functionInfo.idToInvalidComponentName.get(id);invalidComponentName===void 0&&(invalidComponentName=`_component${functionInfo.idToInvalidComponentName.size}`,functionInfo.idToInvalidComponentName.set(id,invalidComponentName)),jsxIdExpression=[invalidComponentName];}node2.openingElement.name=toJsxIdOrMemberExpression(jsxIdExpression),node2.closingElement&&(node2.closingElement.name=toJsxIdOrMemberExpression(jsxIdExpression));}}}},leave(node2){visitors.exit(node2);let defaults=[],actual=[],parameters=[],declarations=[];if(node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression"||node2.type==="ArrowFunctionExpression"){let functionInfo=functionStack[functionStack.length-1],name2;for(name2 of functionInfo.tags.sort())defaults.push({type:"Property",kind:"init",key:name(name2)?{type:"Identifier",name:name2}:{type:"Literal",value:name2},value:{type:"Literal",value:name2},method:!1,shorthand:!1,computed:!1});actual.push(...functionInfo.components);for(name2 of functionInfo.objects)actual.includes(name2)||actual.push(name2);actual.sort();let statements=[];if(defaults.length>0||actual.length>0||functionInfo.idToInvalidComponentName.size>0){if(providerImportSource&&(importProvider=!0,parameters.push({type:"CallExpression",callee:{type:"Identifier",name:"_provideComponents"},arguments:[],optional:!1})),(isNamedFunction(functionInfo.node,"MDXContent")||isNamedFunction(functionInfo.node,"_createMdxContent"))&&parameters.push(toIdOrMemberExpression(["props","components"])),defaults.length>0||parameters.length>1)for(let parameter of parameters)defaults.push({type:"SpreadElement",argument:parameter});let componentsInit=defaults.length>0?{type:"ObjectExpression",properties:defaults}:{type:"LogicalExpression",operator:"||",left:parameters[0],right:{type:"ObjectExpression",properties:[]}},componentsPattern;if(actual.length>0&&(componentsPattern={type:"ObjectPattern",properties:actual.map(function(name3){return {type:"Property",kind:"init",key:{type:"Identifier",name:name3==="MDXLayout"?"wrapper":name3},value:{type:"Identifier",name:name3},method:!1,shorthand:name3!=="MDXLayout",computed:!1}})}),functionInfo.tags.length>0&&(declarations.push({type:"VariableDeclarator",id:{type:"Identifier",name:"_components"},init:componentsInit}),componentsInit={type:"Identifier",name:"_components"}),isNamedFunction(functionInfo.node,"_createMdxContent"))for(let[id,componentName]of [...functionInfo.idToInvalidComponentName].sort(function([a],[b]){return a.localeCompare(b)}))declarations.push({type:"VariableDeclarator",id:{type:"Identifier",name:componentName},init:{type:"MemberExpression",object:{type:"Identifier",name:"_components"},property:{type:"Literal",value:id},computed:!0,optional:!1}});componentsPattern&&declarations.push({type:"VariableDeclarator",id:componentsPattern,init:componentsInit}),declarations.length>0&&statements.push({type:"VariableDeclaration",kind:"const",declarations});}let key;for(key in functionInfo.references)if(Object.hasOwn(functionInfo.references,key)){let parts=key.split("."),index3=0;for(;++index3<parts.length;){let partial=parts.slice(0,index3).join(".");Object.hasOwn(functionInfo.references,partial)||(functionInfo.references[partial]={component:!1,node:functionInfo.references[key].node});}}let references=Object.keys(functionInfo.references).sort(),index2=-1;for(;++index2<references.length;){let id=references[index2],info=functionInfo.references[id],place=stringifyPosition(positionFromEstree(info.node)),parameters2=[{type:"Literal",value:id},{type:"Literal",value:info.component}];createErrorHelper=!0,development&&place&&parameters2.push({type:"Literal",value:place}),statements.push({type:"IfStatement",test:{type:"UnaryExpression",operator:"!",prefix:!0,argument:toIdOrMemberExpression(id.split("."))},consequent:{type:"ExpressionStatement",expression:{type:"CallExpression",callee:{type:"Identifier",name:"_missingMdxReference"},arguments:parameters2,optional:!1}},alternate:void 0});}statements.length>0&&(node2.body.type!=="BlockStatement"&&(node2.body={type:"BlockStatement",body:[{type:"ReturnStatement",argument:node2.body}]}),node2.body.body.unshift(...statements)),functionStack.pop();}}}),importProvider&&providerImportSource&&tree.body.unshift(createImportProvider(providerImportSource,outputFormat)),createErrorHelper){let message=[{type:"Literal",value:"Expected "},{type:"ConditionalExpression",test:{type:"Identifier",name:"component"},consequent:{type:"Literal",value:"component"},alternate:{type:"Literal",value:"object"}},{type:"Literal",value:" `"},{type:"Identifier",name:"id"},{type:"Literal",value:"` to be defined: you likely forgot to import, pass, or provide it."}],parameters=[{type:"Identifier",name:"id"},{type:"Identifier",name:"component"}];development&&(message.push({type:"ConditionalExpression",test:{type:"Identifier",name:"place"},consequent:toBinaryAddition([{type:"Literal",value:"\nIt\u2019s referenced in your code at `"},{type:"Identifier",name:"place"},{type:"Literal",value:(file.path?"` in `"+file.path:"")+"`"}]),alternate:{type:"Literal",value:""}}),parameters.push({type:"Identifier",name:"place"})),tree.body.push({type:"FunctionDeclaration",id:{type:"Identifier",name:"_missingMdxReference"},generator:!1,async:!1,params:parameters,body:{type:"BlockStatement",body:[{type:"ThrowStatement",argument:{type:"NewExpression",callee:{type:"Identifier",name:"Error"},arguments:[toBinaryAddition(message)]}}]}});}outputFormat==="function-body"&&tree.body.unshift({type:"ExpressionStatement",expression:{type:"Literal",value:"use strict"},directive:"use strict"});}}function createImportProvider(providerImportSource,outputFormat){let specifiers=[{type:"ImportSpecifier",imported:{type:"Identifier",name:"useMDXComponents"},local:{type:"Identifier",name:"_provideComponents"}}];return outputFormat==="function-body"?{type:"VariableDeclaration",kind:"const",declarations:specifiersToDeclarations(specifiers,toIdOrMemberExpression(["arguments",0]))}:{type:"ImportDeclaration",specifiers,source:{type:"Literal",value:providerImportSource}}}function isNamedFunction(node2,name2){return !!(node2&&"id"in node2&&node2.id&&node2.id.name===name2)}function inScope(scopes,id){let index2=scopes.length;for(;index2--;)if(scopes[index2].defined.includes(id))return !0;return !1}var init_recma_jsx_rewrite=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/recma-jsx-rewrite.js"(){init_estree_util_is_identifier_name();init_estree_util_scope();init_src();init_unist_util_stringify_position();init_unist_util_position_from_estree();init_estree_util_specifiers_to_declarations();init_estree_util_to_binary_addition();init_estree_util_to_id_or_member_expression();}});function rehypeRemoveRaw(){return function(tree){visit(tree,"raw",function(_,index2,parent){if(parent&&typeof index2=="number")return parent.children.splice(index2,1),index2});}}var init_rehype_remove_raw=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/rehype-remove-raw.js"(){init_unist_util_visit();}});function collapseWhiteSpace(value,options){options?typeof options=="string"&&(options={style:options}):options={};let replace=options.preserveLineEndings?replaceLineEnding:replaceSpace;return String(value).replace(options.style==="html"?html4:js,options.trim?trimFactory(replace):replace)}function replaceLineEnding(value){let match=/\r?\n|\r/.exec(value);return match?match[0]:" "}function replaceSpace(){return " "}function trimFactory(replace){return dropOrReplace;function dropOrReplace(value,index2,all4){return index2===0||index2+value.length===all4.length?"":replace(value)}}var js,html4,init_collapse_white_space=__esm({"../../node_modules/collapse-white-space/index.js"(){js=/\s+/g,html4=/[\t\n\v\f\r ]+/g;}});function remarkMarkAndUnravel(){return function(tree){visit(tree,function(node2,index2,parent){let offset3=-1,all4=!0,oneOrMore=!1;if(parent&&typeof index2=="number"&&node2.type==="paragraph"){let children=node2.children;for(;++offset3<children.length;){let child=children[offset3];if(child.type==="mdxJsxTextElement"||child.type==="mdxTextExpression")oneOrMore=!0;else if(!(child.type==="text"&&collapseWhiteSpace(child.value,{style:"html",trim:!0})==="")){all4=!1;break}}if(all4&&oneOrMore){offset3=-1;let newChildren=[];for(;++offset3<children.length;){let child=children[offset3];child.type==="mdxJsxTextElement"&&(child.type="mdxJsxFlowElement"),child.type==="mdxTextExpression"&&(child.type="mdxFlowExpression"),child.type==="text"&&/^[\t\r\n ]+$/.test(String(child.value))||newChildren.push(child);}return parent.children.splice(index2,1,...newChildren),index2}}if(node2.type==="mdxJsxFlowElement"||node2.type==="mdxJsxTextElement"){let data3=node2.data||(node2.data={});data3._mdxExplicitJsx=!0;}(node2.type==="mdxFlowExpression"||node2.type==="mdxTextExpression"||node2.type==="mdxjsEsm")&&node2.data&&node2.data.estree&&walk2(node2.data.estree,{enter(node3){if(node3.type==="JSXElement"){let data3=node3.data||(node3.data={});data3._mdxExplicitJsx=!0;}}});});}}var init_remark_mark_and_unravel=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/remark-mark-and-unravel.js"(){init_collapse_white_space();init_src();init_unist_util_visit();}});var nodeTypes,init_node_types=__esm({"../../node_modules/@mdx-js/mdx/lib/node-types.js"(){nodeTypes=["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"];}});function createProcessor(options){let settings=options||{},index2=-1;for(;++index2<removedOptions.length;){removedOptions[index2];}settings.format==="detect"&&void 0,(settings.jsxRuntime==="classic"||settings.pragma||settings.pragmaFrag||settings.pragmaImportSource)&&!warned&&(warned=!0,console.warn("Unexpected deprecated option `jsxRuntime: 'classic'`, `pragma`, `pragmaFrag`, or `pragmaImportSource`; see <https://mdxjs.com/migrating/v3/> on how to migrate"));let pipeline=unified().use(remarkParse);settings.format!=="md"&&pipeline.use(remarkMdx);let remarkRehypeOptions=settings.remarkRehypeOptions||{};return pipeline.use(remarkMarkAndUnravel).use(settings.remarkPlugins||[]).use(remarkRehype,{...remarkRehypeOptions,allowDangerousHtml:!0,passThrough:[...remarkRehypeOptions.passThrough||[],...nodeTypes]}).use(settings.rehypePlugins||[]),settings.format==="md"&&pipeline.use(rehypeRemoveRaw),pipeline.use(rehypeRecma,settings).use(recmaDocument,settings).use(recmaJsxRewrite,settings),settings.jsx||pipeline.use(recmaJsx,settings).use(recmaBuildJsxTransform,settings),pipeline.use(recmaJsx2).use(recmaStringify,settings).use(settings.recmaPlugins||[]),pipeline}var removedOptions,warned,init_core2=__esm({"../../node_modules/@mdx-js/mdx/lib/core.js"(){init_recma_build_jsx();init_recma_jsx();init_recma_stringify();init_rehype_recma();init_remark_mdx();init_remark_parse();init_remark_rehype();init_unified();init_recma_build_jsx_transform();init_recma_document();init_recma_jsx_rewrite();init_rehype_remove_raw();init_remark_mark_and_unravel();init_node_types();removedOptions=["compilers","filepath","hastPlugins","mdPlugins","skipExport","wrapExport"],warned=!1;}});function compile(vfileCompatible,compileOptions){let{file,options}=resolveFileAndOptions(vfileCompatible,compileOptions);return createProcessor(options).process(file)}var init_compile=__esm({"../../node_modules/@mdx-js/mdx/lib/compile.js"(){init_resolve_file_and_options();init_core2();}});var init_mdx=__esm({"../../node_modules/@mdx-js/mdx/index.js"(){init_compile();}});function getCompilerOptions(mdxCompileOptions){return {providerImportSource:"@mdx-js/react",rehypePlugins:[],...mdxCompileOptions}}var compile2,init_compiler=__esm({"src/compiler/index.ts"(){init_mdx();compile2=async(input,{mdxCompileOptions={}}={})=>{let options=getCompilerOptions(mdxCompileOptions);return (await compile(input,options)).toString()};}});var mdx_plugin_exports={};__export(mdx_plugin_exports,{mdxPlugin:()=>mdxPlugin});async function mdxPlugin(options){let filter=createFilter(/\.mdx$/),{presets}=options,mdxPluginOptions=(await presets.apply("options",{}))?.mdxPluginOptions,rehypeSlug2=(await Promise.resolve().then(()=>(init_rehype_slug(),rehype_slug_exports))).default,rehypeExternalLinks2=(await Promise.resolve().then(()=>(init_rehype_external_links(),rehype_external_links_exports))).default;return {name:"storybook:mdx-plugin",enforce:"pre",async transform(src,id){if(!filter(id))return;let mdxLoaderOptions=await presets.apply("mdxLoaderOptions",{...mdxPluginOptions,mdxCompileOptions:{providerImportSource:default2.join(default2.dirname(__require.resolve("@storybook/addon-docs/package.json")),"/dist/shims/mdx-react-shim.mjs"),...mdxPluginOptions?.mdxCompileOptions,rehypePlugins:[...mdxPluginOptions?.mdxCompileOptions?.rehypePlugins??[],rehypeSlug2,rehypeExternalLinks2]}});return {code:String(await compile2(src,mdxLoaderOptions)),map:null}}}}var init_mdx_plugin=__esm({"src/plugins/mdx-plugin.ts"(){init_es();init_compiler();}});var getResolvedReact=async options=>{let resolvedReact2=await options.presets.apply("resolvedReact",{});return {react:resolvedReact2.react??default2.dirname(__require.resolve("react/package.json")),reactDom:resolvedReact2.reactDom??default2.dirname(__require.resolve("react-dom/package.json")),mdx:resolvedReact2.mdx??default2.dirname(__require.resolve("@mdx-js/react"))}};async function webpack(webpackConfig={},options){let{module={}}=webpackConfig,{csfPluginOptions={},mdxPluginOptions={}}=options,rehypeSlug2=(await Promise.resolve().then(()=>(init_rehype_slug(),rehype_slug_exports))).default,rehypeExternalLinks2=(await Promise.resolve().then(()=>(init_rehype_external_links(),rehype_external_links_exports))).default,mdxLoaderOptions=await options.presets.apply("mdxLoaderOptions",{...mdxPluginOptions,mdxCompileOptions:{providerImportSource:default2.join(default2.dirname(__require.resolve("@storybook/addon-docs/package.json")),"/dist/shims/mdx-react-shim.mjs"),...mdxPluginOptions.mdxCompileOptions,rehypePlugins:[...mdxPluginOptions?.mdxCompileOptions?.rehypePlugins??[],rehypeSlug2,rehypeExternalLinks2]}});nodeLogger.logger.info("Addon-docs: using MDX3");let{react,reactDom,mdx}=await getResolvedReact(options),alias;return Array.isArray(webpackConfig.resolve?.alias)?(alias=[...webpackConfig.resolve?.alias],alias.push({name:"react",alias:react},{name:"react-dom",alias:reactDom},{name:"@mdx-js/react",alias:mdx})):alias={...webpackConfig.resolve?.alias,react,"react-dom":reactDom,"@mdx-js/react":mdx},{...webpackConfig,plugins:[...webpackConfig.plugins||[],...csfPluginOptions?[(await import('@storybook/csf-plugin')).webpack(csfPluginOptions)]:[]],resolve:{...webpackConfig.resolve,alias},module:{...module,rules:[...module.rules||[],{test:/\.mdx$/,exclude:/(stories|story)\.mdx$/,use:[{loader:__require.resolve("./mdx-loader"),options:mdxLoaderOptions}]}]}}}var docs=(input={},options)=>{if(options?.build?.test?.disableAutoDocs)return;let result={...input,defaultName:"Docs"},docsMode=options.docs;return docsMode&&(result.docsMode=docsMode),result},addons=[__require.resolve("@storybook/react-dom-shim/dist/preset")],viteFinal=async(config,options)=>{let{plugins=[]}=config,{mdxPlugin:mdxPlugin2}=await Promise.resolve().then(()=>(init_mdx_plugin(),mdx_plugin_exports)),{react,reactDom,mdx}=await getResolvedReact(options),themingPath=default2.dirname(__require.resolve("storybook/theming")),packageDeduplicationPlugin={name:"storybook:package-deduplication",enforce:"pre",config:()=>({resolve:{alias:{react,...default2.isAbsolute(reactDom)&&{"react-dom/server":`${reactDom}/server.browser.js`},"react-dom":reactDom,"@mdx-js/react":mdx,"storybook/theming":themingPath}}})};return plugins.unshift(packageDeduplicationPlugin),plugins.unshift(mdxPlugin2(options)),{...config,plugins}},webpackX=webpack,docsX=docs,resolvedReact=async existing=>({react:existing?.react??default2.dirname(__require.resolve("react/package.json")),reactDom:existing?.reactDom??default2.dirname(__require.resolve("react-dom/package.json")),mdx:existing?.mdx??default2.dirname(__require.resolve("@mdx-js/react"))}),optimizeViteDeps=["@mdx-js/react","@storybook/addon-docs > acorn-jsx","@storybook/addon-docs","markdown-to-jsx"];
71
+ `},foot)),result}var init_lib36=__esm({"../../node_modules/mdast-util-to-hast/lib/index.js"(){init_footer();init_state2();}});var init_mdast_util_to_hast=__esm({"../../node_modules/mdast-util-to-hast/index.js"(){init_lib36();}});function remarkRehype(destination,options){return destination&&"run"in destination?async function(tree,file){let hastTree=toHast(tree,{file,...options});await destination.run(hastTree,file);}:function(tree,file){return toHast(tree,{file,...destination||options})}}var init_lib37=__esm({"../../node_modules/remark-rehype/lib/index.js"(){init_mdast_util_to_hast();}});var init_remark_rehype=__esm({"../../node_modules/remark-rehype/index.js"(){init_lib37();}});function bail(error){if(error)throw error}var init_bail=__esm({"../../node_modules/bail/index.js"(){}});var require_extend=__commonJS({"../../node_modules/extend/index.js"(exports,module){var hasOwn2=Object.prototype.hasOwnProperty,toStr=Object.prototype.toString,defineProperty=Object.defineProperty,gOPD=Object.getOwnPropertyDescriptor,isArray4=function(arr){return typeof Array.isArray=="function"?Array.isArray(arr):toStr.call(arr)==="[object Array]"},isPlainObject2=function(obj){if(!obj||toStr.call(obj)!=="[object Object]")return !1;var hasOwnConstructor=hasOwn2.call(obj,"constructor"),hasIsPrototypeOf=obj.constructor&&obj.constructor.prototype&&hasOwn2.call(obj.constructor.prototype,"isPrototypeOf");if(obj.constructor&&!hasOwnConstructor&&!hasIsPrototypeOf)return !1;var key;for(key in obj);return typeof key>"u"||hasOwn2.call(obj,key)},setProperty=function(target,options){defineProperty&&options.name==="__proto__"?defineProperty(target,options.name,{enumerable:!0,configurable:!0,value:options.newValue,writable:!0}):target[options.name]=options.newValue;},getProperty=function(obj,name2){if(name2==="__proto__")if(hasOwn2.call(obj,name2)){if(gOPD)return gOPD(obj,name2).value}else return;return obj[name2]};module.exports=function extend4(){var options,name2,src,copy,copyIsArray,clone,target=arguments[0],i=1,length=arguments.length,deep=!1;for(typeof target=="boolean"&&(deep=target,target=arguments[1]||{},i=2),(target==null||typeof target!="object"&&typeof target!="function")&&(target={});i<length;++i)if(options=arguments[i],options!=null)for(name2 in options)src=getProperty(target,name2),copy=getProperty(options,name2),target!==copy&&(deep&&copy&&(isPlainObject2(copy)||(copyIsArray=isArray4(copy)))?(copyIsArray?(copyIsArray=!1,clone=src&&isArray4(src)?src:[]):clone=src&&isPlainObject2(src)?src:{},setProperty(target,{name:name2,newValue:extend4(deep,clone,copy)})):typeof copy<"u"&&setProperty(target,{name:name2,newValue:copy}));return target};}});function isPlainObject(value){if(typeof value!="object"||value===null)return !1;let prototype=Object.getPrototypeOf(value);return (prototype===null||prototype===Object.prototype||Object.getPrototypeOf(prototype)===null)&&!(Symbol.toStringTag in value)&&!(Symbol.iterator in value)}var init_is_plain_obj=__esm({"../../node_modules/is-plain-obj/index.js"(){}});function trough(){let fns=[],pipeline={run,use};return pipeline;function run(...values){let middlewareIndex=-1,callback=values.pop();if(typeof callback!="function")throw new TypeError("Expected function as last argument, not "+callback);next(null,...values);function next(error,...output){let fn=fns[++middlewareIndex],index2=-1;if(error){callback(error);return}for(;++index2<values.length;)(output[index2]===null||output[index2]===void 0)&&(output[index2]=values[index2]);values=output,fn?wrap2(fn,next)(...output):callback(null,...output);}}function use(middelware){if(typeof middelware!="function")throw new TypeError("Expected `middelware` to be a function, not "+middelware);return fns.push(middelware),pipeline}}function wrap2(middleware,callback){let called;return wrapped;function wrapped(...parameters){let fnExpectsCallback=middleware.length>parameters.length,result;fnExpectsCallback&&parameters.push(done);try{result=middleware.apply(this,parameters);}catch(error){let exception=error;if(fnExpectsCallback&&called)throw exception;return done(exception)}fnExpectsCallback||(result&&result.then&&typeof result.then=="function"?result.then(then,done):result instanceof Error?done(result):then(result));}function done(error,...output){called||(called=!0,callback(error,...output));}function then(value){done(null,value);}}var init_lib38=__esm({"../../node_modules/trough/lib/index.js"(){}});var init_trough=__esm({"../../node_modules/trough/index.js"(){init_lib38();}});var CallableInstance,init_callable_instance=__esm({"../../node_modules/unified/lib/callable-instance.js"(){CallableInstance=function(property){let proto=this.constructor.prototype,value=proto[property],apply=function(){return value.apply(apply,arguments)};return Object.setPrototypeOf(apply,proto),apply};}});function assertParser(name2,value){if(typeof value!="function")throw new TypeError("Cannot `"+name2+"` without `parser`")}function assertCompiler(name2,value){if(typeof value!="function")throw new TypeError("Cannot `"+name2+"` without `compiler`")}function assertUnfrozen(name2,frozen){if(frozen)throw new Error("Cannot call `"+name2+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function assertNode(node2){if(!isPlainObject(node2)||typeof node2.type!="string")throw new TypeError("Expected node, got `"+node2+"`")}function assertDone(name2,asyncName,complete){if(!complete)throw new Error("`"+name2+"` finished async. Use `"+asyncName+"` instead")}function vfile(value){return looksLikeAVFile2(value)?value:new VFile(value)}function looksLikeAVFile2(value){return !!(value&&typeof value=="object"&&"message"in value&&"messages"in value)}function looksLikeAValue(value){return typeof value=="string"||isUint8Array2(value)}function isUint8Array2(value){return !!(value&&typeof value=="object"&&"byteLength"in value&&"byteOffset"in value)}var import_extend,own10,Processor,unified,init_lib39=__esm({"../../node_modules/unified/lib/index.js"(){init_bail();import_extend=__toESM(require_extend(),1);init_is_plain_obj();init_trough();init_vfile();init_callable_instance();own10={}.hasOwnProperty,Processor=class _Processor extends CallableInstance{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=trough();}copy(){let destination=new _Processor,index2=-1;for(;++index2<this.attachers.length;){let attacher=this.attachers[index2];destination.use(...attacher);}return destination.data((0, import_extend.default)(!0,{},this.namespace)),destination}data(key,value){return typeof key=="string"?arguments.length===2?(assertUnfrozen("data",this.frozen),this.namespace[key]=value,this):own10.call(this.namespace,key)&&this.namespace[key]||void 0:key?(assertUnfrozen("data",this.frozen),this.namespace=key,this):this.namespace}freeze(){if(this.frozen)return this;let self2=this;for(;++this.freezeIndex<this.attachers.length;){let[attacher,...options]=this.attachers[this.freezeIndex];if(options[0]===!1)continue;options[0]===!0&&(options[0]=void 0);let transformer=attacher.call(self2,...options);typeof transformer=="function"&&this.transformers.use(transformer);}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(file){this.freeze();let realFile=vfile(file),parser=this.parser||this.Parser;return assertParser("parse",parser),parser(String(realFile),realFile)}process(file,done){let self2=this;return this.freeze(),assertParser("process",this.parser||this.Parser),assertCompiler("process",this.compiler||this.Compiler),done?executor(void 0,done):new Promise(executor);function executor(resolve2,reject){let realFile=vfile(file),parseTree=self2.parse(realFile);self2.run(parseTree,realFile,function(error,tree,file2){if(error||!tree||!file2)return realDone(error);let compileTree=tree,compileResult=self2.stringify(compileTree,file2);looksLikeAValue(compileResult)?file2.value=compileResult:file2.result=compileResult,realDone(error,file2);});function realDone(error,file2){error||!file2?reject(error):resolve2?resolve2(file2):done(void 0,file2);}}}processSync(file){let complete=!1,result;return this.freeze(),assertParser("processSync",this.parser||this.Parser),assertCompiler("processSync",this.compiler||this.Compiler),this.process(file,realDone),assertDone("processSync","process",complete),result;function realDone(error,file2){complete=!0,bail(error),result=file2;}}run(tree,file,done){assertNode(tree),this.freeze();let transformers=this.transformers;return !done&&typeof file=="function"&&(done=file,file=void 0),done?executor(void 0,done):new Promise(executor);function executor(resolve2,reject){let realFile=vfile(file);transformers.run(tree,realFile,realDone);function realDone(error,outputTree,file2){let resultingTree=outputTree||tree;error?reject(error):resolve2?resolve2(resultingTree):done(void 0,resultingTree,file2);}}}runSync(tree,file){let complete=!1,result;return this.run(tree,file,realDone),assertDone("runSync","run",complete),result;function realDone(error,tree2){bail(error),result=tree2,complete=!0;}}stringify(tree,file){this.freeze();let realFile=vfile(file),compiler2=this.compiler||this.Compiler;return assertCompiler("stringify",compiler2),assertNode(tree),compiler2(tree,realFile)}use(value,...parameters){let attachers=this.attachers,namespace=this.namespace;if(assertUnfrozen("use",this.frozen),value!=null)if(typeof value=="function")addPlugin(value,parameters);else if(typeof value=="object")Array.isArray(value)?addList(value):addPreset(value);else throw new TypeError("Expected usable value, not `"+value+"`");return this;function add(value2){if(typeof value2=="function")addPlugin(value2,[]);else if(typeof value2=="object")if(Array.isArray(value2)){let[plugin,...parameters2]=value2;addPlugin(plugin,parameters2);}else addPreset(value2);else throw new TypeError("Expected usable value, not `"+value2+"`")}function addPreset(result){if(!("plugins"in result)&&!("settings"in result))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");addList(result.plugins),result.settings&&(namespace.settings=(0, import_extend.default)(!0,namespace.settings,result.settings));}function addList(plugins){let index2=-1;if(plugins!=null)if(Array.isArray(plugins))for(;++index2<plugins.length;){let thing=plugins[index2];add(thing);}else throw new TypeError("Expected a list of plugins, not `"+plugins+"`")}function addPlugin(plugin,parameters2){let index2=-1,entryIndex=-1;for(;++index2<attachers.length;)if(attachers[index2][0]===plugin){entryIndex=index2;break}if(entryIndex===-1)attachers.push([plugin,...parameters2]);else if(parameters2.length>0){let[primary,...rest]=parameters2,currentPrimary=attachers[entryIndex][1];isPlainObject(currentPrimary)&&isPlainObject(primary)&&(primary=(0, import_extend.default)(!0,currentPrimary,primary)),attachers[entryIndex]=[plugin,primary,...rest];}}}},unified=new Processor().freeze();}});var init_unified=__esm({"../../node_modules/unified/index.js"(){init_lib39();}});function create3(from,to){let fields=["start","end","loc","range"],index2=-1;for(;++index2<fields.length;){let field=fields[index2];field in from&&(to[field]=from[field]);}}var init_estree_util_create=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-create.js"(){}});function specifiersToDeclarations(specifiers,init){let index2=-1,declarations=[],otherSpecifiers=[],importNamespaceSpecifier;for(;++index2<specifiers.length;){let specifier=specifiers[index2];specifier.type==="ImportNamespaceSpecifier"?importNamespaceSpecifier=specifier:otherSpecifiers.push(specifier);}if(importNamespaceSpecifier){let declarator={type:"VariableDeclarator",id:importNamespaceSpecifier.local,init};create3(importNamespaceSpecifier,declarator),declarations.push(declarator);}return declarations.push({type:"VariableDeclarator",id:{type:"ObjectPattern",properties:otherSpecifiers.map(function(specifier){let key=specifier.type==="ImportSpecifier"?specifier.imported:specifier.type==="ExportSpecifier"?specifier.exported:{type:"Identifier",name:"default"},value=specifier.local;specifier.type==="ExportSpecifier"&&(value=key,key=specifier.local),value.type;let property={type:"Property",kind:"init",shorthand:key.type==="Identifier"&&value.type==="Identifier"&&key.name===value.name,method:!1,computed:!1,key,value};return create3(specifier,property),property})},init:importNamespaceSpecifier?{type:"Identifier",name:importNamespaceSpecifier.local.name}:init}),declarations}var init_estree_util_specifiers_to_declarations=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-specifiers-to-declarations.js"(){init_estree_util_create();}});function toIdOrMemberExpression(ids){let index2=-1,object;for(;++index2<ids.length;){let name2=ids[index2],id=typeof name2=="string"&&name(name2)?{type:"Identifier",name:name2}:{type:"Literal",value:name2};object=object?{type:"MemberExpression",object,property:id,computed:id.type==="Literal",optional:!1}:id;}return object.type,object}function toJsxIdOrMemberExpression(ids){let index2=-1,object;for(;++index2<ids.length;){let name2=ids[index2];typeof name2=="string"&&name(name2,{jsx:!0});let id={type:"JSXIdentifier",name:name2};object=object?{type:"JSXMemberExpression",object,property:id}:id;}return object}var init_estree_util_to_id_or_member_expression=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-to-id-or-member-expression.js"(){init_estree_util_is_identifier_name();}});function recmaBuildJsxTransform(options){let{outputFormat}=options||{};return function(tree){if(tree.comments&&(tree.comments=tree.comments.filter(function(d){return !d.data?._mdxIsPragmaComment})),outputFormat==="function-body"){let index2=0;for(;index2<tree.body.length;){let child=tree.body[index2];if("directive"in child&&child.directive)index2++;else break}let declaration=tree.body[index2];declaration&&declaration.type==="ImportDeclaration"&&typeof declaration.source.value=="string"&&/\/jsx-(dev-)?runtime$/.test(declaration.source.value)&&(tree.body[index2]={type:"VariableDeclaration",kind:"const",declarations:specifiersToDeclarations(declaration.specifiers,toIdOrMemberExpression(["arguments",0]))});}}}var init_recma_build_jsx_transform=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/recma-build-jsx-transform.js"(){init_estree_util_specifiers_to_declarations();init_estree_util_to_id_or_member_expression();}});function createVisitors(){let scopes=[{block:!1,defined:[]}];return {enter,exit:exit2,scopes};function enter(node2){if(node2.type==="ArrowFunctionExpression"){scopes.push({block:!1,defined:[]});for(let parameter of node2.params)definePattern(parameter,!1);}else if(node2.type==="BlockStatement"||node2.type==="DoWhileStatement"||node2.type==="ForInStatement"||node2.type==="ForOfStatement"||node2.type==="ForStatement"||node2.type==="WhileStatement")scopes.push({block:!0,defined:[]});else if(node2.type==="CatchClause")scopes.push({block:!0,defined:[]}),node2.param&&definePattern(node2.param,!0);else if(node2.type==="ClassDeclaration")defineIdentifier(node2.id.name,!1);else if(node2.type==="FunctionDeclaration"){defineIdentifier(node2.id.name,!1),scopes.push({block:!1,defined:[]});for(let parameter of node2.params)definePattern(parameter,!1);}else if(node2.type==="FunctionExpression"){node2.id&&defineIdentifier(node2.id.name,!1),scopes.push({block:!1,defined:[]});for(let parameter of node2.params)definePattern(parameter,!1);}else if(node2.type==="ImportDeclaration")for(let specifier of node2.specifiers)defineIdentifier(specifier.local.name,!1);else if(node2.type==="VariableDeclaration")for(let declaration of node2.declarations)definePattern(declaration.id,node2.kind!=="var");}function exit2(node2){if(node2.type==="ArrowFunctionExpression"||node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression"){let scope=scopes.pop();scope.block;}else if(node2.type==="BlockStatement"||node2.type==="CatchClause"||node2.type==="DoWhileStatement"||node2.type==="ForInStatement"||node2.type==="ForOfStatement"||node2.type==="ForStatement"||node2.type==="WhileStatement"){let scope=scopes.pop();scope.block;}}function defineIdentifier(id,block){let index2=scopes.length,scope;for(;index2--&&(scope=scopes[index2],!(block||!scope.block)););scope.defined.push(id);}function definePattern(pattern,block){if(pattern.type==="ArrayPattern")for(let element3 of pattern.elements)element3&&definePattern(element3,block);else if(pattern.type==="AssignmentPattern")definePattern(pattern.left,block);else if(pattern.type==="Identifier")defineIdentifier(pattern.name,block);else if(pattern.type==="ObjectPattern")for(let property of pattern.properties)property.type==="Property"?definePattern(property.value,block):(property.type,definePattern(property,block));else pattern.type,definePattern(pattern.argument,block);}}var init_lib40=__esm({"../../node_modules/estree-util-scope/lib/index.js"(){}});var init_estree_util_scope=__esm({"../../node_modules/estree-util-scope/index.js"(){init_lib40();}});function declarationToExpression(declaration){return declaration.type==="FunctionDeclaration"?{...declaration,type:"FunctionExpression"}:(declaration.type,{...declaration,type:"ClassExpression"})}var init_estree_util_declaration_to_expression=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-declaration-to-expression.js"(){}});function isDeclaration(node2){return node2.type==="FunctionDeclaration"||node2.type==="ClassDeclaration"||node2.type==="VariableDeclaration"}var init_estree_util_is_declaration=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-is-declaration.js"(){}});function recmaDocument(options){let baseUrl=options.baseUrl||void 0,baseHref=typeof baseUrl=="object"?baseUrl.href:baseUrl,outputFormat=options.outputFormat||"program",pragma=options.pragma===void 0?"React.createElement":options.pragma,pragmaFrag=options.pragmaFrag===void 0?"React.Fragment":options.pragmaFrag,pragmaImportSource=options.pragmaImportSource||"react",jsxImportSource=options.jsxImportSource||"react",jsxRuntime=options.jsxRuntime||"automatic";return function(tree,file){let exportedValues=[],replacement=[],exportAllCount=0,layout,content3,child;if(jsxRuntime==="classic"&&pragmaFrag&&injectPragma(tree,"@jsxFrag",pragmaFrag),jsxRuntime==="classic"&&pragma&&injectPragma(tree,"@jsx",pragma),jsxRuntime==="automatic"&&jsxImportSource&&injectPragma(tree,"@jsxImportSource",jsxImportSource),jsxRuntime&&injectPragma(tree,"@jsxRuntime",jsxRuntime),jsxRuntime==="classic"&&pragmaImportSource){if(!pragma)throw new Error("Missing `pragma` in classic runtime with `pragmaImportSource`");handleEsm({type:"ImportDeclaration",specifiers:[{type:"ImportDefaultSpecifier",local:{type:"Identifier",name:pragma.split(".")[0]}}],source:{type:"Literal",value:pragmaImportSource}});}for(child of tree.body)if(child.type==="ExportDefaultDeclaration")layout&&file.fail("Unexpected duplicate layout, expected a single layout (previous: "+stringifyPosition(positionFromEstree(layout))+")",{ancestors:[tree,child],place:positionFromEstree(child),ruleId:"duplicate-layout",source:"recma-document"}),layout=child,replacement.push({type:"VariableDeclaration",kind:"const",declarations:[{type:"VariableDeclarator",id:{type:"Identifier",name:"MDXLayout"},init:isDeclaration(child.declaration)?declarationToExpression(child.declaration):child.declaration}]});else if(child.type==="ExportNamedDeclaration"&&child.source){let source=child.source;child.specifiers=child.specifiers.filter(function(specifier){if(specifier.exported.type==="Identifier"&&specifier.exported.name==="default"){layout&&file.fail("Unexpected duplicate layout, expected a single layout (previous: "+stringifyPosition(positionFromEstree(layout))+")",{ancestors:[tree,child,specifier],place:positionFromEstree(child),ruleId:"duplicate-layout",source:"recma-document"}),layout=specifier;let specifiers=[];if(specifier.local.type==="Identifier"&&specifier.local.name==="default")specifiers.push({type:"ImportDefaultSpecifier",local:{type:"Identifier",name:"MDXLayout"}});else {let importSpecifier={type:"ImportSpecifier",imported:specifier.local,local:{type:"Identifier",name:"MDXLayout"}};create3(specifier.local,importSpecifier),specifiers.push(importSpecifier);}let from={type:"Literal",value:source.value};create3(source,from);let declaration={type:"ImportDeclaration",specifiers,source:from};return create3(specifier,declaration),handleEsm(declaration),!1}return !0}),child.specifiers.length>0&&handleExport(child);}else child.type==="ExportNamedDeclaration"||child.type==="ExportAllDeclaration"?handleExport(child):child.type==="ImportDeclaration"?handleEsm(child):child.type==="ExpressionStatement"&&(child.expression.type==="JSXElement"||child.expression.type==="JSXFragment")?(content3=!0,replacement.push(...createMdxContent(child.expression,outputFormat,!!layout))):replacement.push(child);content3||replacement.push(...createMdxContent(void 0,outputFormat,!!layout)),exportedValues.push(["MDXContent","default"]),outputFormat==="function-body"&&replacement.push({type:"ReturnStatement",argument:{type:"ObjectExpression",properties:[...Array.from({length:exportAllCount}).map(function(_,index2){return {type:"SpreadElement",argument:{type:"Identifier",name:"_exportAll"+(index2+1)}}}),...exportedValues.map(function(d){return {type:"Property",kind:"init",method:!1,computed:!1,shorthand:typeof d=="string",key:{type:"Identifier",name:typeof d=="string"?d:d[1]},value:{type:"Identifier",name:typeof d=="string"?d:d[0]}}})]}}),tree.body=replacement;let usesImportMetaUrlVariable=!1,usesResolveDynamicHelper=!1;(baseHref||outputFormat==="function-body")&&walk2(tree,{enter(node2){if((node2.type==="ExportAllDeclaration"||node2.type==="ExportNamedDeclaration"||node2.type==="ImportDeclaration")&&node2.source){let value=node2.source.value;try{new URL(value);}catch{(value.startsWith("/")||value.startsWith("./")||value.startsWith("../"))&&(value=new URL(value,baseHref).href);}let replacement2={type:"Literal",value};create3(node2.source,replacement2),node2.source=replacement2;return}if(node2.type==="ImportExpression"){usesResolveDynamicHelper=!0;let replacement2={type:"CallExpression",callee:{type:"Identifier",name:"_resolveDynamicMdxSpecifier"},arguments:[node2.source],optional:!1};node2.source=replacement2;return}if(node2.type==="MemberExpression"&&"object"in node2&&node2.object.type==="MetaProperty"&&node2.property.type==="Identifier"&&node2.object.meta.name==="import"&&node2.object.property.name==="meta"&&node2.property.name==="url"){usesImportMetaUrlVariable=!0;let replacement2={type:"Identifier",name:"_importMetaUrl"};create3(node2,replacement2),this.replace(replacement2);}}}),usesResolveDynamicHelper&&(baseHref||(usesImportMetaUrlVariable=!0),tree.body.push(resolveDynamicMdxSpecifier(baseHref?{type:"Literal",value:baseHref}:{type:"Identifier",name:"_importMetaUrl"}))),usesImportMetaUrlVariable&&tree.body.unshift(...createImportMetaUrlVariable());function handleExport(node2){if(node2.type==="ExportNamedDeclaration"){if(node2.declaration){let visitors=createVisitors();walk2(node2,{enter(node3){visitors.enter(node3),(node3.type==="ArrowFunctionExpression"||node3.type==="FunctionDeclaration"||node3.type==="FunctionExpression")&&(this.skip(),visitors.exit(node3));},leave:visitors.exit}),exportedValues.push(...visitors.scopes[0].defined);}for(child of node2.specifiers)child.exported.type==="Identifier"?exportedValues.push(child.exported.name):(child.exported.value,exportedValues.push(child.exported.value));}handleEsm(node2);}function handleEsm(node2){let replace,init;if(outputFormat==="function-body")if(node2.type==="ImportDeclaration"||node2.type==="ExportAllDeclaration"||node2.type==="ExportNamedDeclaration"&&node2.source){node2.source;let argument={type:"ImportExpression",source:node2.source};create3(node2,argument),init={type:"AwaitExpression",argument},(node2.type==="ImportDeclaration"||node2.type==="ExportNamedDeclaration")&&node2.specifiers.length===0?replace={type:"ExpressionStatement",expression:init}:replace={type:"VariableDeclaration",kind:"const",declarations:node2.type==="ExportAllDeclaration"?[{type:"VariableDeclarator",id:{type:"Identifier",name:"_exportAll"+ ++exportAllCount},init}]:specifiersToDeclarations(node2.specifiers,init)};}else if(node2.declaration)replace=node2.declaration;else {let declarators=[];for(let specifier of node2.specifiers)specifier.exported.type==="Identifier"&&specifier.local.type==="Identifier"&&specifier.local.name!==specifier.exported.name&&declarators.push({type:"VariableDeclarator",id:specifier.exported,init:specifier.local});declarators.length>0&&(replace={type:"VariableDeclaration",kind:"const",declarations:declarators});}else replace=node2;replace&&replacement.push(replace);}};function createMdxContent(content3,outputFormat2,hasInternalLayout){let result={type:"JSXElement",openingElement:{type:"JSXOpeningElement",name:{type:"JSXIdentifier",name:"MDXLayout"},attributes:[{type:"JSXSpreadAttribute",argument:{type:"Identifier",name:"props"}}],selfClosing:!1},closingElement:{type:"JSXClosingElement",name:{type:"JSXIdentifier",name:"MDXLayout"}},children:[{type:"JSXElement",openingElement:{type:"JSXOpeningElement",name:{type:"JSXIdentifier",name:"_createMdxContent"},attributes:[{type:"JSXSpreadAttribute",argument:{type:"Identifier",name:"props"}}],selfClosing:!0},closingElement:null,children:[]}]};hasInternalLayout||(result={type:"ConditionalExpression",test:{type:"Identifier",name:"MDXLayout"},consequent:result,alternate:{type:"CallExpression",callee:{type:"Identifier",name:"_createMdxContent"},arguments:[{type:"Identifier",name:"props"}],optional:!1}});let argument=content3||{type:"Identifier",name:"undefined"};argument.type==="JSXFragment"&&argument.children.length===1&&argument.children[0].type==="JSXElement"&&(argument=argument.children[0]);let awaitExpression=!1;walk2(argument,{enter(node2){if(node2.type==="ArrowFunctionExpression"||node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression")return this.skip();(node2.type==="AwaitExpression"||node2.type==="ForOfStatement"&&node2.await)&&(awaitExpression=!0);}});let declaration={type:"FunctionDeclaration",id:{type:"Identifier",name:"MDXContent"},params:[{type:"AssignmentPattern",left:{type:"Identifier",name:"props"},right:{type:"ObjectExpression",properties:[]}}],body:{type:"BlockStatement",body:[{type:"ReturnStatement",argument:result}]}};return [{type:"FunctionDeclaration",async:awaitExpression,id:{type:"Identifier",name:"_createMdxContent"},params:[{type:"Identifier",name:"props"}],body:{type:"BlockStatement",body:[{type:"ReturnStatement",argument}]}},outputFormat2==="program"?{type:"ExportDefaultDeclaration",declaration}:declaration]}}function injectPragma(tree,name2,value){tree.comments?.unshift({type:"Block",value:name2+" "+value,data:{_mdxIsPragmaComment:!0}});}function resolveDynamicMdxSpecifier(importMetaUrl){return {type:"FunctionDeclaration",id:{type:"Identifier",name:"_resolveDynamicMdxSpecifier"},generator:!1,async:!1,params:[{type:"Identifier",name:"d"}],body:{type:"BlockStatement",body:[{type:"IfStatement",test:{type:"BinaryExpression",left:{type:"UnaryExpression",operator:"typeof",prefix:!0,argument:{type:"Identifier",name:"d"}},operator:"!==",right:{type:"Literal",value:"string"}},consequent:{type:"ReturnStatement",argument:{type:"Identifier",name:"d"}},alternate:null},{type:"TryStatement",block:{type:"BlockStatement",body:[{type:"ExpressionStatement",expression:{type:"NewExpression",callee:{type:"Identifier",name:"URL"},arguments:[{type:"Identifier",name:"d"}]}},{type:"ReturnStatement",argument:{type:"Identifier",name:"d"}}]},handler:{type:"CatchClause",param:null,body:{type:"BlockStatement",body:[]}},finalizer:null},{type:"IfStatement",test:{type:"LogicalExpression",left:{type:"LogicalExpression",left:{type:"CallExpression",callee:toIdOrMemberExpression(["d","startsWith"]),arguments:[{type:"Literal",value:"/"}],optional:!1},operator:"||",right:{type:"CallExpression",callee:toIdOrMemberExpression(["d","startsWith"]),arguments:[{type:"Literal",value:"./"}],optional:!1}},operator:"||",right:{type:"CallExpression",callee:toIdOrMemberExpression(["d","startsWith"]),arguments:[{type:"Literal",value:"../"}],optional:!1}},consequent:{type:"ReturnStatement",argument:{type:"MemberExpression",object:{type:"NewExpression",callee:{type:"Identifier",name:"URL"},arguments:[{type:"Identifier",name:"d"},importMetaUrl]},property:{type:"Identifier",name:"href"},computed:!1,optional:!1}},alternate:null},{type:"ReturnStatement",argument:{type:"Identifier",name:"d"}}]}}}function createImportMetaUrlVariable(){return [{type:"VariableDeclaration",declarations:[{type:"VariableDeclarator",id:{type:"Identifier",name:"_importMetaUrl"},init:toIdOrMemberExpression(["arguments",0,"baseUrl"])}],kind:"const"},{type:"IfStatement",test:{type:"UnaryExpression",operator:"!",prefix:!0,argument:{type:"Identifier",name:"_importMetaUrl"}},consequent:{type:"ThrowStatement",argument:{type:"NewExpression",callee:{type:"Identifier",name:"Error"},arguments:[{type:"Literal",value:"Unexpected missing `options.baseUrl` needed to support `export \u2026 from`, `import`, or `import.meta.url` when generating `function-body`"}]}},alternate:null}]}var init_recma_document=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/recma-document.js"(){init_estree_util_scope();init_src();init_unist_util_position_from_estree();init_unist_util_stringify_position();init_estree_util_create();init_estree_util_declaration_to_expression();init_estree_util_is_declaration();init_estree_util_specifiers_to_declarations();init_estree_util_to_id_or_member_expression();}});function toBinaryAddition(expressions){let index2=-1,left;for(;++index2<expressions.length;){let right=expressions[index2];left=left?{type:"BinaryExpression",left,operator:"+",right}:right;}return left}var init_estree_util_to_binary_addition=__esm({"../../node_modules/@mdx-js/mdx/lib/util/estree-util-to-binary-addition.js"(){}});function recmaJsxRewrite(options){let{development,outputFormat,providerImportSource}=options;return function(tree,file){let visitors=createVisitors(),functionStack=[],importProvider=!1,createErrorHelper=!1;if(walk2(tree,{enter(node2){visitors.enter(node2),(node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression"||node2.type==="ArrowFunctionExpression")&&(functionStack.push({components:[],idToInvalidComponentName:new Map,node:node2,objects:[],references:{},tags:[]}),isNamedFunction(node2,"MDXContent")&&!inScope(visitors.scopes,"MDXLayout")&&functionStack[0].components.push("MDXLayout"));let functionInfo=functionStack[0];if(!(!functionInfo||!isNamedFunction(functionInfo.node,"_createMdxContent")&&!providerImportSource)&&node2.type==="JSXElement"){let name2=node2.openingElement.name;if(name2.type==="JSXMemberExpression"){let ids=[];for(;name2.type==="JSXMemberExpression";)ids.unshift(name2.property.name),name2=name2.object;ids.unshift(name2.name);let fullId=ids.join("."),id=name2.name,isInScope=inScope(visitors.scopes,id);!Object.hasOwn(functionInfo.references,fullId)&&(!isInScope||functionStack.length===1&&functionStack[0].node.type==="FunctionDeclaration"&&isNamedFunction(functionStack[0].node,"_createMdxContent"))&&(functionInfo.references[fullId]={component:!0,node:node2}),!functionInfo.objects.includes(id)&&!isInScope&&functionInfo.objects.push(id);}else if(name2.type!=="JSXNamespacedName"){if(name(name2.name)&&!/^[a-z]/.test(name2.name)){let id=name2.name;inScope(visitors.scopes,id)||(id!=="MDXLayout"&&!Object.hasOwn(functionInfo.references,id)&&(functionInfo.references[id]={component:!0,node:node2}),functionInfo.components.includes(id)||functionInfo.components.push(id));}else if(!(node2.data&&node2.data._mdxExplicitJsx)){let id=name2.name;functionInfo.tags.includes(id)||functionInfo.tags.push(id);let jsxIdExpression=["_components",id];if(name(id)===!1){let invalidComponentName=functionInfo.idToInvalidComponentName.get(id);invalidComponentName===void 0&&(invalidComponentName=`_component${functionInfo.idToInvalidComponentName.size}`,functionInfo.idToInvalidComponentName.set(id,invalidComponentName)),jsxIdExpression=[invalidComponentName];}node2.openingElement.name=toJsxIdOrMemberExpression(jsxIdExpression),node2.closingElement&&(node2.closingElement.name=toJsxIdOrMemberExpression(jsxIdExpression));}}}},leave(node2){visitors.exit(node2);let defaults=[],actual=[],parameters=[],declarations=[];if(node2.type==="FunctionDeclaration"||node2.type==="FunctionExpression"||node2.type==="ArrowFunctionExpression"){let functionInfo=functionStack[functionStack.length-1],name2;for(name2 of functionInfo.tags.sort())defaults.push({type:"Property",kind:"init",key:name(name2)?{type:"Identifier",name:name2}:{type:"Literal",value:name2},value:{type:"Literal",value:name2},method:!1,shorthand:!1,computed:!1});actual.push(...functionInfo.components);for(name2 of functionInfo.objects)actual.includes(name2)||actual.push(name2);actual.sort();let statements=[];if(defaults.length>0||actual.length>0||functionInfo.idToInvalidComponentName.size>0){if(providerImportSource&&(importProvider=!0,parameters.push({type:"CallExpression",callee:{type:"Identifier",name:"_provideComponents"},arguments:[],optional:!1})),(isNamedFunction(functionInfo.node,"MDXContent")||isNamedFunction(functionInfo.node,"_createMdxContent"))&&parameters.push(toIdOrMemberExpression(["props","components"])),defaults.length>0||parameters.length>1)for(let parameter of parameters)defaults.push({type:"SpreadElement",argument:parameter});let componentsInit=defaults.length>0?{type:"ObjectExpression",properties:defaults}:{type:"LogicalExpression",operator:"||",left:parameters[0],right:{type:"ObjectExpression",properties:[]}},componentsPattern;if(actual.length>0&&(componentsPattern={type:"ObjectPattern",properties:actual.map(function(name3){return {type:"Property",kind:"init",key:{type:"Identifier",name:name3==="MDXLayout"?"wrapper":name3},value:{type:"Identifier",name:name3},method:!1,shorthand:name3!=="MDXLayout",computed:!1}})}),functionInfo.tags.length>0&&(declarations.push({type:"VariableDeclarator",id:{type:"Identifier",name:"_components"},init:componentsInit}),componentsInit={type:"Identifier",name:"_components"}),isNamedFunction(functionInfo.node,"_createMdxContent"))for(let[id,componentName]of [...functionInfo.idToInvalidComponentName].sort(function([a],[b]){return a.localeCompare(b)}))declarations.push({type:"VariableDeclarator",id:{type:"Identifier",name:componentName},init:{type:"MemberExpression",object:{type:"Identifier",name:"_components"},property:{type:"Literal",value:id},computed:!0,optional:!1}});componentsPattern&&declarations.push({type:"VariableDeclarator",id:componentsPattern,init:componentsInit}),declarations.length>0&&statements.push({type:"VariableDeclaration",kind:"const",declarations});}let key;for(key in functionInfo.references)if(Object.hasOwn(functionInfo.references,key)){let parts=key.split("."),index3=0;for(;++index3<parts.length;){let partial=parts.slice(0,index3).join(".");Object.hasOwn(functionInfo.references,partial)||(functionInfo.references[partial]={component:!1,node:functionInfo.references[key].node});}}let references=Object.keys(functionInfo.references).sort(),index2=-1;for(;++index2<references.length;){let id=references[index2],info=functionInfo.references[id],place=stringifyPosition(positionFromEstree(info.node)),parameters2=[{type:"Literal",value:id},{type:"Literal",value:info.component}];createErrorHelper=!0,development&&place&&parameters2.push({type:"Literal",value:place}),statements.push({type:"IfStatement",test:{type:"UnaryExpression",operator:"!",prefix:!0,argument:toIdOrMemberExpression(id.split("."))},consequent:{type:"ExpressionStatement",expression:{type:"CallExpression",callee:{type:"Identifier",name:"_missingMdxReference"},arguments:parameters2,optional:!1}},alternate:void 0});}statements.length>0&&(node2.body.type!=="BlockStatement"&&(node2.body={type:"BlockStatement",body:[{type:"ReturnStatement",argument:node2.body}]}),node2.body.body.unshift(...statements)),functionStack.pop();}}}),importProvider&&providerImportSource&&tree.body.unshift(createImportProvider(providerImportSource,outputFormat)),createErrorHelper){let message=[{type:"Literal",value:"Expected "},{type:"ConditionalExpression",test:{type:"Identifier",name:"component"},consequent:{type:"Literal",value:"component"},alternate:{type:"Literal",value:"object"}},{type:"Literal",value:" `"},{type:"Identifier",name:"id"},{type:"Literal",value:"` to be defined: you likely forgot to import, pass, or provide it."}],parameters=[{type:"Identifier",name:"id"},{type:"Identifier",name:"component"}];development&&(message.push({type:"ConditionalExpression",test:{type:"Identifier",name:"place"},consequent:toBinaryAddition([{type:"Literal",value:"\nIt\u2019s referenced in your code at `"},{type:"Identifier",name:"place"},{type:"Literal",value:(file.path?"` in `"+file.path:"")+"`"}]),alternate:{type:"Literal",value:""}}),parameters.push({type:"Identifier",name:"place"})),tree.body.push({type:"FunctionDeclaration",id:{type:"Identifier",name:"_missingMdxReference"},generator:!1,async:!1,params:parameters,body:{type:"BlockStatement",body:[{type:"ThrowStatement",argument:{type:"NewExpression",callee:{type:"Identifier",name:"Error"},arguments:[toBinaryAddition(message)]}}]}});}outputFormat==="function-body"&&tree.body.unshift({type:"ExpressionStatement",expression:{type:"Literal",value:"use strict"},directive:"use strict"});}}function createImportProvider(providerImportSource,outputFormat){let specifiers=[{type:"ImportSpecifier",imported:{type:"Identifier",name:"useMDXComponents"},local:{type:"Identifier",name:"_provideComponents"}}];return outputFormat==="function-body"?{type:"VariableDeclaration",kind:"const",declarations:specifiersToDeclarations(specifiers,toIdOrMemberExpression(["arguments",0]))}:{type:"ImportDeclaration",specifiers,source:{type:"Literal",value:providerImportSource}}}function isNamedFunction(node2,name2){return !!(node2&&"id"in node2&&node2.id&&node2.id.name===name2)}function inScope(scopes,id){let index2=scopes.length;for(;index2--;)if(scopes[index2].defined.includes(id))return !0;return !1}var init_recma_jsx_rewrite=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/recma-jsx-rewrite.js"(){init_estree_util_is_identifier_name();init_estree_util_scope();init_src();init_unist_util_stringify_position();init_unist_util_position_from_estree();init_estree_util_specifiers_to_declarations();init_estree_util_to_binary_addition();init_estree_util_to_id_or_member_expression();}});function rehypeRemoveRaw(){return function(tree){visit(tree,"raw",function(_,index2,parent){if(parent&&typeof index2=="number")return parent.children.splice(index2,1),index2});}}var init_rehype_remove_raw=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/rehype-remove-raw.js"(){init_unist_util_visit();}});function collapseWhiteSpace(value,options){options?typeof options=="string"&&(options={style:options}):options={};let replace=options.preserveLineEndings?replaceLineEnding:replaceSpace;return String(value).replace(options.style==="html"?html4:js,options.trim?trimFactory(replace):replace)}function replaceLineEnding(value){let match=/\r?\n|\r/.exec(value);return match?match[0]:" "}function replaceSpace(){return " "}function trimFactory(replace){return dropOrReplace;function dropOrReplace(value,index2,all4){return index2===0||index2+value.length===all4.length?"":replace(value)}}var js,html4,init_collapse_white_space=__esm({"../../node_modules/collapse-white-space/index.js"(){js=/\s+/g,html4=/[\t\n\v\f\r ]+/g;}});function remarkMarkAndUnravel(){return function(tree){visit(tree,function(node2,index2,parent){let offset3=-1,all4=!0,oneOrMore=!1;if(parent&&typeof index2=="number"&&node2.type==="paragraph"){let children=node2.children;for(;++offset3<children.length;){let child=children[offset3];if(child.type==="mdxJsxTextElement"||child.type==="mdxTextExpression")oneOrMore=!0;else if(!(child.type==="text"&&collapseWhiteSpace(child.value,{style:"html",trim:!0})==="")){all4=!1;break}}if(all4&&oneOrMore){offset3=-1;let newChildren=[];for(;++offset3<children.length;){let child=children[offset3];child.type==="mdxJsxTextElement"&&(child.type="mdxJsxFlowElement"),child.type==="mdxTextExpression"&&(child.type="mdxFlowExpression"),child.type==="text"&&/^[\t\r\n ]+$/.test(String(child.value))||newChildren.push(child);}return parent.children.splice(index2,1,...newChildren),index2}}if(node2.type==="mdxJsxFlowElement"||node2.type==="mdxJsxTextElement"){let data3=node2.data||(node2.data={});data3._mdxExplicitJsx=!0;}(node2.type==="mdxFlowExpression"||node2.type==="mdxTextExpression"||node2.type==="mdxjsEsm")&&node2.data&&node2.data.estree&&walk2(node2.data.estree,{enter(node3){if(node3.type==="JSXElement"){let data3=node3.data||(node3.data={});data3._mdxExplicitJsx=!0;}}});});}}var init_remark_mark_and_unravel=__esm({"../../node_modules/@mdx-js/mdx/lib/plugin/remark-mark-and-unravel.js"(){init_collapse_white_space();init_src();init_unist_util_visit();}});var nodeTypes,init_node_types=__esm({"../../node_modules/@mdx-js/mdx/lib/node-types.js"(){nodeTypes=["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"];}});function createProcessor(options){let settings=options||{},index2=-1;for(;++index2<removedOptions.length;){removedOptions[index2];}settings.format==="detect"&&void 0,(settings.jsxRuntime==="classic"||settings.pragma||settings.pragmaFrag||settings.pragmaImportSource)&&!warned&&(warned=!0,console.warn("Unexpected deprecated option `jsxRuntime: 'classic'`, `pragma`, `pragmaFrag`, or `pragmaImportSource`; see <https://mdxjs.com/migrating/v3/> on how to migrate"));let pipeline=unified().use(remarkParse);settings.format!=="md"&&pipeline.use(remarkMdx);let remarkRehypeOptions=settings.remarkRehypeOptions||{};return pipeline.use(remarkMarkAndUnravel).use(settings.remarkPlugins||[]).use(remarkRehype,{...remarkRehypeOptions,allowDangerousHtml:!0,passThrough:[...remarkRehypeOptions.passThrough||[],...nodeTypes]}).use(settings.rehypePlugins||[]),settings.format==="md"&&pipeline.use(rehypeRemoveRaw),pipeline.use(rehypeRecma,settings).use(recmaDocument,settings).use(recmaJsxRewrite,settings),settings.jsx||pipeline.use(recmaJsx,settings).use(recmaBuildJsxTransform,settings),pipeline.use(recmaJsx2).use(recmaStringify,settings).use(settings.recmaPlugins||[]),pipeline}var removedOptions,warned,init_core2=__esm({"../../node_modules/@mdx-js/mdx/lib/core.js"(){init_recma_build_jsx();init_recma_jsx();init_recma_stringify();init_rehype_recma();init_remark_mdx();init_remark_parse();init_remark_rehype();init_unified();init_recma_build_jsx_transform();init_recma_document();init_recma_jsx_rewrite();init_rehype_remove_raw();init_remark_mark_and_unravel();init_node_types();removedOptions=["compilers","filepath","hastPlugins","mdPlugins","skipExport","wrapExport"],warned=!1;}});function compile(vfileCompatible,compileOptions){let{file,options}=resolveFileAndOptions(vfileCompatible,compileOptions);return createProcessor(options).process(file)}var init_compile=__esm({"../../node_modules/@mdx-js/mdx/lib/compile.js"(){init_resolve_file_and_options();init_core2();}});var init_mdx=__esm({"../../node_modules/@mdx-js/mdx/index.js"(){init_compile();}});function getCompilerOptions(mdxCompileOptions){return {providerImportSource:"@mdx-js/react",rehypePlugins:[],...mdxCompileOptions}}var compile2,init_compiler=__esm({"src/compiler/index.ts"(){init_mdx();compile2=async(input,{mdxCompileOptions={}}={})=>{let options=getCompilerOptions(mdxCompileOptions);return (await compile(input,options)).toString()};}});var mdx_plugin_exports={};__export(mdx_plugin_exports,{mdxPlugin:()=>mdxPlugin});async function mdxPlugin(options){let filter=createFilter(/\.mdx$/),{presets}=options,mdxPluginOptions=(await presets.apply("options",{}))?.mdxPluginOptions,rehypeSlug2=(await Promise.resolve().then(()=>(init_rehype_slug(),rehype_slug_exports))).default,rehypeExternalLinks2=(await Promise.resolve().then(()=>(init_rehype_external_links(),rehype_external_links_exports))).default;return {name:"storybook:mdx-plugin",enforce:"pre",async transform(src,id){if(!filter(id))return;let mdxLoaderOptions=await presets.apply("mdxLoaderOptions",{...mdxPluginOptions,mdxCompileOptions:{providerImportSource:default2.join(default2.dirname(__require.resolve("@storybook/addon-docs/package.json")),"/dist/shims/mdx-react-shim.mjs"),...mdxPluginOptions?.mdxCompileOptions,rehypePlugins:[...mdxPluginOptions?.mdxCompileOptions?.rehypePlugins??[],rehypeSlug2,rehypeExternalLinks2]}});return {code:String(await compile2(src,mdxLoaderOptions)),map:null}}}}var init_mdx_plugin=__esm({"src/plugins/mdx-plugin.ts"(){init_es();init_compiler();}});var getResolvedReact=async options=>{let resolvedReact2=await options.presets.apply("resolvedReact",{});return {react:resolvedReact2.react??default2.dirname(__require.resolve("react/package.json")),reactDom:resolvedReact2.reactDom??default2.dirname(__require.resolve("react-dom/package.json")),mdx:resolvedReact2.mdx??default2.dirname(__require.resolve("@mdx-js/react"))}};async function webpack(webpackConfig={},options){let{module={}}=webpackConfig,{csfPluginOptions={},mdxPluginOptions={}}=options,rehypeSlug2=(await Promise.resolve().then(()=>(init_rehype_slug(),rehype_slug_exports))).default,rehypeExternalLinks2=(await Promise.resolve().then(()=>(init_rehype_external_links(),rehype_external_links_exports))).default,mdxLoaderOptions=await options.presets.apply("mdxLoaderOptions",{...mdxPluginOptions,mdxCompileOptions:{providerImportSource:default2.join(default2.dirname(__require.resolve("@storybook/addon-docs/package.json")),"/dist/shims/mdx-react-shim.mjs"),...mdxPluginOptions.mdxCompileOptions,rehypePlugins:[...mdxPluginOptions?.mdxCompileOptions?.rehypePlugins??[],rehypeSlug2,rehypeExternalLinks2]}});nodeLogger.logger.info("Addon-docs: using MDX3");let{react,reactDom,mdx}=await getResolvedReact(options),alias;return Array.isArray(webpackConfig.resolve?.alias)?(alias=[...webpackConfig.resolve?.alias],alias.push({name:"react",alias:react},{name:"react-dom",alias:reactDom},{name:"@mdx-js/react",alias:mdx})):alias={...webpackConfig.resolve?.alias,react,"react-dom":reactDom,"@mdx-js/react":mdx},{...webpackConfig,plugins:[...webpackConfig.plugins||[],...csfPluginOptions?[(await import('@storybook/csf-plugin')).webpack(csfPluginOptions)]:[]],resolve:{...webpackConfig.resolve,alias},module:{...module,rules:[...module.rules||[],{test:/\.mdx$/,exclude:/(stories|story)\.mdx$/,use:[{loader:__require.resolve("./mdx-loader"),options:mdxLoaderOptions}]}]}}}var docs=(input={},options)=>{if(options?.build?.test?.disableAutoDocs)return;let result={...input,defaultName:"Docs"},docsMode=options.docs;return docsMode&&(result.docsMode=docsMode),result},addons=[__require.resolve("@storybook/react-dom-shim/dist/preset")],viteFinal=async(config,options)=>{let{plugins=[]}=config,{mdxPlugin:mdxPlugin2}=await Promise.resolve().then(()=>(init_mdx_plugin(),mdx_plugin_exports)),{react,reactDom,mdx}=await getResolvedReact(options),themingPath=default2.dirname(__require.resolve("storybook/theming")),packageDeduplicationPlugin={name:"storybook:package-deduplication",enforce:"pre",config:()=>({resolve:{alias:{react,...default2.isAbsolute(reactDom)&&{"react-dom/server":`${reactDom}/server.browser.js`},"react-dom":reactDom,"@mdx-js/react":mdx,"storybook/theming":themingPath}}})};return plugins.unshift(packageDeduplicationPlugin),plugins.unshift(mdxPlugin2(options)),{...config,plugins}},webpackX=webpack,docsX=docs,resolvedReact=async existing=>({react:existing?.react??default2.dirname(__require.resolve("react/package.json")),reactDom:existing?.reactDom??default2.dirname(__require.resolve("react-dom/package.json")),mdx:existing?.mdx??default2.dirname(__require.resolve("@mdx-js/react"))}),optimizeViteDeps=["@mdx-js/react","@storybook/addon-docs","markdown-to-jsx"];
72
72
 
73
73
  exports.addons = addons;
74
74
  exports.docs = docsX;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/addon-docs",
3
- "version": "9.0.11",
3
+ "version": "9.0.12",
4
4
  "description": "Document component usage and properties in Markdown",
5
5
  "keywords": [
6
6
  "addon",
@@ -111,9 +111,9 @@
111
111
  },
112
112
  "dependencies": {
113
113
  "@mdx-js/react": "^3.0.0",
114
- "@storybook/csf-plugin": "9.0.11",
114
+ "@storybook/csf-plugin": "9.0.12",
115
115
  "@storybook/icons": "^1.2.12",
116
- "@storybook/react-dom-shim": "9.0.11",
116
+ "@storybook/react-dom-shim": "9.0.12",
117
117
  "react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
118
118
  "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0",
119
119
  "ts-dedent": "^2.0.0"
@@ -140,7 +140,7 @@
140
140
  "vite": "^6.2.5"
141
141
  },
142
142
  "peerDependencies": {
143
- "storybook": "^9.0.11"
143
+ "storybook": "^9.0.12"
144
144
  },
145
145
  "publishConfig": {
146
146
  "access": "public"