@mintlify/cli 4.1.86 → 4.1.87
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{cli-CY_nQTg8.js → cli-eZs65L66.js} +1 -1
- package/dist/{live-DD6wtFs0.js → live-CdptobvR.js} +1 -1
- package/dist/{live-DWkaHufM.js → live-J0vTIkyk.js} +2 -2
- package/dist/{multi-repo-command-C77Fkq9h.js → multi-repo-command-CQL_HD4n.js} +1 -1
- package/dist/{multi-repo-command-EXcJ0PHc.js → multi-repo-command-CbXq8sCW.js} +1 -1
- package/dist/start.js +1 -1
- package/package.json +9 -9
|
@@ -4,7 +4,7 @@ import { dirname as __mintDirname } from 'node:path';
|
|
|
4
4
|
const require = __mintCreateRequire(import.meta.url);
|
|
5
5
|
const __filename = __mintFileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __mintDirname(__filename);
|
|
7
|
-
import{i as e,o as t,t as n}from"./rolldown-runtime-CEAe2Uac.js";import{B as r,C as i,D as a,G as o,J as s,L as c,N as l,R as u,V as d,W as f,Y as p,a as m,b as h,d as g,et as _,f as v,g as y,m as b,nt as x,p as S,q as C,r as w,t as T,v as E,y as D}from"./dist-DQMmUueM.js";import{$t as O,Bn as k,Cn as A,Fn as ee,Gt as j,Hn as te,In as ne,Ln as re,Mn as ie,Nn as ae,Qt as oe,Rn as se,St as ce,Tt as le,Vn as ue,Vt as de,Y as fe,Yn as pe,Zn as me,ir as he,it as ge,jn as _e,kn as ve,lr as ye,m as be,nt as xe,or as Se,ot as Ce,s as we,tr as Te,tt as Ee,wt as De,zt as Oe}from"./dist-jWkjigqF.js";import{g as ke,h as M,m as Ae}from"./build-dp785b-C.js";import{a as je,i as Me,n as Ne}from"./multi-repo-command-EXcJ0PHc.js";import{c as Pe,l as Fe,n as Ie,t as Le,u as Re}from"./agent-Da2kI1tZ.js";import{A as ze,C as Be,D as Ve,E as He,F as Ue,I as We,L as N,M as Ge,N as Ke,O as qe,P as Je,R as Ye,S as Xe,T as Ze,_ as Qe,a as $e,b as et,c as tt,d as nt,f as rt,g as it,h as at,i as ot,j as st,k as ct,l as lt,m as ut,n as dt,o as ft,p as pt,r as mt,s as ht,t as gt,u as _t,v as vt,w as yt,x as bt,y as xt,z as St}from"./config-CQe8eTOd.js";import{n as Ct,t as wt}from"./client-DXQ6Tgw0.js";import{_ as Tt,a as Et,b as Dt,c as Ot,d as kt,f as At,g as jt,h as Mt,i as Nt,l as Pt,m as Ft,n as It,o as Lt,p as Rt,r as zt,s as Bt,t as Vt,u as Ht,v as Ut}from"./esm-Bzf2rZuk.js";import{C as Wt,S as Gt,_ as Kt,a as qt,b as Jt,c as Yt,d as Xt,f as Zt,g as Qt,h as $t,i as en,l as tn,m as nn,o as rn,p as an,r as on,s as sn,u as cn,v as ln,x as un,y as dn}from"./live-DWkaHufM.js";import{P as fn,dt as pn,tt as mn}from"./utils-BUq37nH_.js";import{n as hn}from"./remark-utils-CV-HGimg.js";import{_ as gn,a as _n,c as vn,d as yn,f as bn,l as xn,m as Sn,o as Cn,p as wn,s as Tn,u as En,v as Dn}from"./schemas-CVKidklE.js";import{n as On,t as kn}from"./currencyMath-Bm2NMq0k.js";import{createRequire as An}from"node:module";import jn from"path";import{existsSync as Mn,readFileSync as Nn,readdirSync as Pn}from"node:fs";import{execFile as Fn,spawn as In}from"node:child_process";import Ln from"node:os";import Rn from"node:path";import{createHash as zn,randomUUID as Bn}from"node:crypto";import{fileURLToPath as Vn}from"node:url";import{format as Hn,stripVTControlCharacters as Un}from"node:util";import Wn,{mkdir as Gn,mkdtemp as Kn,readFile as qn,writeFile as Jn}from"node:fs/promises";import Yn from"node:process";import Xn,{promises as Zn}from"fs";import Qn from"crypto";import{createRequire as $n}from"module";import er from"os";import{setTimeout as tr}from"node:timers/promises";var P=x();const nr=(e,t)=>{let n=t.a+e.a-t.a*e.a;if(n===0)return{r:0,g:0,b:0,a:0};let r=t.a/n,i=(e,t)=>Math.round((1-r)*e+r*t);return{r:i(e.r,t.r),g:i(e.g,t.g),b:i(e.b,t.b),a:n}},rr=e=>{let t=/^#?([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i.exec(e)?.[1];if(!t)throw TypeError(`Expected a valid hex string, got ${e}`);let n=t.length<6?[...t].map(e=>e+e).join(``):t,r=Number.parseInt(n.slice(0,6),16);return{red:r>>16,green:r>>8&255,blue:r&255,alpha:n.length===8?Number.parseInt(n.slice(6,8),16)/255:1}},ir=e=>{try{let t=rr(e);return`${t.red} ${t.green} ${t.blue}`}catch{return`0 0 0`}},ar=e=>`${e.r} ${e.g} ${e.b}`,or=e=>`#${e.r.toString(16).padStart(2,`0`)}${e.g.toString(16).padStart(2,`0`)}${e.b.toString(16).padStart(2,`0`)}`,sr=(e,t,n)=>{if(t)return n?t:ir(t);let r=cr(`#09090b`,1,e,.02);return n?or(r):ar(r)},cr=(e,t,n,r)=>{let i=rr(e),a=rr(n);return nr({r:i.red,g:i.green,b:i.blue,a:t},{r:a.red,g:a.green,b:a.blue,a:r})},lr=`#4ADE80`,ur=(e=lr)=>({light:`#ffffff`,dark:sr(e,void 0,!0)});function dr(e){let t=e?.colors.primary||`#16A34A`,n=e?.colors.light??lr;e?.theme===`linden`&&(e.background=Object.assign(Object.assign({},e.background),{color:{light:e.background?.color?.light||or(cr(`#FFFFFF`,1,t,.03)),dark:e.background?.color?.dark||or(cr(`#09090B`,1,n,.03))}}));let r=e?.background?.color?.light??`#ffffff`;return{light:ir(r),dark:sr(n,e?.background?.color?.dark),lightHex:r,darkHex:sr(n,e?.background?.color?.dark,!0),background:e?.thumbnails?.background}}var F=class e extends Error{constructor(t,n){var r=`KaTeX parse error: `+t,i,a,o=n&&n.loc;if(o&&o.start<=o.end){var s=o.lexer.input;i=o.start,a=o.end,i===s.length?r+=` at end of input: `:r+=` at position `+(i+1)+`: `;var c=s.slice(i,a).replace(/[^]/g,`$&̲`),l=i>15?`…`+s.slice(i-15,i):s.slice(0,i),u=a+15<s.length?s.slice(a,a+15)+`…`:s.slice(a);r+=l+c+u}super(r),this.name=`ParseError`,this.position=void 0,this.length=void 0,this.rawMessage=void 0,Object.setPrototypeOf(this,e.prototype),this.position=i,i!=null&&a!=null&&(this.length=a-i),this.rawMessage=t}},fr=/([A-Z])/g,pr=e=>e.replace(fr,`-$1`).toLowerCase(),mr={"&":`&`,">":`>`,"<":`<`,'"':`"`,"'":`'`},hr=/[&><"']/g,gr=e=>String(e).replace(hr,e=>mr[e]),_r=e=>e.type===`ordgroup`||e.type===`color`?e.body.length===1?_r(e.body[0]):e:e.type===`font`?_r(e.body):e,vr=/* @__PURE__ */ new Set([`mathord`,`textord`,`atom`]),yr=e=>vr.has(_r(e).type),br=e=>{var t=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(e);return t?t[2]!==`:`||!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(t[1])?null:t[1].toLowerCase():`_relative`},xr={displayMode:{type:`boolean`,description:`Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.`,cli:`-d, --display-mode`},output:{type:{enum:[`htmlAndMathml`,`html`,`mathml`]},description:`Determines the markup language of the output.`,cli:`-F, --format <type>`},leqno:{type:`boolean`,description:`Render display math in leqno style (left-justified tags).`},fleqn:{type:`boolean`,description:`Render display math flush left.`},throwOnError:{type:`boolean`,default:!0,cli:`-t, --no-throw-on-error`,cliDescription:`Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error.`},errorColor:{type:`string`,default:`#cc0000`,cli:`-c, --error-color <color>`,cliDescription:`A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.`,cliProcessor:e=>`#`+e},macros:{type:`object`,cli:`-m, --macro <def>`,cliDescription:`Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).`,cliDefault:[],cliProcessor:(e,t)=>(t.push(e),t)},minRuleThickness:{type:`number`,description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:e=>Math.max(0,e),cli:`--min-rule-thickness <size>`,cliProcessor:parseFloat},colorIsTextColor:{type:`boolean`,description:`Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.`,cli:`-b, --color-is-text-color`},strict:{type:[{enum:[`warn`,`ignore`,`error`]},`boolean`,`function`],description:`Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.`,cli:`-S, --strict`,cliDefault:!1},trust:{type:[`boolean`,`function`],description:`Trust the input, enabling all HTML features such as \\url.`,cli:`-T, --trust`},maxSize:{type:`number`,default:1/0,description:`If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large`,processor:e=>Math.max(0,e),cli:`-s, --max-size <n>`,cliProcessor:parseInt},maxExpand:{type:`number`,default:1e3,description:`Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.`,processor:e=>Math.max(0,e),cli:`-e, --max-expand <n>`,cliProcessor:e=>e===`Infinity`?1/0:parseInt(e)},globalGroup:{type:`boolean`,cli:!1}};function Sr(e){if(typeof e!=`string`)return e.enum[0];switch(e){case`boolean`:return!1;case`string`:return``;case`number`:return 0;case`object`:return{};default:throw Error(`Unexpected schema type; settings must declare an explicit default.`)}}function Cr(e){return e.default===void 0?Sr(Array.isArray(e.type)?e.type[0]:e.type):e.default}function wr(e,t,n,r){var i=n[t];e[t]=i===void 0?Cr(r):r.processor?r.processor(i):i}var Tr=class{constructor(e){e===void 0&&(e={}),this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,e||={};for(var t of Object.keys(xr)){var n=xr[t];n&&wr(this,t,e,n)}}reportNonstrict(e,t,n){var r=this.strict;if(typeof r==`function`&&(r=r(e,t,n)),r&&r!==`ignore`){if(r===!0||r===`error`)throw new F(`LaTeX-incompatible input and strict mode is set to 'error': `+(t+` [`+e+`]`),n);r===`warn`?typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(t+` [`+e+`]`)):typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+r+`': `+t+` [`+e+`]`))}}useStrictBehavior(e,t,n){var r=this.strict;if(typeof r==`function`)try{r=r(e,t,n)}catch{r=`error`}return!r||r===`ignore`?!1:r===!0||r===`error`?!0:r===`warn`?(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(t+` [`+e+`]`)),!1):(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+r+`': `+t+` [`+e+`]`)),!1)}isTrusted(e){if(`url`in e&&e.url&&!e.protocol){var t=br(e.url);if(t==null)return!1;e.protocol=t}return!!(typeof this.trust==`function`?this.trust(e):this.trust)}},Er=class{constructor(e,t,n){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=e,this.size=t,this.cramped=n}sup(){return Fr[Ir[this.id]]}sub(){return Fr[Lr[this.id]]}fracNum(){return Fr[Rr[this.id]]}fracDen(){return Fr[zr[this.id]]}cramp(){return Fr[Br[this.id]]}text(){return Fr[Vr[this.id]]}isTight(){return this.size>=2}},Dr=0,Or=1,kr=2,Ar=3,jr=4,Mr=5,Nr=6,Pr=7,Fr=[new Er(Dr,0,!1),new Er(Or,0,!0),new Er(kr,1,!1),new Er(Ar,1,!0),new Er(jr,2,!1),new Er(Mr,2,!0),new Er(Nr,3,!1),new Er(Pr,3,!0)],Ir=[jr,Mr,jr,Mr,Nr,Pr,Nr,Pr],Lr=[Mr,Mr,Mr,Mr,Pr,Pr,Pr,Pr],Rr=[kr,Ar,jr,Mr,Nr,Pr,Nr,Pr],zr=[Ar,Ar,Mr,Mr,Pr,Pr,Pr,Pr],Br=[Or,Or,Ar,Ar,Mr,Mr,Pr,Pr],Vr=[Dr,Or,kr,Ar,kr,Ar,kr,Ar],Hr={DISPLAY:Fr[Dr],TEXT:Fr[kr],SCRIPT:Fr[jr],SCRIPTSCRIPT:Fr[Nr]},Ur=[{name:`latin`,blocks:[[256,591],[768,879]]},{name:`cyrillic`,blocks:[[1024,1279]]},{name:`armenian`,blocks:[[1328,1423]]},{name:`brahmic`,blocks:[[2304,4255]]},{name:`georgian`,blocks:[[4256,4351]]},{name:`cjk`,blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:`hangul`,blocks:[[44032,55215]]}];function Wr(e){for(var t=0;t<Ur.length;t++)for(var n=Ur[t],r=0;r<n.blocks.length;r++){var i=n.blocks[r];if(e>=i[0]&&e<=i[1])return n.name}return null}var Gr=[];Ur.forEach(e=>e.blocks.forEach(e=>Gr.push(...e)));function Kr(e){for(var t=0;t<Gr.length;t+=2)if(e>=Gr[t]&&e<=Gr[t+1])return!0;return!1}var qr=e=>e+` `+e,Jr=80,Yr=function(e,t){return`M95,`+(622+e+t)+`
|
|
7
|
+
import{i as e,o as t,t as n}from"./rolldown-runtime-CEAe2Uac.js";import{B as r,C as i,D as a,G as o,J as s,L as c,N as l,R as u,V as d,W as f,Y as p,a as m,b as h,d as g,et as _,f as v,g as y,m as b,nt as x,p as S,q as C,r as w,t as T,v as E,y as D}from"./dist-DQMmUueM.js";import{$t as O,Bn as k,Cn as A,Fn as ee,Gt as j,Hn as te,In as ne,Ln as re,Mn as ie,Nn as ae,Qt as oe,Rn as se,St as ce,Tt as le,Vn as ue,Vt as de,Y as fe,Yn as pe,Zn as me,ir as he,it as ge,jn as _e,kn as ve,lr as ye,m as be,nt as xe,or as Se,ot as Ce,s as we,tr as Te,tt as Ee,wt as De,zt as Oe}from"./dist-jWkjigqF.js";import{g as ke,h as M,m as Ae}from"./build-dp785b-C.js";import{a as je,i as Me,n as Ne}from"./multi-repo-command-CbXq8sCW.js";import{c as Pe,l as Fe,n as Ie,t as Le,u as Re}from"./agent-Da2kI1tZ.js";import{A as ze,C as Be,D as Ve,E as He,F as Ue,I as We,L as N,M as Ge,N as Ke,O as qe,P as Je,R as Ye,S as Xe,T as Ze,_ as Qe,a as $e,b as et,c as tt,d as nt,f as rt,g as it,h as at,i as ot,j as st,k as ct,l as lt,m as ut,n as dt,o as ft,p as pt,r as mt,s as ht,t as gt,u as _t,v as vt,w as yt,x as bt,y as xt,z as St}from"./config-CQe8eTOd.js";import{n as Ct,t as wt}from"./client-DXQ6Tgw0.js";import{_ as Tt,a as Et,b as Dt,c as Ot,d as kt,f as At,g as jt,h as Mt,i as Nt,l as Pt,m as Ft,n as It,o as Lt,p as Rt,r as zt,s as Bt,t as Vt,u as Ht,v as Ut}from"./esm-Bzf2rZuk.js";import{C as Wt,S as Gt,_ as Kt,a as qt,b as Jt,c as Yt,d as Xt,f as Zt,g as Qt,h as $t,i as en,l as tn,m as nn,o as rn,p as an,r as on,s as sn,u as cn,v as ln,x as un,y as dn}from"./live-J0vTIkyk.js";import{P as fn,dt as pn,tt as mn}from"./utils-BUq37nH_.js";import{n as hn}from"./remark-utils-CV-HGimg.js";import{_ as gn,a as _n,c as vn,d as yn,f as bn,l as xn,m as Sn,o as Cn,p as wn,s as Tn,u as En,v as Dn}from"./schemas-CVKidklE.js";import{n as On,t as kn}from"./currencyMath-Bm2NMq0k.js";import{createRequire as An}from"node:module";import jn from"path";import{existsSync as Mn,readFileSync as Nn,readdirSync as Pn}from"node:fs";import{execFile as Fn,spawn as In}from"node:child_process";import Ln from"node:os";import Rn from"node:path";import{createHash as zn,randomUUID as Bn}from"node:crypto";import{fileURLToPath as Vn}from"node:url";import{format as Hn,stripVTControlCharacters as Un}from"node:util";import Wn,{mkdir as Gn,mkdtemp as Kn,readFile as qn,writeFile as Jn}from"node:fs/promises";import Yn from"node:process";import Xn,{promises as Zn}from"fs";import Qn from"crypto";import{createRequire as $n}from"module";import er from"os";import{setTimeout as tr}from"node:timers/promises";var P=x();const nr=(e,t)=>{let n=t.a+e.a-t.a*e.a;if(n===0)return{r:0,g:0,b:0,a:0};let r=t.a/n,i=(e,t)=>Math.round((1-r)*e+r*t);return{r:i(e.r,t.r),g:i(e.g,t.g),b:i(e.b,t.b),a:n}},rr=e=>{let t=/^#?([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i.exec(e)?.[1];if(!t)throw TypeError(`Expected a valid hex string, got ${e}`);let n=t.length<6?[...t].map(e=>e+e).join(``):t,r=Number.parseInt(n.slice(0,6),16);return{red:r>>16,green:r>>8&255,blue:r&255,alpha:n.length===8?Number.parseInt(n.slice(6,8),16)/255:1}},ir=e=>{try{let t=rr(e);return`${t.red} ${t.green} ${t.blue}`}catch{return`0 0 0`}},ar=e=>`${e.r} ${e.g} ${e.b}`,or=e=>`#${e.r.toString(16).padStart(2,`0`)}${e.g.toString(16).padStart(2,`0`)}${e.b.toString(16).padStart(2,`0`)}`,sr=(e,t,n)=>{if(t)return n?t:ir(t);let r=cr(`#09090b`,1,e,.02);return n?or(r):ar(r)},cr=(e,t,n,r)=>{let i=rr(e),a=rr(n);return nr({r:i.red,g:i.green,b:i.blue,a:t},{r:a.red,g:a.green,b:a.blue,a:r})},lr=`#4ADE80`,ur=(e=lr)=>({light:`#ffffff`,dark:sr(e,void 0,!0)});function dr(e){let t=e?.colors.primary||`#16A34A`,n=e?.colors.light??lr;e?.theme===`linden`&&(e.background=Object.assign(Object.assign({},e.background),{color:{light:e.background?.color?.light||or(cr(`#FFFFFF`,1,t,.03)),dark:e.background?.color?.dark||or(cr(`#09090B`,1,n,.03))}}));let r=e?.background?.color?.light??`#ffffff`;return{light:ir(r),dark:sr(n,e?.background?.color?.dark),lightHex:r,darkHex:sr(n,e?.background?.color?.dark,!0),background:e?.thumbnails?.background}}var F=class e extends Error{constructor(t,n){var r=`KaTeX parse error: `+t,i,a,o=n&&n.loc;if(o&&o.start<=o.end){var s=o.lexer.input;i=o.start,a=o.end,i===s.length?r+=` at end of input: `:r+=` at position `+(i+1)+`: `;var c=s.slice(i,a).replace(/[^]/g,`$&̲`),l=i>15?`…`+s.slice(i-15,i):s.slice(0,i),u=a+15<s.length?s.slice(a,a+15)+`…`:s.slice(a);r+=l+c+u}super(r),this.name=`ParseError`,this.position=void 0,this.length=void 0,this.rawMessage=void 0,Object.setPrototypeOf(this,e.prototype),this.position=i,i!=null&&a!=null&&(this.length=a-i),this.rawMessage=t}},fr=/([A-Z])/g,pr=e=>e.replace(fr,`-$1`).toLowerCase(),mr={"&":`&`,">":`>`,"<":`<`,'"':`"`,"'":`'`},hr=/[&><"']/g,gr=e=>String(e).replace(hr,e=>mr[e]),_r=e=>e.type===`ordgroup`||e.type===`color`?e.body.length===1?_r(e.body[0]):e:e.type===`font`?_r(e.body):e,vr=/* @__PURE__ */ new Set([`mathord`,`textord`,`atom`]),yr=e=>vr.has(_r(e).type),br=e=>{var t=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(e);return t?t[2]!==`:`||!/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(t[1])?null:t[1].toLowerCase():`_relative`},xr={displayMode:{type:`boolean`,description:`Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.`,cli:`-d, --display-mode`},output:{type:{enum:[`htmlAndMathml`,`html`,`mathml`]},description:`Determines the markup language of the output.`,cli:`-F, --format <type>`},leqno:{type:`boolean`,description:`Render display math in leqno style (left-justified tags).`},fleqn:{type:`boolean`,description:`Render display math flush left.`},throwOnError:{type:`boolean`,default:!0,cli:`-t, --no-throw-on-error`,cliDescription:`Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error.`},errorColor:{type:`string`,default:`#cc0000`,cli:`-c, --error-color <color>`,cliDescription:`A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.`,cliProcessor:e=>`#`+e},macros:{type:`object`,cli:`-m, --macro <def>`,cliDescription:`Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).`,cliDefault:[],cliProcessor:(e,t)=>(t.push(e),t)},minRuleThickness:{type:`number`,description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:e=>Math.max(0,e),cli:`--min-rule-thickness <size>`,cliProcessor:parseFloat},colorIsTextColor:{type:`boolean`,description:`Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.`,cli:`-b, --color-is-text-color`},strict:{type:[{enum:[`warn`,`ignore`,`error`]},`boolean`,`function`],description:`Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.`,cli:`-S, --strict`,cliDefault:!1},trust:{type:[`boolean`,`function`],description:`Trust the input, enabling all HTML features such as \\url.`,cli:`-T, --trust`},maxSize:{type:`number`,default:1/0,description:`If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large`,processor:e=>Math.max(0,e),cli:`-s, --max-size <n>`,cliProcessor:parseInt},maxExpand:{type:`number`,default:1e3,description:`Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.`,processor:e=>Math.max(0,e),cli:`-e, --max-expand <n>`,cliProcessor:e=>e===`Infinity`?1/0:parseInt(e)},globalGroup:{type:`boolean`,cli:!1}};function Sr(e){if(typeof e!=`string`)return e.enum[0];switch(e){case`boolean`:return!1;case`string`:return``;case`number`:return 0;case`object`:return{};default:throw Error(`Unexpected schema type; settings must declare an explicit default.`)}}function Cr(e){return e.default===void 0?Sr(Array.isArray(e.type)?e.type[0]:e.type):e.default}function wr(e,t,n,r){var i=n[t];e[t]=i===void 0?Cr(r):r.processor?r.processor(i):i}var Tr=class{constructor(e){e===void 0&&(e={}),this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,e||={};for(var t of Object.keys(xr)){var n=xr[t];n&&wr(this,t,e,n)}}reportNonstrict(e,t,n){var r=this.strict;if(typeof r==`function`&&(r=r(e,t,n)),r&&r!==`ignore`){if(r===!0||r===`error`)throw new F(`LaTeX-incompatible input and strict mode is set to 'error': `+(t+` [`+e+`]`),n);r===`warn`?typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(t+` [`+e+`]`)):typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+r+`': `+t+` [`+e+`]`))}}useStrictBehavior(e,t,n){var r=this.strict;if(typeof r==`function`)try{r=r(e,t,n)}catch{r=`error`}return!r||r===`ignore`?!1:r===!0||r===`error`?!0:r===`warn`?(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to 'warn': `+(t+` [`+e+`]`)),!1):(typeof console<`u`&&console.warn(`LaTeX-incompatible input and strict mode is set to `+(`unrecognized '`+r+`': `+t+` [`+e+`]`)),!1)}isTrusted(e){if(`url`in e&&e.url&&!e.protocol){var t=br(e.url);if(t==null)return!1;e.protocol=t}return!!(typeof this.trust==`function`?this.trust(e):this.trust)}},Er=class{constructor(e,t,n){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=e,this.size=t,this.cramped=n}sup(){return Fr[Ir[this.id]]}sub(){return Fr[Lr[this.id]]}fracNum(){return Fr[Rr[this.id]]}fracDen(){return Fr[zr[this.id]]}cramp(){return Fr[Br[this.id]]}text(){return Fr[Vr[this.id]]}isTight(){return this.size>=2}},Dr=0,Or=1,kr=2,Ar=3,jr=4,Mr=5,Nr=6,Pr=7,Fr=[new Er(Dr,0,!1),new Er(Or,0,!0),new Er(kr,1,!1),new Er(Ar,1,!0),new Er(jr,2,!1),new Er(Mr,2,!0),new Er(Nr,3,!1),new Er(Pr,3,!0)],Ir=[jr,Mr,jr,Mr,Nr,Pr,Nr,Pr],Lr=[Mr,Mr,Mr,Mr,Pr,Pr,Pr,Pr],Rr=[kr,Ar,jr,Mr,Nr,Pr,Nr,Pr],zr=[Ar,Ar,Mr,Mr,Pr,Pr,Pr,Pr],Br=[Or,Or,Ar,Ar,Mr,Mr,Pr,Pr],Vr=[Dr,Or,kr,Ar,kr,Ar,kr,Ar],Hr={DISPLAY:Fr[Dr],TEXT:Fr[kr],SCRIPT:Fr[jr],SCRIPTSCRIPT:Fr[Nr]},Ur=[{name:`latin`,blocks:[[256,591],[768,879]]},{name:`cyrillic`,blocks:[[1024,1279]]},{name:`armenian`,blocks:[[1328,1423]]},{name:`brahmic`,blocks:[[2304,4255]]},{name:`georgian`,blocks:[[4256,4351]]},{name:`cjk`,blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:`hangul`,blocks:[[44032,55215]]}];function Wr(e){for(var t=0;t<Ur.length;t++)for(var n=Ur[t],r=0;r<n.blocks.length;r++){var i=n.blocks[r];if(e>=i[0]&&e<=i[1])return n.name}return null}var Gr=[];Ur.forEach(e=>e.blocks.forEach(e=>Gr.push(...e)));function Kr(e){for(var t=0;t<Gr.length;t+=2)if(e>=Gr[t]&&e<=Gr[t+1])return!0;return!1}var qr=e=>e+` `+e,Jr=80,Yr=function(e,t){return`M95,`+(622+e+t)+`
|
|
8
8
|
c-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14
|
|
9
9
|
c0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54
|
|
10
10
|
c44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10
|
|
@@ -4,4 +4,4 @@ import { dirname as __mintDirname } from 'node:path';
|
|
|
4
4
|
const require = __mintCreateRequire(import.meta.url);
|
|
5
5
|
const __filename = __mintFileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __mintDirname(__filename);
|
|
7
|
-
export{t as DIAGNOSTICS_DIR,n as reportPathOf,r as watchComponentUsage}from"./live-
|
|
7
|
+
export{t as DIAGNOSTICS_DIR,n as reportPathOf,r as watchComponentUsage}from"./live-J0vTIkyk.js";
|
|
@@ -13,7 +13,7 @@ import{o as e}from"./rolldown-runtime-CEAe2Uac.js";import{$ as t,A as n,O as r,Q
|
|
|
13
13
|
`,r);if(t===-1)break;r=t+1}return r+n-1},V=(e,t)=>{let n=e.slice(0,t).split(`
|
|
14
14
|
`);return{line:n.length,column:(n.pop()?.length??0)+1}},Di=(e,t)=>e.start-t.start;function Oi(e,t,n){let r=0;for(let i of e){let e=i.start+r;if(n===`snap`?t<e:t<=e)break;if(t<e+i.text.length)return n===`snap`?i.start:void 0;r+=i.text.length-(i.end-i.start)}return t-r}const ki=(e,t,n)=>{let{start:r,end:i}=n;for(let{edits:n}of e.slice(0,t).reverse()){let e=[...n].sort(Di),t=Oi(e,r,`reject`),a=Oi(e,i,`reject`);if(t===void 0||a===void 0||e.some(e=>e.start<a&&e.end>t))return;r=t,i=a}return{start:r,end:i,text:n.text}},Ai=(e,t,n)=>{let r=e[t],i=e[0];if(!r||!i||n.line===void 0)return{};let a=e.slice(0,t).reduceRight((e,{edits:t})=>Oi([...t].sort(Di),e,`snap`),Ei(r.content,n.line,n.column)),o=V(i.content,a);return n.column===void 0?{line:o.line}:o},ji=e=>u(C(e)).replace(/^\.$/,``),Mi=(e,t)=>ii(void 0,void 0,void 0,function*(){let n=new br(e);try{yield Xr(n,t)}catch{return[]}return n.paths.flatMap(e=>e.pathType===L.INTERNAL&&e.anchorLink?[`${ji(Ae(e.toString()))}#${re(e.anchorLink.slice(1))}`]:[])}),Ni=(e,t,n)=>{let r=`${ji(t)}#`;for(let t of e??[]){if(!t.startsWith(r))continue;let e=t.slice(r.length),i=e.startsWith(`${n}-`)&&/^\d/.test(e.slice(n.length+1));if(e===n||i)return e}},Pi={id:`parse-error`,group:`content`,severity:`error`,description:`files MDX can't parse; other checks skip them`};var Fi=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})},Ii=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n};const Li=/* @__PURE__ */ new Set([`page`,`snippet`,`snippet-v2`]),Ri=(e,t)=>[...new Set([...t].flatMap(t=>{let n=Oe(t,`/${e.replace(/^\//,``)}`);return n?[n.toLowerCase()]:[]}))].sort().join(`
|
|
15
15
|
`),zi=e=>Fi(void 0,void 0,void 0,function*(){let{mdxCandidates:t}=yield S(e,yield he(e)),{snippets:n,snippetsV2:r,fileImportsMap:i}=yield ae(e,t),a=/* @__PURE__ */ new Set([...n,...r]),o=new Map(t.map(e=>[e.replace(/^\//,``),[...i.get(e.toLowerCase())??[]].sort().join(`
|
|
16
|
-
`)]));return{files:t.filter(e=>/\.mdx?$/.test(e)&&Li.has(ne(e))).map(e=>({file:e.replace(/^\//,``),kind:a.has(e)?`snippet`:`page`})),imports:o}}),Bi=e=>{try{let{attributes:t}=ie(e);return t&&typeof t==`object`?Object.assign({},t):{}}catch{return{}}},Vi=/\s*\(\d+:\d+(?:-\d+:\d+)?\)$/,Hi=/* @__PURE__ */ new Set([`unexpected-character`,`unexpected-eof`]),Ui=(e,t,n)=>{let{source:r,ruleId:i}=e??{};return r===`micromark-extension-mdx-jsx`&&typeof i==`string`&&Hi.has(i)&&n?.line!=null&&n.column!=null&&t[Ei(t,n.line,n.column)-1]===`<`},Wi=(e,t=``)=>{let n=e?.reason,r=e instanceof Error?e.message:`could not parse this file`,i=typeof n==`string`?n:r,a=e&&typeof e==`object`?me(e):null,o=Ui(e,t,a)?`; if this < isn't a tag, escape it as \\<`:``;return Object.assign(Object.assign(Object.assign({},a?.line!=null&&{line:a.line}),a?.column!=null&&{column:a.column}),{message:i.replace(Vi,``)+o})},Gi=(e,t)=>Object.assign(Object.assign({},t),{rule:Pi.id,group:Pi.group,severity:Pi.severity,file:e,message:`${t.message} (other checks were skipped for this file)`}),Ki=e=>{try{return ui(e)}catch{return}},qi=(e,t,n,r={})=>{let i=Object.assign({file:e,content:t,baseDir:n,frontmatter:Bi(t)},r),a=Ki(t);if(a)return{context:Object.assign(Object.assign({},i),{tree:a}),approximate:!1};try{return{context:Object.assign(Object.assign({},i),{tree:Ee(t,e)}),approximate:!0}}catch(e){return{error:Wi(e,t)}}},Ji={type:`root`,children:[]},Yi=/\{\{\s*([\w.\-]+)\s*\}\}/g,Xi=(e,t={})=>[...e.matchAll(Yi)].filter(e=>e[1]!==void 0&&t[e[1]]!==void 0).map(e=>({start:e.index,end:e.index+e[0].length,text:b(e[0],t)})),Zi=(e,t,n,r,i)=>{var{edit:a}=n,o=Ii(n,[`edit`]);let s=a&&ki(r,i,a);return Object.assign(Object.assign(Object.assign(Object.assign({},o),Ai(r,i,o)),{rule:e.id,group:e.group,severity:e.severity,file:t}),s&&{fix:Object.assign({file:t},s)})},Qi=(e,{file:t,kind:n},r,i,a,o)=>{let s=n===`snippet`?e.filter(e=>!e.pagesOnly):e,c=s.filter(e=>e.raw),l=s.filter(e=>!e.raw),u=n===`snippet`?Xi(r,o):[],d=Ti(r,u),f={file:t,content:d,baseDir:i,frontmatter:{},tree:Ji,variables:o},p=c.flatMap(e=>e.check(f).map(t=>({rule:e,finding:t}))),m=wi(p.flatMap(({finding:e})=>e.edit?[e.edit]:[])),h=Ti(d,m),g=[{content:r,edits:u},{content:d,edits:m},{content:h,edits:[]}],_=p.map(({rule:e,finding:n})=>Zi(e,t,n,g,1)),v=qi(t,h,i,Object.assign(Object.assign({},a),{variables:o}));if(`error`in v)return _.unshift(Gi(t,Object.assign(Object.assign({},v.error),Ai(g,2,v.error)))),_;for(let e of l)for(let n of e.check(v.context)){let r=v.approximate?Object.assign(Object.assign({},n),{edit:void 0}):n;_.push(Zi(e,t,r,g,2))}return _},$i=e=>Fi(void 0,void 0,void 0,function*(){let t=yield Promise.all(e.files.map(({file:t})=>Mi(t,e.read(t)??``)));return new Set(t.flat())}),ea=(e,t)=>Fi(void 0,void 0,void 0,function*(){let n=new Set(t.filter(e=>e.needsAnchorLinks).map(({id:e})=>e)),r=e.files.filter(({file:t})=>!e.selected||e.selected.has(t)),i=(n,r)=>{let i=e.read(n.file);return i===void 0?[Gi(n.file,{message:`could not read this file`})]:Qi(t,n,i,e.baseDir,r,e.variables)},a=e=>e.some(({rule:e})=>n.has(e)),o={readFile:e.read,themeVersion:e.themeVersion,latex:e.latex},s=r.map(e=>i(e,o));if(!s.some(a))return s.flat();let c=Object.assign(Object.assign({},o),{anchorLinks:yield $i(e)});return r.flatMap((e,t)=>{let n=s[t]??[];return a(n)?i(e,c):n})}),ta=[`humans`,`agents`,`signed-in`,`signed-out`],na={wide:"The page keeps the default width and still hides the table of contents; without `mode` the table of contents shows.",center:"The page keeps the default layout and still hides the table of contents; without `mode` the table of contents shows.",frame:"The page uses the default layout, but its headings still get no anchor ids and no table of contents; without `mode` they do."},ra=[`children`,`className`,`id`,`key`,`style`],ia=[`right`,`left`,`none`],aa=[`grey`,`violet`,`sky`,`teal`,`plum`,`crimson`,`info`,`success`,`warning`,`destructive`],oa=[`inline`,`base`],sa=[`default`,`color`],ca=[`dot`,`number`,`box`],la=[`timeline`,`divided`],ua=[`box`,`circle`,`dot`,`number`],da=[`solid`,`dashed`],fa=[`h2`,`h3`,`h4`],pa=[`rule`,`card`,`plain`],ma=[`background`,`plain`,`separator`],ha=[`compact`,`table`],ga=[`minimal`,`grid`],_a=[`equal`,`auto`],va=[`start`,`center`,`end`],ya=[`subtle`,`strong`],H=(e,{legacy:t={},invalid:n}={})=>Object.assign({values:e,legacy:t},n!==void 0&&{invalid:n}),ba=e=>e,U={icon:{kind:`icon`},iconType:{kind:`iconType`}},W={kind:`flag`},G={kind:`any`},K={status:`supported`,props:U,removedProps:{color:{note:`It is ignored. Style the callout with custom CSS on [data-component-item="alert"].`}}},xa={status:`pending`,anyProps:!0},Sa={type:G,typeHref:G,location:G,default:G,required:W,deprecated:W,hidden:W,pre:G,post:G},Ca={status:`supported`,within:[`Table`],anyProps:!0},wa=Object.assign(Object.assign({},Ca),{props:{align:H(va)}}),Ta={status:`supported`,props:{cols:{kind:`integer`,min:1,max:4},joined:W,variant:H(ma)}},Ea={status:`supported`,props:Object.assign(Object.assign({},U),{filename:G,language:G,lang:G,lines:W,wrap:W,expandable:W,nocopy:W,inline:W})},Da={status:`supported`},Oa={status:`supported`,within:[`Tree`,`FileTree`],props:{name:G,highlight:W}},ka=Object.assign(Object.assign({},Oa),{props:Object.assign(Object.assign({},Oa.props),{defaultOpen:W,openable:W})}),Aa=Object.assign({},xa),ja=`A tooltip holds text only. Put the link in the text next to the tooltip, or make the trigger itself a link.`,Ma={status:`removed`,note:"Written directly, it renders nothing of its own. Remove the tag; `twoslash` code fences still show hovers."},Na=ba({Accordion:{status:`supported`,props:Object.assign(Object.assign({},U),{title:G,description:G,defaultOpen:W})},AccordionGroup:{status:`supported`,children:[`Accordion`]},ApiPlayground:{status:`removed`,note:`Nothing renders in its place. Generate the API playground from OpenAPI or AsyncAPI.`},Badge:{status:`supported`,props:Object.assign(Object.assign({},U),{color:H(aa,{legacy:{gray:`grey`,blue:[`sky`,`info`],green:[`teal`,`success`],orange:`warning`,yellow:`warning`,red:[`crimson`,`destructive`],purple:`violet`,white:null,surface:null,"white-destructive":`destructive`,"surface-destructive":`destructive`}}),size:H(oa,{legacy:{xs:`inline`,sm:`inline`,md:`inline`,lg:`base`}}),type:H(sa)}),removedProps:{shape:{note:`The badge has one shape.`,remove:!0},stroke:{note:`The badge has no outline.`,remove:!0},disabled:{note:`The badge has no disabled state.`,remove:!0}}},Callout:K,Card:{status:`supported`,props:Object.assign(Object.assign({},U),{title:G,color:G,horizontal:W,href:G,img:G,disabled:W,cta:G,variant:H(ma)}),removedProps:{arrow:{note:"The card has no corner icon. Add a `cta` instead: it shows a chevron when the card links within the site."},type:{note:`It is ignored.`,remove:!0}}},CardGroup:Object.assign(Object.assign({},Ta),{status:`deprecated`,replacement:`Columns`}),Check:K,CodeBlock:Ea,CodeGroup:{status:`supported`,props:{dropdown:W,report:W}},Color:{status:`supported`,props:{variant:H(ha)}},"Color.Row":{status:`supported`,within:[`Color`],props:{title:G}},"Color.Item":{status:`supported`,within:[`Color`],required:[{props:[`value`],note:`Without it the item does not render.`}],props:{name:G,value:{kind:`text`}}},Column:{status:`supported`,within:[`Columns`,`CardGroup`]},Columns:Ta,CustomCode:{status:`supported`,anyProps:!0},CustomComponent:{status:`supported`,anyProps:!0},Danger:K,DynamicCustomComponent:{status:`supported`,anyProps:!0},Expandable:{status:`supported`,props:{title:G,defaultOpen:W},removedProps:{lazy:{note:`It is ignored.`,remove:!0},uniqueParamId:{note:`It is ignored.`,remove:!0}}},FileTree:Da,Frame:{status:`supported`,props:{caption:G,hint:G,containerClassName:G},removedProps:{as:{note:`It is ignored.`,remove:!0}}},GitHub:Aa,"GitHub.Repo":Aa,Github:Aa,"Github.Repo":Aa,Heading:{status:`supported`,anyProps:!0},Icon:{status:`supported`,props:Object.assign(Object.assign({},U),{src:G,library:G,color:G,size:G,title:G,"aria-label":G})},Info:K,Latex:{status:`supported`},Link:{status:`supported`,anyProps:!0,props:{iconPosition:H(ia)}},List:{status:`supported`,props:{marker:H(ca),start:{kind:`integer`}}},MDX:{status:`supported`},MDXContentController:{status:`supported`,anyProps:!0},Mermaid:{status:`supported`,props:{chart:G,title:G,actions:G},removedProps:{placement:{note:`It is ignored.`,remove:!0}}},Note:K,OptimizedVideo:{status:`supported`,anyProps:!0},Panel:{status:`supported`,anyProps:!0},Param:{status:`removed`,replacement:`ParamField`,note:`Only its description renders.`},ParamField:{status:`supported`,required:[{props:[`query`,`path`,`body`,`header`],note:`It names the parameter and where it goes; without one the field does not render.`}],props:Object.assign(Object.assign({},Sa),{query:G,path:G,body:G,header:G,placeholder:G,enum:G})},Popup:Ma,PopupContent:Ma,PopupTrigger:Ma,Prompt:{status:`supported`,props:{description:G,actions:G},removedProps:{icon:{note:`It is ignored.`,remove:!0},iconType:{note:`It is ignored.`,remove:!0}}},Quote:{status:`supported`,props:{variant:H(pa),author:G,img:G,icon:G}},RequestExample:{status:`supported`,props:{dropdown:W}},ResponseExample:{status:`supported`,props:{dropdown:W}},ResponseField:{status:`supported`,required:[{props:[`name`],note:`Without it the field does not render.`}],props:Object.assign(Object.assign({},Sa),{name:G})},SnippetGroup:{status:`removed`,replacement:`CodeGroup`,note:`Its code blocks render without the group.`},Step:{status:`supported`,within:[`Steps`],props:Object.assign(Object.assign({},U),{title:G,description:G,stepNumber:G,titleSize:H(fa),noAnchor:W})},Steps:{status:`supported`,children:[`Step`],props:{titleSize:H(fa),variant:H(la),marker:H(ua),line:H(da),background:W,start:{kind:`integer`}}},Tab:{status:`supported`,within:[`Tabs`],required:[{props:[`title`],note:`Without it the tab is labelled "Tab Title".`}],props:Object.assign(Object.assign({},U),{title:G})},Table:{status:`supported`,props:{variant:H(ga),layout:H(_a),"aria-label":G}},"Table.Body":Ca,"Table.Cell":Object.assign(Object.assign({},wa),{props:Object.assign(Object.assign({},wa.props),{variant:H(ya)})}),"Table.Header":Ca,"Table.HeaderCell":wa,"Table.Row":Ca,"Table.RowHeader":wa,Tabs:{status:`supported`,children:[`Tab`],props:{defaultTabIndex:{kind:`integer`,min:0},borderBottom:W,sync:W}},Tile:xa,Tip:Object.assign(Object.assign({},K),{status:`deprecated`,replacement:`Check`}),Tooltip:{status:`supported`,required:[{props:[`tip`,`headline`],note:`Without either one the trigger renders as plain text, with no tooltip.`}],linksOnlyWhole:!0,props:{tip:G,headline:G,triggerAriaLabel:G,iconPosition:H(ia)},removedProps:{cta:{note:ja},href:{note:ja}}},Tree:Da,"Tree.File":Oa,"Tree.Folder":ka,Update:xa,Variation:xa,View:{status:`supported`,required:[{props:[`title`],note:`Without it readers can never pick this view.`}],props:Object.assign(Object.assign({},U),{title:G})},Visibility:{status:`supported`,required:[{props:[`for`],note:`Without it readers see nothing.`}],props:{for:H(ta,{invalid:`Readers see nothing.`})}},Warning:K,ZoomImage:{status:`supported`,anyProps:!0}}),q=e=>{let t=/* @__PURE__ */ new Set;return O(e.tree,`mdxjsEsm`,e=>{for(let n of e.data?.estree?.body??[])if(n.type===`ImportDeclaration`)for(let e of n.specifiers)D(e.local,t);else if(n.type===`ExportNamedDeclaration`){let e=n.declaration;if(e?.type===`VariableDeclaration`)for(let n of e.declarations)D(n.id,t);else e&&D(e.id,t);for(let e of n.specifiers)D(e.local,t),D(e.exported,t)}else if(n.type===`ExportDefaultDeclaration`){let e=n.declaration;(e.type===`FunctionDeclaration`||e.type===`ClassDeclaration`)&&D(e.id,t)}}),t},Pa=e=>(e.tree.children.find(e=>[`yaml`,`toml`].includes(e.type))?.position)?.end.offset??0,Fa=(e,t,n)=>{let r;try{r=be(Ee(e,t))}catch{return}return r.has(n)?`{ ${n} }`:r.has(`default`)?n:void 0},Ia={id:`unknown-component`,group:`content`,severity:`error`,scope:`file`,description:`JSX components that are not built in, imported or exported`,pagesOnly:!0,check:e=>{let t=q(e),n=/* @__PURE__ */ new Set,r=[],i=Pa(e),a=i===0?``:`
|
|
16
|
+
`)]));return{files:t.filter(e=>/\.mdx?$/.test(e)&&Li.has(ne(e))).map(e=>({file:e.replace(/^\//,``),kind:a.has(e)?`snippet`:`page`})),imports:o}}),Bi=e=>{try{let{attributes:t}=ie(e);return t&&typeof t==`object`?Object.assign({},t):{}}catch{return{}}},Vi=/\s*\(\d+:\d+(?:-\d+:\d+)?\)$/,Hi=/* @__PURE__ */ new Set([`unexpected-character`,`unexpected-eof`]),Ui=(e,t,n)=>{let{source:r,ruleId:i}=e??{};return r===`micromark-extension-mdx-jsx`&&typeof i==`string`&&Hi.has(i)&&n?.line!=null&&n.column!=null&&t[Ei(t,n.line,n.column)-1]===`<`},Wi=(e,t=``)=>{let n=e?.reason,r=e instanceof Error?e.message:`could not parse this file`,i=typeof n==`string`?n:r,a=e&&typeof e==`object`?me(e):null,o=Ui(e,t,a)?`; if this < isn't a tag, escape it as \\<`:``;return Object.assign(Object.assign(Object.assign({},a?.line!=null&&{line:a.line}),a?.column!=null&&{column:a.column}),{message:i.replace(Vi,``)+o})},Gi=(e,t)=>Object.assign(Object.assign({},t),{rule:Pi.id,group:Pi.group,severity:Pi.severity,file:e,message:`${t.message} (other checks were skipped for this file)`}),Ki=e=>{try{return ui(e)}catch{return}},qi=(e,t,n,r={})=>{let i=Object.assign({file:e,content:t,baseDir:n,frontmatter:Bi(t)},r),a=Ki(t);if(a)return{context:Object.assign(Object.assign({},i),{tree:a}),approximate:!1};try{return{context:Object.assign(Object.assign({},i),{tree:Ee(t,e)}),approximate:!0}}catch(e){return{error:Wi(e,t)}}},Ji={type:`root`,children:[]},Yi=/\{\{\s*([\w.\-]+)\s*\}\}/g,Xi=(e,t={})=>[...e.matchAll(Yi)].filter(e=>e[1]!==void 0&&t[e[1]]!==void 0).map(e=>({start:e.index,end:e.index+e[0].length,text:b(e[0],t)})),Zi=(e,t,n,r,i)=>{var{edit:a}=n,o=Ii(n,[`edit`]);let s=a&&ki(r,i,a);return Object.assign(Object.assign(Object.assign(Object.assign({},o),Ai(r,i,o)),{rule:e.id,group:e.group,severity:e.severity,file:t}),s&&{fix:Object.assign({file:t},s)})},Qi=(e,{file:t,kind:n},r,i,a,o)=>{let s=n===`snippet`?e.filter(e=>!e.pagesOnly):e,c=s.filter(e=>e.raw),l=s.filter(e=>!e.raw),u=n===`snippet`?Xi(r,o):[],d=Ti(r,u),f={file:t,content:d,baseDir:i,frontmatter:{},tree:Ji,variables:o},p=c.flatMap(e=>e.check(f).map(t=>({rule:e,finding:t}))),m=wi(p.flatMap(({finding:e})=>e.edit?[e.edit]:[])),h=Ti(d,m),g=[{content:r,edits:u},{content:d,edits:m},{content:h,edits:[]}],_=p.map(({rule:e,finding:n})=>Zi(e,t,n,g,1)),v=qi(t,h,i,Object.assign(Object.assign({},a),{variables:o}));if(`error`in v)return _.unshift(Gi(t,Object.assign(Object.assign({},v.error),Ai(g,2,v.error)))),_;for(let e of l)for(let n of e.check(v.context)){let r=v.approximate?Object.assign(Object.assign({},n),{edit:void 0}):n;_.push(Zi(e,t,r,g,2))}return _},$i=e=>Fi(void 0,void 0,void 0,function*(){let t=yield Promise.all(e.files.map(({file:t})=>Mi(t,e.read(t)??``)));return new Set(t.flat())}),ea=(e,t)=>Fi(void 0,void 0,void 0,function*(){let n=new Set(t.filter(e=>e.needsAnchorLinks).map(({id:e})=>e)),r=e.files.filter(({file:t})=>!e.selected||e.selected.has(t)),i=(n,r)=>{let i=e.read(n.file);return i===void 0?[Gi(n.file,{message:`could not read this file`})]:Qi(t,n,i,e.baseDir,r,e.variables)},a=e=>e.some(({rule:e})=>n.has(e)),o={readFile:e.read,themeVersion:e.themeVersion,latex:e.latex},s=r.map(e=>i(e,o));if(!s.some(a))return s.flat();let c=Object.assign(Object.assign({},o),{anchorLinks:yield $i(e)});return r.flatMap((e,t)=>{let n=s[t]??[];return a(n)?i(e,c):n})}),ta=[`humans`,`agents`,`signed-in`,`signed-out`],na={wide:"The page keeps the default width and still hides the table of contents; without `mode` the table of contents shows.",center:"The page keeps the default layout and still hides the table of contents; without `mode` the table of contents shows.",frame:"The page uses the default layout, but its headings still get no anchor ids and no table of contents; without `mode` they do."},ra=[`children`,`className`,`id`,`key`,`style`],ia=[`right`,`left`,`none`],aa=[`grey`,`violet`,`sky`,`teal`,`plum`,`crimson`,`info`,`success`,`warning`,`destructive`],oa=[`inline`,`base`],sa=[`default`,`color`],ca=[`dot`,`number`,`box`],la=[`timeline`,`divided`],ua=[`box`,`circle`,`dot`,`number`],da=[`solid`,`dashed`],fa=[`h2`,`h3`,`h4`],pa=[`rule`,`card`,`plain`],ma=[`background`,`plain`,`separator`],ha=[`compact`,`table`],ga=[`minimal`,`grid`],_a=[`equal`,`auto`],va=[`start`,`center`,`end`],ya=[`subtle`,`strong`],H=(e,{legacy:t={},invalid:n}={})=>Object.assign({values:e,legacy:t},n!==void 0&&{invalid:n}),ba=e=>e,U={icon:{kind:`icon`},iconType:{kind:`iconType`}},W={kind:`flag`},G={kind:`any`},K={status:`supported`,props:U,removedProps:{color:{note:`It is ignored. Style the callout with custom CSS on [data-component-item="alert"].`}}},xa={status:`pending`,anyProps:!0},Sa={type:G,typeHref:G,location:G,default:G,required:W,deprecated:W,hidden:W,pre:G,post:G},Ca={status:`supported`,within:[`Table`],anyProps:!0},wa=Object.assign(Object.assign({},Ca),{props:{align:H(va)}}),Ta={status:`supported`,props:{cols:{kind:`integer`,min:1,max:4},joined:W,variant:H(ma)}},Ea={status:`supported`,props:Object.assign(Object.assign({},U),{filename:G,language:G,lang:G,lines:W,wrap:W,expandable:W,nocopy:W,inline:W})},Da={status:`supported`},Oa={status:`supported`,within:[`Tree`,`FileTree`],props:{name:G,highlight:W}},ka=Object.assign(Object.assign({},Oa),{props:Object.assign(Object.assign({},Oa.props),{defaultOpen:W,openable:W})}),Aa=Object.assign({},xa),ja=`A tooltip holds text only. Put the link in the text next to the tooltip, or make the trigger itself a link.`,Ma={status:`removed`,note:"Written directly, it renders nothing of its own. Remove the tag; `twoslash` code fences still show hovers."},Na=ba({Accordion:{status:`supported`,props:Object.assign(Object.assign({},U),{title:G,description:G,defaultOpen:W})},AccordionGroup:{status:`supported`,children:[`Accordion`]},ApiPlayground:{status:`removed`,note:`Nothing renders in its place. Generate the API playground from OpenAPI or AsyncAPI.`},Badge:{status:`supported`,props:Object.assign(Object.assign({},U),{color:H(aa,{legacy:{gray:`grey`,blue:[`sky`,`info`],green:[`teal`,`success`],orange:`warning`,yellow:`warning`,red:[`crimson`,`destructive`],purple:`violet`,white:null,surface:null,"white-destructive":`destructive`,"surface-destructive":`destructive`}}),size:H(oa,{legacy:{xs:`inline`,sm:`inline`,md:`inline`,lg:`base`}}),type:H(sa)}),removedProps:{shape:{note:`The badge has one shape.`,remove:!0},stroke:{note:`The badge has no outline.`,remove:!0},disabled:{note:`The badge has no disabled state.`,remove:!0}}},Callout:K,Card:{status:`supported`,props:Object.assign(Object.assign({},U),{title:G,color:G,horizontal:W,href:G,img:G,disabled:W,cta:G,variant:H(ma)}),removedProps:{arrow:{note:"The card has no corner icon. Add a `cta` instead: it shows a chevron when the card links within the site."},type:{note:`It is ignored.`,remove:!0}}},CardGroup:Object.assign(Object.assign({},Ta),{status:`deprecated`,replacement:`Columns`}),Check:K,CodeBlock:Ea,CodeGroup:{status:`supported`,props:{dropdown:W,report:W}},Color:{status:`supported`,props:{variant:H(ha)}},"Color.Row":{status:`supported`,within:[`Color`],props:{title:G}},"Color.Item":{status:`supported`,within:[`Color`],required:[{props:[`value`],note:`Without it the item does not render.`}],props:{name:G,value:{kind:`text`}}},Column:{status:`supported`,within:[`Columns`,`CardGroup`]},Columns:Ta,CustomCode:{status:`supported`,anyProps:!0},CustomComponent:{status:`supported`,anyProps:!0},Danger:K,DynamicCustomComponent:{status:`supported`,anyProps:!0},Expandable:{status:`supported`,props:{title:G,defaultOpen:W},removedProps:{lazy:{note:`It is ignored.`,remove:!0},uniqueParamId:{note:`It is ignored.`,remove:!0}}},FileTree:Da,Frame:{status:`supported`,props:{caption:G,hint:G,containerClassName:G},removedProps:{as:{note:`It is ignored.`,remove:!0}}},GitHub:Aa,"GitHub.Repo":Aa,Github:Aa,"Github.Repo":Aa,Heading:{status:`supported`,anyProps:!0},Icon:{status:`supported`,props:Object.assign(Object.assign({},U),{src:G,library:G,color:G,size:G,title:G,"aria-label":G})},Info:K,Latex:{status:`supported`},Link:{status:`supported`,anyProps:!0,props:{iconPosition:H(ia)}},List:{status:`supported`,props:{marker:H(ca),start:{kind:`integer`}}},MDX:{status:`supported`},MDXContentController:{status:`supported`,anyProps:!0},Mermaid:{status:`supported`,props:{chart:G,title:G,actions:G},removedProps:{placement:{note:`It is ignored.`,remove:!0}}},Note:K,OptimizedVideo:{status:`supported`,anyProps:!0},Panel:{status:`supported`,anyProps:!0},Param:{status:`removed`,replacement:`ParamField`,note:`Only its description renders.`},ParamField:{status:`supported`,required:[{props:[`query`,`path`,`body`,`header`],note:`It names the parameter and where it goes; without one the field does not render.`}],props:Object.assign(Object.assign({},Sa),{query:G,path:G,body:G,header:G,placeholder:G,enum:G})},Popup:Ma,PopupContent:Ma,PopupTrigger:Ma,Prompt:{status:`supported`,props:{description:G,actions:G},removedProps:{icon:{note:`It is ignored.`,remove:!0},iconType:{note:`It is ignored.`,remove:!0}}},Quote:{status:`supported`,props:{variant:H(pa),author:G,img:G,icon:G}},RequestExample:{status:`supported`,props:{dropdown:W}},ResponseExample:{status:`supported`,props:{dropdown:W}},ResponseField:{status:`supported`,required:[{props:[`name`],note:`Without it the field does not render.`}],props:Object.assign(Object.assign({},Sa),{name:G})},SnippetGroup:{status:`removed`,replacement:`CodeGroup`,note:`Its code blocks render without the group.`},Step:{status:`supported`,within:[`Steps`],props:Object.assign(Object.assign({},U),{title:G,description:G,stepNumber:G,titleSize:H(fa),noAnchor:W})},Steps:{status:`supported`,children:[`Step`],props:{titleSize:H(fa),variant:H(la),marker:H(ua),line:H(da),background:W,start:{kind:`integer`}}},Tab:{status:`supported`,within:[`Tabs`],required:[{props:[`title`],note:`Without it the tab is labelled "Tab Title".`}],props:Object.assign(Object.assign({},U),{title:G})},Table:{status:`supported`,props:{variant:H(ga),layout:H(_a),"aria-label":G}},"Table.Body":Ca,"Table.Cell":Object.assign(Object.assign({},wa),{props:Object.assign(Object.assign({},wa.props),{variant:H(ya)})}),"Table.Header":Ca,"Table.HeaderCell":wa,"Table.Row":Ca,"Table.RowHeader":wa,Tabs:{status:`supported`,children:[`Tab`],props:{defaultTabIndex:{kind:`integer`,min:0},borderBottom:W,sync:W}},Tile:xa,Tip:Object.assign(Object.assign({},K),{status:`deprecated`,replacement:`Check`}),Tooltip:{status:`supported`,required:[{props:[`tip`,`headline`],note:`Without either one the trigger renders as plain text, with no tooltip.`}],linksOnlyWhole:!0,props:{tip:G,headline:G,triggerAriaLabel:G,iconPosition:H(ia)},removedProps:{cta:{note:ja},href:{note:ja}}},Tree:Da,"Tree.File":Oa,"Tree.Folder":ka,Update:xa,Variation:xa,View:{status:`deprecated`,note:`Use Tabs for alternatives within a section or CodeGroup for code samples.`,required:[{props:[`title`],note:`Without it readers can never pick this view.`}],props:Object.assign(Object.assign({},U),{title:G})},Visibility:{status:`supported`,required:[{props:[`for`],note:`Without it readers see nothing.`}],props:{for:H(ta,{invalid:`Readers see nothing.`})}},Warning:K,ZoomImage:{status:`supported`,anyProps:!0}}),q=e=>{let t=/* @__PURE__ */ new Set;return O(e.tree,`mdxjsEsm`,e=>{for(let n of e.data?.estree?.body??[])if(n.type===`ImportDeclaration`)for(let e of n.specifiers)D(e.local,t);else if(n.type===`ExportNamedDeclaration`){let e=n.declaration;if(e?.type===`VariableDeclaration`)for(let n of e.declarations)D(n.id,t);else e&&D(e.id,t);for(let e of n.specifiers)D(e.local,t),D(e.exported,t)}else if(n.type===`ExportDefaultDeclaration`){let e=n.declaration;(e.type===`FunctionDeclaration`||e.type===`ClassDeclaration`)&&D(e.id,t)}}),t},Pa=e=>(e.tree.children.find(e=>[`yaml`,`toml`].includes(e.type))?.position)?.end.offset??0,Fa=(e,t,n)=>{let r;try{r=be(Ee(e,t))}catch{return}return r.has(n)?`{ ${n} }`:r.has(`default`)?n:void 0},Ia={id:`unknown-component`,group:`content`,severity:`error`,scope:`file`,description:`JSX components that are not built in, imported or exported`,pagesOnly:!0,check:e=>{let t=q(e),n=/* @__PURE__ */ new Set,r=[],i=Pa(e),a=i===0?``:`
|
|
17
17
|
|
|
18
18
|
`,o=/^\n*/.exec(e.content.slice(i))?.[0].length??0,s=`
|
|
19
|
-
`.repeat(Math.max(0,2-o)),c=(o,c)=>{let l=o?.split(`.`)[0];if(!o||!l||!/^[A-Z]/.test(l)||t.has(l)||n.has(o)||Nt(o)||e.themeVersion===2&&Object.prototype.hasOwnProperty.call(Na,o))return;n.add(o);let u=we.map(e=>`snippets/${l}${e}`).find(t=>e.readFile?.call(e,t)!==void 0),d=u&&e.readFile?.call(e,u),f=u&&d!==void 0&&o===l?Fa(d,u,l):void 0;r.push({line:c?.line,column:c?.column,message:`<${o}> is not built in, imported or exported on this page`,edit:f?{start:i,end:i,text:`${a}import ${f} from "/${u}";${s}`}:void 0})},l=(e,t)=>Je(e,/* @__PURE__ */ new Set,{reference:e=>{if(e.type!==`JSXIdentifier`)return;let n=e.loc;c(String(e.name),n?.start??t)}});return O(e.tree,e=>{if(e.type===`mdxJsxFlowElement`||e.type===`mdxJsxTextElement`){c(e.name,e.position?.start);for(let t of e.attributes){let n=t.type===`mdxJsxAttribute`?t.value:t;n&&typeof n==`object`&&l(n.data?.estree,e.position?.start)}}else(e.type===`mdxFlowExpression`||e.type===`mdxTextExpression`)&&l(e.data?.estree,e.position?.start)}),r}},La=Na,Ra=new Set(ra),J=e=>e.type===`mdxJsxFlowElement`||e.type===`mdxJsxTextElement`,Y=e=>e&&Object.prototype.hasOwnProperty.call(La,e)?La[e]:void 0,za=e=>(e.children??[]).flatMap(e=>J(e)&&e.name?[e]:za(e)),Ba=(e,t)=>{for(let n=e.length-1;n>=0;n--){let r=e[n];if(r!==void 0&&t(r))return n}return-1},Va=e=>e?.split(`.`)[0]??``,X=(e,t)=>{let n=q(e),r=(e,i,a)=>{let o=i;if(J(e)){let r=n.has(Va(e.name))?void 0:Y(e.name);r&&t(e,r,i,a),o=[...i,e]}let s=[...a,e];for(let t of e.children??[])r(t,o,s)};r(e.tree,[],[])},Ha=e=>e.data?.estree,Ua=e=>{let t=/* @__PURE__ */ new Set,n=e=>{if(Array.isArray(e)){for(let t of e)n(t);return}if(typeof e!=`object`||!e)return;let{type:r,name:i}=e;if(r===`JSXClosingElement`){let e=i;for(;e?.type===`JSXMemberExpression`;)e=e.object;t.add(e)}for(let[t,r]of Object.entries(e))t!==`loc`&&t!==`range`&&typeof r==`object`&&n(r)};return n(e),t},Wa=(e,t)=>{let n=q(e),r=e=>{let r=Ua(e);Je(e,/* @__PURE__ */ new Set,{reference:e=>{if(e.type!==`JSXIdentifier`||r.has(e))return;let i=String(e.name),a=n.has(i)?void 0:Y(i),o=e.loc?.start;a&&t({name:i,spec:a,position:o?{line:o.line,column:o.column+1}:{}})}})},i=e=>{if(J(e)){let i=n.has(Va(e.name))?void 0:Y(e.name);i&&e.name&&t({name:e.name,spec:i,position:Q(e),element:e});for(let t of e.attributes){let e=t.type===`mdxJsxAttribute`?t.value:t;e&&typeof e==`object`&&r(Ha(e))}}else(e.type===`mdxFlowExpression`||e.type===`mdxTextExpression`)&&r(Ha(e));for(let t of e.children??[])i(t)};i(e.tree)},Z=(e,t)=>Object.assign(Object.assign({},e),{scope:`file`,group:`content`,severity:`warning`,theme:2,check:e=>{let n=[];return t(e,e=>n.push(e)),n}}),Q=e=>({line:e.position?.start.line,column:e.position?.start.column}),Ga=e=>e.map(e=>`"${e}"`).join(`, `),Ka=e=>e.map(e=>`<${e}>`).join(` or `),qa=(e,t)=>{let n=e.toLowerCase(),r=t.toLowerCase(),i=Array.from({length:n.length+1},(e,t)=>Array.from({length:r.length+1},(e,n)=>t===0?n:n===0?t:0)),a=(e,t)=>i[e]?.[t]??0;for(let e=1;e<=n.length;e++)for(let t=1;t<=r.length;t++){let o=n[e-1]===r[t-1]?0:1,s=Math.min(a(e-1,t)+1,a(e,t-1)+1,a(e-1,t-1)+o);e>1&&t>1&&n[e-1]===r[t-2]&&n[e-2]===r[t-1]&&(s=Math.min(s,a(e-2,t-2)+1));let c=i[e];c&&(c[t]=s)}return a(n.length,r.length)},Ja=(e,t)=>{let n=Math.max(1,Math.floor(e.length/3));return t.map(t=>({candidate:t,score:qa(e,t)})).filter(({score:e})=>e<=n).sort((e,t)=>e.score-t.score)[0]?.candidate},Ya=(e,t)=>{let n=Ja(e,t);return n?` Did you mean "${n}"?`:``},Xa=e=>{if(e!==null)return typeof e==`string`?`"${e}"`:Ga(e).replace(/, (?=[^,]*$)/,` or `)},Za=e=>e.attributes.filter(e=>e.type===`mdxJsxAttribute`),Qa=/[^\s=/>{}"']+/y,$a=e=>e.attributes.flatMap(e=>{let t=e.type===`mdxJsxAttribute`?e.value:e,n=t&&typeof t==`object`?Ha(t):void 0;return typeof n?.start==`number`&&typeof n.end==`number`?[{start:n.start,end:n.end}]:[]}),eo=(e,t,n)=>{let r=/* @__PURE__ */ new Map,i=t=>{let r=n.find(({start:e})=>e===t+1);if(!r)return;let i=r.end;for(;i<e.length&&/[\s>]/.test(e[i]??``);)i++;return e[i]===`}`?i+1:void 0},a=t,o=()=>{for(;a<e.length&&/\s/.test(e[a]??``);)a++};for(;;){o();let t=e[a];if(t===void 0||t===`>`||t===`/`)break;if(t===`{`){let e=i(a);if(e===void 0)break;a=e;continue}Qa.lastIndex=a;let n=Qa.exec(e)?.[0];if(!n)break;let s=a;a+=n.length;let c=a;if(o(),e[a]===`=`){a++,o();let t=e[a];if(t===`"`||t===`'`){let n=e.indexOf(t,a+1);a=n===-1?e.length:n+1}else if(t===`{`){let e=i(a);if(e===void 0)break;a=e}}else a=c;r.set(n,[...r.get(n)??[],{start:s,end:a}])}return r},to=(e,t)=>{let n=Za(t),r=t.position?.start.offset;if(r===void 0||!t.name)return n.map(e=>({attribute:e}));let{content:i}=e,a=eo(i,r+t.name.length+1,$a(t)),o=/* @__PURE__ */ new Map;return n.map(e=>{let t=o.get(e.name)??0;o.set(e.name,t+1);let n=a.get(e.name)?.[t];return n?Object.assign(Object.assign({attribute:e},n),{source:i.slice(n.start,n.end)}):{attribute:e}})},no=(e,t,n)=>t===void 0?Q(n):V(e.content,t),ro={known:!1},io=e=>{let t=e;if(t.type===`Literal`)return{known:!0,value:t.value};if(t.type===`TemplateLiteral`&&t.expressions?.length===0)return{known:!0,value:(t.quasis?.[0])?.value.cooked};if(t.type===`UnaryExpression`&&t.operator===`-`){let e=io(t.argument);return e.known&&typeof e.value==`number`?{known:!0,value:-e.value}:ro}return ro},ao=e=>{let{value:t}=e;if(typeof t!=`object`||!t)return;let[n]=Ha(t)?.body??[];return n?.type===`ExpressionStatement`?n.expression:void 0},oo=e=>{let{value:t}=e;return t==null?{known:!0,value:!0}:typeof t==`string`?{known:!0,value:t}:io(ao(e))},so=e=>{let t=oo(e);if(!t.known)return;let{value:n}=t;return typeof n==`string`||typeof n==`number`?String(n):void 0},co=(e,t)=>{let n=`values`in e||e.kind===`integer`||e.kind===`iconType`,r=oo(t);return n&&r.known&&typeof r.value==`boolean`?String(r.value):void 0},lo=e=>{let t=ao(e)?.type;return t===`ObjectExpression`||t===`ArrayExpression`},uo=e=>e===``||e===!1||e==null,fo=e=>{let t=oo(e);return!t.known||!uo(t.value)},po=({start:e,end:t},n)=>e===void 0||t===void 0?void 0:{start:e,end:t,text:n},mo=(e,{start:t,end:n})=>{if(t===void 0||n===void 0)return;let r=t;for(;r>0&&/[ \t]/.test(e.content[r-1]??``);)r--;return{start:r,end:n,text:``}},ho=e=>e.replace(/\./g,`\\.`),go=(e,t,n)=>{let r=t.position?.start.offset,i=t.position?.end.offset,a=t.name;if(r===void 0||i===void 0||!a)return;let o=e.content.slice(r,i),s=ho(a),c=RegExp(`^<\\s*${s}(?![\\w.:-])`).exec(o);if(!c)return;let l=RegExp(`</\\s*${s}\\s*>$`).exec(o);if(l||o.endsWith(`/>`))return{start:r,end:i,text:`<${n}${o.slice(c[0].length,l?l.index:o.length)}${l?`</${n}>`:``}`}},_o=Z({id:`removed-component`,description:`Components that no longer render`},(e,t)=>Wa(e,({name:e,spec:n,position:r})=>{if(n.status!==`removed`)return;let i=n.replacement?` Use <${n.replacement}> instead.`:``;t(Object.assign(Object.assign({},r),{message:`<${e}> is removed. ${n.note??``}${i}`.trim()}))})),vo=Z({id:`deprecated-component`,description:`Components that still render but have a replacement`},(e,t)=>{let n=q(e);Wa(e,({name:r,spec:i,position:a,element:o})=>{let{replacement:s}=i;if(i.status!==`deprecated`||!s)return;let c=n.has(s);t(Object.assign(Object.assign({},a),{message:c?`<${r}> is deprecated. Use the built-in <${s}>, which takes the same props; this page declares its own <${s}>, so rename that first.`:`<${r}> is deprecated. Use <${s}>, which takes the same props.`,edit:o&&!c?go(e,o,s):void 0}))})}),yo=Z({id:`pending-component`,description:`Components that do not render yet`},(e,t)=>Wa(e,({name:e,spec:n,position:r})=>{n.status===`pending`&&t(Object.assign(Object.assign({},r),{message:`<${e}> is not supported yet. It renders only its content, without its own styling.`}))})),bo=Z({id:`removed-prop`,description:`Props that are no longer read`},(e,t)=>X(e,(n,r)=>{for(let i of to(e,n)){let{attribute:a}=i,o=r.removedProps?.[a.name];if(o===void 0)continue;let s=o.remove?` Remove the prop.`:``;t(Object.assign(Object.assign({},no(e,i.start,n)),{message:`\`${a.name}\` on <${n.name}> is removed. ${o.note}${s}`,edit:o.remove?mo(e,i):void 0}))}})),xo=Z({id:`unknown-prop`,description:`Props a component does not take`},(e,t)=>X(e,(n,r)=>{if(r.anyProps||r.status===`removed`||r.status===`pending`)return;let i=Object.keys(r.props??{});for(let a of to(e,n)){let{name:o}=a.attribute;if(Ra.has(o)||i.includes(o)||r.removedProps?.[o]!==void 0||o.startsWith(`data-`)||o.startsWith(`aria-`))continue;let s=i.length>0?` It takes ${Ga(i)}.`:` It takes no props.`;t(Object.assign(Object.assign({},no(e,a.start,n)),{message:`<${n.name}> has no \`${o}\` prop, so it is ignored.${Ya(o,i)}${s}`}))}})),So=(e,t)=>Object.prototype.hasOwnProperty.call(e.legacy,t)?e.legacy[t]:void 0,Co=(e,t,n,r)=>{let i=`\`${t.source??`${t.attribute.name}="${r}"`}\` on <${e.name}>`;if(`values`in n){if(n.values.includes(r))return;let e=So(n,r);if(e!==void 0){let t=Xa(e);return{message:t?`${i} is an old value. Use ${t}.`:`${i} is an old value with no replacement. Remove it to get the default.`}}return{message:`${i} is not a supported value${n.invalid?`. ${n.invalid}`:`, so the default is used.`}${Ya(r,n.values)} Allowed: ${Ga(n.values)}.`}}if(n.kind===`iconType`)return Le.includes(r)?void 0:{message:`${i} is not an icon type, so the icon is not drawn.${Ya(r,Le)} Allowed: ${Ga(Le)}.`};if(n.kind===`integer`){let e=Number(r);return Number.isInteger(e)&&(n.min===void 0||e>=n.min)&&(n.max===void 0||e<=n.max)?void 0:{message:`${i} must be a whole number${n.min!==void 0&&n.max!==void 0?` from ${n.min} to ${n.max}`:n.min===void 0?``:` of at least ${n.min}`}.`}}},wo=Z({id:`invalid-value`,description:`Prop values a component does not support`},(e,t)=>X(e,(n,r)=>{for(let i of to(e,n)){let{attribute:a}=i,o=r.props?.[a.name];if(o&&`kind`in o&&o.kind===`text`){let r=oo(a);(lo(a)||r.known&&typeof r.value!=`string`)&&t(Object.assign(Object.assign({},no(e,i.start,n)),{message:`\`${i.source??a.name}\` on <${n.name}> must be one plain string. Any other value does not render.`}));continue}if(!o)continue;let s=so(a)??co(o,a);if(s===void 0)continue;let c=Co(n,i,o,s);if(!c)continue;let l=`values`in o?So(o,s):void 0;t(Object.assign(Object.assign(Object.assign({},no(e,i.start,n)),c),{edit:typeof l==`string`?po(i,`${a.name}="${l}"`):void 0}))}})),To=e=>e.type===`text`&&!e.value?.trim(),Eo=e=>J(e)&&!e.name||e.type===`paragraph`&&e.children.every(e=>To(e)||e.type===`mdxJsxTextElement`||e.type===`mdxTextExpression`),Do=Z({id:`component-placement`,description:`Components used outside the component they belong in`,pagesOnly:!0},(e,t)=>X(e,(e,n,r,i)=>{let{within:a}=n;if(!a)return;let o=Ba(i,e=>J(e)&&a.includes(e.name??``)),s=i[o];if(!s||!J(s)){t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> only works inside ${Ka(a)}. Here it renders without the layout that component gives it.`}));return}if(!(Y(s.name)?.children)?.includes(e.name??``))return;let c=i.slice(o+1).find(e=>!Eo(e));if(!c)return;let l=J(c)?`<${c.name}>`:`a ${c.type}`;t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> must be a direct child of <${s.name}>; only a fragment may wrap it. Here it is inside ${l}, so <${s.name}> drops it.`}))})),Oo=Z({id:`dropped-child`,description:`Children a component does not render`},(e,t)=>{let n=q(e);X(e,(e,r)=>{if(r.children)for(let i of za(e)){let a=i.name??``;r.children.includes(a)||!Y(a)||n.has(Va(a))||t(Object.assign(Object.assign({},Q(i)),{message:`<${e.name}> holds only ${Ka(r.children)}. This <${a}> is dropped.`}))}})}),ko=e=>e.map(e=>`\`${e}\``).join(` or `),Ao=Z({id:`missing-prop`,description:`Props a component needs to render its main part`},(e,t)=>X(e,(e,n)=>{let{attributes:r}=e,i=e=>{let t=Ba(r,t=>t.type===`mdxJsxAttribute`&&t.name===e),n=r.slice(t+1).some(({type:e})=>e===`mdxJsxExpressionAttribute`),i=r[t];return n||i?.type===`mdxJsxAttribute`&&fo(i)};for(let{props:r,note:a}of n.required??[])r.some(i)||t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> needs ${ko(r)}. ${a}`}))})),jo=e=>{let t=/* @__PURE__ */ new Set,n=e=>{e.type===`definition`&&t.add(String(e.identifier).toLowerCase());for(let t of e.children??[])n(t)};return n(e),t},Mo=(e,t)=>e.type===`link`||e.type===`linkReference`&&t.has(String(e.identifier).toLowerCase())||J(e)&&(e.name===`a`||e.name===`Link`||e.name===`button`),No=(e,t)=>Mo(e,t)||(e.children??[]).some(e=>No(e,t)),Po=e=>e.flatMap(e=>e.type===`paragraph`?Po(e.children):e.type===`text`&&!e.value?.trim()?[]:[e]),Fo=[_o,vo,yo,bo,xo,wo,Ao,Do,Oo,Z({id:`nested-link`,description:`Links inside a component that only works when the link is its whole content`},(e,t)=>{let n=jo(e.tree);X(e,(e,r)=>{if(!r.linksOnlyWhole)return;let i=Po(e.children),[a]=i;i.length===1&&a&&Mo(a,n)||i.some(e=>No(e,n))&&t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> around text that contains a link shows no tooltip. Make the whole trigger the link, or move the link out of it.`}))})}),Z({id:`removed-page-mode`,description:`Page modes that no longer exist`,pagesOnly:!0},(e,t)=>{let{mode:n}=e.frontmatter,r=na;if(typeof n!=`string`||!Object.prototype.hasOwnProperty.call(r,n))return;let i=e.content.search(/^mode\s*:/m);t(Object.assign(Object.assign({},i===-1?{}:V(e.content,i)),{message:`\`mode: ${n}\` in the frontmatter is deprecated. ${r[n]} Use custom CSS for a different layout.`}))})],Io=e=>`type`in e&&e.type===`JSXOpeningElement`&&`name`in e&&typeof e.name==`object`&&e.name!==null&&`name`in e.name&&e.name.name===`Latex`,Lo=e=>Array.isArray(e)?e.some(Lo):typeof e!=`object`||!e?!1:Io(e)?!0:Object.entries(e).some(([e,t])=>e!==`loc`&&e!==`range`&&typeof t==`object`&&Lo(t)),Ro=e=>typeof e==`object`&&e&&`data`in e&&typeof e.data==`object`&&e.data!==null&&`estree`in e.data?e.data.estree:void 0,zo=e=>{if(e.type===`math`||e.type===`inlineMath`)return!0;if(e.type===`mdxFlowExpression`||e.type===`mdxTextExpression`)return Lo(Ro(e));if(e.type!==`mdxJsxFlowElement`&&e.type!==`mdxJsxTextElement`)return!1;if(`name`in e&&e.name===`Latex`)return!0;let t=`attributes`in e?e.attributes:void 0;return Array.isArray(t)&&t.some(e=>Lo(Ro(e))||typeof e==`object`&&!!e&&`value`in e&&Lo(Ro(e.value)))},Bo={id:`latex-disabled`,group:`content`,severity:`warning`,theme:2,scope:`file`,description:`math on a site whose docs.json turns LaTeX off`,check:({tree:e,content:t,latex:n})=>{if(n!==!1)return[];let r=[];return O(e,e=>{if(r.length>0)return!1;zo(e)&&(e.type!==`inlineMath`||!rt(e,t)&&!nt(e.value))&&r.push({line:e.position?.start.line,column:e.position?.start.column,message:`This page uses LaTeX math, but docs.json sets "styling": { "latex": false }, so it shows as plain text. Set "latex" to true to render it.`})}),r}};var Vo=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const Ho=({styling:e})=>{let t=e&&typeof e==`object`&&`latex`in e?e.latex:void 0;return typeof t==`boolean`?t:void 0},Uo=e=>{try{let t=JSON.parse(e);return t&&typeof t==`object`?t:{}}catch{return{}}},Wo=Ce,Go=({theme:e,themeVersion:t})=>{let n=Wo[typeof e==`string`?e:`mint`]??1;return typeof t==`number`&&Number.isInteger(t)&&t>=1&&t<=n?t:1},Ko=e=>ut.existsSync(M.join(e,`docs.json`))?`docs.json`:`mint.json`,qo=e=>{try{return Go(Uo(ut.readFileSync(M.join(e,Ko(e)),`utf-8`)))}catch{return Go({})}},Jo=(e,t)=>Vo(void 0,[e,t],void 0,function*(e,{selected:t,localSchema:n}){let{files:r,imports:i}=yield zi(e),a=/* @__PURE__ */ new Map,o=Ko(e),s=t=>{if(!a.has(t))try{a.set(t,ut.readFileSync(M.join(e,t),`utf-8`))}catch{a.set(t,void 0)}return a.get(t)},c=Uo(s(o)??``);return{baseDir:e,files:r,imports:i,selected:t,configFile:o,variables:c.variables&&typeof c.variables==`object`?c.variables:void 0,themeVersion:Go(c),latex:Ho(c),localSchema:n,read:s,locate:(e,t)=>{let n=s(e)??``,r=t?n.indexOf(t):-1;return r===-1?{}:V(n,r)}}});var $=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const Yo=M.join(pt.homedir(),`.mintlify`,`diagnostics`),Xo=(e,t=Yo)=>{let n=M.resolve(e),r=mt(`sha256`).update(n).digest(`hex`).slice(0,12),i=M.basename(n).replace(/[^\w.-]+/g,`-`)||`site`;return M.join(t,`${i}-${r}.json`)},Zo=/\.mdx?$/,Qo=e=>ue(M.extname(e).slice(1)),$o=/* @__PURE__ */ new Set([`docs.json`,`mint.json`,`.mintignore`]),es=(e,t)=>`${e} ${t}${e===1?``:`s`}`,ts=({rule:e,message:t})=>`${e}:${t}`,ns=[...Fo,Bo],rs=new Set(ns.map(({id:e})=>e)),is=e=>e.filter(({rule:e})=>rs.has(e)),as=(e,t)=>{let n=/* @__PURE__ */ new Map;for(let t of e)n.set(ts(t),(n.get(ts(t))??0)+1);return t.filter(e=>{let t=n.get(ts(e))??0;return n.set(ts(e),t-1),t<=0})},os=e=>{let t=e.line?`:${e.line}${e.column?`:${e.column}`:``}`:``;return`${e.file}${t} ${e.rule} ${e.message}`},ss=e=>[...e].sort((e,t)=>(e.line??0)-(t.line??0)||(e.column??0)-(t.column??0)),cs=e=>{let t=/* @__PURE__ */ new Map;for(let n of e)t.set(n.file,[...t.get(n.file)??[],n]);return t},ls=(e,t,n)=>n===void 0?``:Ri(t,se(n,M.join(e,t))),us=e=>{let t=/* @__PURE__ */ new Map;return{read:n=>{if(!t.has(n))try{t.set(n,dt(M.join(e,n),`utf-8`))}catch{t.set(n,void 0)}return t.get(n)},forget:e=>t.delete(e)}},ds=(e,...t)=>$(void 0,[e,...t],void 0,function*(e,{reportDir:t}={}){let i=Xo(e,t),o,s=us(e),c=/* @__PURE__ */ new Map,u,f,h=Promise.resolve(),g=/* @__PURE__ */ new Map,_=/* @__PURE__ */ new Map,v=()=>[...c.values()].flat(),ee=()=>$(void 0,void 0,void 0,function*(){let e=v(),t={version:1,updatedAt:(/* @__PURE__ */ new Date()).toISOString(),summary:{warnings:e.length,files:c.size,fixable:e.filter(({fix:e})=>e).length},diagnostics:e};yield ht.mkdir(M.dirname(i),{recursive:!0});let n=`${i}.${process.pid}.tmp`;yield ht.writeFile(n,`${JSON.stringify(t,null,2)}\n`),yield ht.rename(n,i)}),y=()=>{let e=v().length,t=e===0?void 0:(0,xn.jsx)(p,{message:`${es(e,`content warning`)} in ${es(c.size,`file`)}. Run \`mint validate\` to list them, or read ${i}.`});f&&t?n(f,t):t?m(t):f&&r(f),f=t},te=e=>{h=h.then(e).catch(()=>void 0)},b=(e,t)=>{clearTimeout(g.get(e)),g.set(e,setTimeout(()=>{g.delete(e),te(t)},150))},ne=()=>$(void 0,void 0,void 0,function*(){let t=us(e),n=yield Jo(e,{localSchema:!1});return{site:Object.assign(Object.assign({},n),{read:t.read}),reader:t}}),x=(e,t)=>$(void 0,void 0,void 0,function*(){let n=c.get(t)??[],r=e.files.some(e=>e.file===t)?ss(is(yield ea(Object.assign(Object.assign({},e),{selected:/* @__PURE__ */ new Set([t])}),ns))):[];return r.length>0?c.set(t,r):c.delete(t),as(n,r)}),S=e=>new Map(e.files.map(({file:e,kind:t})=>[e,t])),re=t=>$(void 0,void 0,void 0,function*(){if(!o)return;let n=!1;for(let[r,i]of t){s.forget(r),ls(e,r,s.read(r))!==(o.imports?.get(r)??``)&&(n=!0);let t=Zo.test(r)&&!o.files.some(e=>e.file===r);(i||t)&&(n=!0)}let r=new Set([...t.keys()].filter(e=>Zo.test(e)));if(n){let e=S(o),n;try{n=yield ne()}catch(e){for(let[e,n]of t)_.set(e,(_.get(e)??!1)||n);throw e}o=n.site,s=n.reader;for(let[t,n]of S(o))e.get(t)!==n&&r.add(t);for(let t of e.keys())o.files.some(e=>e.file===t)||r.add(t)}let i=o,a=(yield Promise.all([...r].map(e=>x(i,e)))).flat();for(let e of a.slice(0,5))l((0,xn.jsx)(p,{message:os(e)}));a.length>5&&l((0,xn.jsx)(p,{message:`${es(a.length-5,`more content warning`)}`})),y(),yield ee()}),C=()=>{let e=new Map(_);return _.clear(),re(e)},w=()=>$(void 0,void 0,void 0,function*(){if(qo(e)!==2){yield u?.close(),u=void 0,o=void 0,c=/* @__PURE__ */ new Map,y(),yield ht.rm(i,{force:!0});return}let t=yield he(e),n=yield it(e,{ignored:d(e,t),onEvent:(t,n)=>{let r=M.relative(e,n).split(M.sep).join(`/`);Qo(r)&&(_.set(r,(_.get(r)??!1)||t!==`change`),b(`files`,C))},onError:()=>void 0}),r;try{r=yield ne()}catch(e){throw yield n.close(),e}yield u?.close(),u=n,o=r.site,s=r.reader,c=cs(ss(is(yield ea(o,ns)))),y(),yield ee()}),T=a(()=>{f&&m(f)}),E=ft(e,(e,t)=>{t&&$o.has(String(t))&&b(`config`,w)});return E.on(`error`,()=>void 0),te(w),yield h,{close:()=>$(void 0,void 0,void 0,function*(){E.close(),T();for(let e of g.values())clearTimeout(e);yield h,yield u?.close()})}});export{Bn as C,vr as S,wi as _,Bo as a,Zr as b,ea as c,Ti as d,li as f,Ci as g,gi as h,Jo as i,qi as l,_i as m,Xo as n,Fo as o,Ni as p,ds as r,Ia as s,Yo as t,Pi as u,V as v,Ur as x,ri as y};
|
|
19
|
+
`.repeat(Math.max(0,2-o)),c=(o,c)=>{let l=o?.split(`.`)[0];if(!o||!l||!/^[A-Z]/.test(l)||t.has(l)||n.has(o)||Nt(o)||e.themeVersion===2&&Object.prototype.hasOwnProperty.call(Na,o))return;n.add(o);let u=we.map(e=>`snippets/${l}${e}`).find(t=>e.readFile?.call(e,t)!==void 0),d=u&&e.readFile?.call(e,u),f=u&&d!==void 0&&o===l?Fa(d,u,l):void 0;r.push({line:c?.line,column:c?.column,message:`<${o}> is not built in, imported or exported on this page`,edit:f?{start:i,end:i,text:`${a}import ${f} from "/${u}";${s}`}:void 0})},l=(e,t)=>Je(e,/* @__PURE__ */ new Set,{reference:e=>{if(e.type!==`JSXIdentifier`)return;let n=e.loc;c(String(e.name),n?.start??t)}});return O(e.tree,e=>{if(e.type===`mdxJsxFlowElement`||e.type===`mdxJsxTextElement`){c(e.name,e.position?.start);for(let t of e.attributes){let n=t.type===`mdxJsxAttribute`?t.value:t;n&&typeof n==`object`&&l(n.data?.estree,e.position?.start)}}else(e.type===`mdxFlowExpression`||e.type===`mdxTextExpression`)&&l(e.data?.estree,e.position?.start)}),r}},La=Na,Ra=new Set(ra),J=e=>e.type===`mdxJsxFlowElement`||e.type===`mdxJsxTextElement`,Y=e=>e&&Object.prototype.hasOwnProperty.call(La,e)?La[e]:void 0,za=e=>(e.children??[]).flatMap(e=>J(e)&&e.name?[e]:za(e)),Ba=(e,t)=>{for(let n=e.length-1;n>=0;n--){let r=e[n];if(r!==void 0&&t(r))return n}return-1},Va=e=>e?.split(`.`)[0]??``,X=(e,t)=>{let n=q(e),r=(e,i,a)=>{let o=i;if(J(e)){let r=n.has(Va(e.name))?void 0:Y(e.name);r&&t(e,r,i,a),o=[...i,e]}let s=[...a,e];for(let t of e.children??[])r(t,o,s)};r(e.tree,[],[])},Ha=e=>e.data?.estree,Ua=e=>{let t=/* @__PURE__ */ new Set,n=e=>{if(Array.isArray(e)){for(let t of e)n(t);return}if(typeof e!=`object`||!e)return;let{type:r,name:i}=e;if(r===`JSXClosingElement`){let e=i;for(;e?.type===`JSXMemberExpression`;)e=e.object;t.add(e)}for(let[t,r]of Object.entries(e))t!==`loc`&&t!==`range`&&typeof r==`object`&&n(r)};return n(e),t},Wa=(e,t)=>{let n=q(e),r=e=>{let r=Ua(e);Je(e,/* @__PURE__ */ new Set,{reference:e=>{if(e.type!==`JSXIdentifier`||r.has(e))return;let i=String(e.name),a=n.has(i)?void 0:Y(i),o=e.loc?.start;a&&t({name:i,spec:a,position:o?{line:o.line,column:o.column+1}:{}})}})},i=e=>{if(J(e)){let i=n.has(Va(e.name))?void 0:Y(e.name);i&&e.name&&t({name:e.name,spec:i,position:Q(e),element:e});for(let t of e.attributes){let e=t.type===`mdxJsxAttribute`?t.value:t;e&&typeof e==`object`&&r(Ha(e))}}else(e.type===`mdxFlowExpression`||e.type===`mdxTextExpression`)&&r(Ha(e));for(let t of e.children??[])i(t)};i(e.tree)},Z=(e,t)=>Object.assign(Object.assign({},e),{scope:`file`,group:`content`,severity:`warning`,theme:2,check:e=>{let n=[];return t(e,e=>n.push(e)),n}}),Q=e=>({line:e.position?.start.line,column:e.position?.start.column}),Ga=e=>e.map(e=>`"${e}"`).join(`, `),Ka=e=>e.map(e=>`<${e}>`).join(` or `),qa=(e,t)=>{let n=e.toLowerCase(),r=t.toLowerCase(),i=Array.from({length:n.length+1},(e,t)=>Array.from({length:r.length+1},(e,n)=>t===0?n:n===0?t:0)),a=(e,t)=>i[e]?.[t]??0;for(let e=1;e<=n.length;e++)for(let t=1;t<=r.length;t++){let o=n[e-1]===r[t-1]?0:1,s=Math.min(a(e-1,t)+1,a(e,t-1)+1,a(e-1,t-1)+o);e>1&&t>1&&n[e-1]===r[t-2]&&n[e-2]===r[t-1]&&(s=Math.min(s,a(e-2,t-2)+1));let c=i[e];c&&(c[t]=s)}return a(n.length,r.length)},Ja=(e,t)=>{let n=Math.max(1,Math.floor(e.length/3));return t.map(t=>({candidate:t,score:qa(e,t)})).filter(({score:e})=>e<=n).sort((e,t)=>e.score-t.score)[0]?.candidate},Ya=(e,t)=>{let n=Ja(e,t);return n?` Did you mean "${n}"?`:``},Xa=e=>{if(e!==null)return typeof e==`string`?`"${e}"`:Ga(e).replace(/, (?=[^,]*$)/,` or `)},Za=e=>e.attributes.filter(e=>e.type===`mdxJsxAttribute`),Qa=/[^\s=/>{}"']+/y,$a=e=>e.attributes.flatMap(e=>{let t=e.type===`mdxJsxAttribute`?e.value:e,n=t&&typeof t==`object`?Ha(t):void 0;return typeof n?.start==`number`&&typeof n.end==`number`?[{start:n.start,end:n.end}]:[]}),eo=(e,t,n)=>{let r=/* @__PURE__ */ new Map,i=t=>{let r=n.find(({start:e})=>e===t+1);if(!r)return;let i=r.end;for(;i<e.length&&/[\s>]/.test(e[i]??``);)i++;return e[i]===`}`?i+1:void 0},a=t,o=()=>{for(;a<e.length&&/\s/.test(e[a]??``);)a++};for(;;){o();let t=e[a];if(t===void 0||t===`>`||t===`/`)break;if(t===`{`){let e=i(a);if(e===void 0)break;a=e;continue}Qa.lastIndex=a;let n=Qa.exec(e)?.[0];if(!n)break;let s=a;a+=n.length;let c=a;if(o(),e[a]===`=`){a++,o();let t=e[a];if(t===`"`||t===`'`){let n=e.indexOf(t,a+1);a=n===-1?e.length:n+1}else if(t===`{`){let e=i(a);if(e===void 0)break;a=e}}else a=c;r.set(n,[...r.get(n)??[],{start:s,end:a}])}return r},to=(e,t)=>{let n=Za(t),r=t.position?.start.offset;if(r===void 0||!t.name)return n.map(e=>({attribute:e}));let{content:i}=e,a=eo(i,r+t.name.length+1,$a(t)),o=/* @__PURE__ */ new Map;return n.map(e=>{let t=o.get(e.name)??0;o.set(e.name,t+1);let n=a.get(e.name)?.[t];return n?Object.assign(Object.assign({attribute:e},n),{source:i.slice(n.start,n.end)}):{attribute:e}})},no=(e,t,n)=>t===void 0?Q(n):V(e.content,t),ro={known:!1},io=e=>{let t=e;if(t.type===`Literal`)return{known:!0,value:t.value};if(t.type===`TemplateLiteral`&&t.expressions?.length===0)return{known:!0,value:(t.quasis?.[0])?.value.cooked};if(t.type===`UnaryExpression`&&t.operator===`-`){let e=io(t.argument);return e.known&&typeof e.value==`number`?{known:!0,value:-e.value}:ro}return ro},ao=e=>{let{value:t}=e;if(typeof t!=`object`||!t)return;let[n]=Ha(t)?.body??[];return n?.type===`ExpressionStatement`?n.expression:void 0},oo=e=>{let{value:t}=e;return t==null?{known:!0,value:!0}:typeof t==`string`?{known:!0,value:t}:io(ao(e))},so=e=>{let t=oo(e);if(!t.known)return;let{value:n}=t;return typeof n==`string`||typeof n==`number`?String(n):void 0},co=(e,t)=>{let n=`values`in e||e.kind===`integer`||e.kind===`iconType`,r=oo(t);return n&&r.known&&typeof r.value==`boolean`?String(r.value):void 0},lo=e=>{let t=ao(e)?.type;return t===`ObjectExpression`||t===`ArrayExpression`},uo=e=>e===``||e===!1||e==null,fo=e=>{let t=oo(e);return!t.known||!uo(t.value)},po=({start:e,end:t},n)=>e===void 0||t===void 0?void 0:{start:e,end:t,text:n},mo=(e,{start:t,end:n})=>{if(t===void 0||n===void 0)return;let r=t;for(;r>0&&/[ \t]/.test(e.content[r-1]??``);)r--;return{start:r,end:n,text:``}},ho=e=>e.replace(/\./g,`\\.`),go=(e,t,n)=>{let r=t.position?.start.offset,i=t.position?.end.offset,a=t.name;if(r===void 0||i===void 0||!a)return;let o=e.content.slice(r,i),s=ho(a),c=RegExp(`^<\\s*${s}(?![\\w.:-])`).exec(o);if(!c)return;let l=RegExp(`</\\s*${s}\\s*>$`).exec(o);if(l||o.endsWith(`/>`))return{start:r,end:i,text:`<${n}${o.slice(c[0].length,l?l.index:o.length)}${l?`</${n}>`:``}`}},_o=Z({id:`removed-component`,description:`Components that no longer render`},(e,t)=>Wa(e,({name:e,spec:n,position:r})=>{if(n.status!==`removed`)return;let i=n.replacement?` Use <${n.replacement}> instead.`:``;t(Object.assign(Object.assign({},r),{message:`<${e}> is removed. ${n.note??``}${i}`.trim()}))})),vo=Z({id:`deprecated-component`,description:`Components that still render but are on their way out`},(e,t)=>{let n=q(e);Wa(e,({name:r,spec:i,position:a,element:o})=>{let{replacement:s}=i;if(i.status!==`deprecated`)return;if(!s){t(Object.assign(Object.assign({},a),{message:`<${r}> is deprecated. ${i.note??``}`.trim()}));return}let c=n.has(s);t(Object.assign(Object.assign({},a),{message:c?`<${r}> is deprecated. Use the built-in <${s}>, which takes the same props; this page declares its own <${s}>, so rename that first.`:`<${r}> is deprecated. Use <${s}>, which takes the same props.`,edit:o&&!c?go(e,o,s):void 0}))})}),yo=Z({id:`pending-component`,description:`Components that do not render yet`},(e,t)=>Wa(e,({name:e,spec:n,position:r})=>{n.status===`pending`&&t(Object.assign(Object.assign({},r),{message:`<${e}> is not supported yet. It renders only its content, without its own styling.`}))})),bo=Z({id:`removed-prop`,description:`Props that are no longer read`},(e,t)=>X(e,(n,r)=>{for(let i of to(e,n)){let{attribute:a}=i,o=r.removedProps?.[a.name];if(o===void 0)continue;let s=o.remove?` Remove the prop.`:``;t(Object.assign(Object.assign({},no(e,i.start,n)),{message:`\`${a.name}\` on <${n.name}> is removed. ${o.note}${s}`,edit:o.remove?mo(e,i):void 0}))}})),xo=Z({id:`unknown-prop`,description:`Props a component does not take`},(e,t)=>X(e,(n,r)=>{if(r.anyProps||r.status===`removed`||r.status===`pending`)return;let i=Object.keys(r.props??{});for(let a of to(e,n)){let{name:o}=a.attribute;if(Ra.has(o)||i.includes(o)||r.removedProps?.[o]!==void 0||o.startsWith(`data-`)||o.startsWith(`aria-`))continue;let s=i.length>0?` It takes ${Ga(i)}.`:` It takes no props.`;t(Object.assign(Object.assign({},no(e,a.start,n)),{message:`<${n.name}> has no \`${o}\` prop, so it is ignored.${Ya(o,i)}${s}`}))}})),So=(e,t)=>Object.prototype.hasOwnProperty.call(e.legacy,t)?e.legacy[t]:void 0,Co=(e,t,n,r)=>{let i=`\`${t.source??`${t.attribute.name}="${r}"`}\` on <${e.name}>`;if(`values`in n){if(n.values.includes(r))return;let e=So(n,r);if(e!==void 0){let t=Xa(e);return{message:t?`${i} is an old value. Use ${t}.`:`${i} is an old value with no replacement. Remove it to get the default.`}}return{message:`${i} is not a supported value${n.invalid?`. ${n.invalid}`:`, so the default is used.`}${Ya(r,n.values)} Allowed: ${Ga(n.values)}.`}}if(n.kind===`iconType`)return Le.includes(r)?void 0:{message:`${i} is not an icon type, so the icon is not drawn.${Ya(r,Le)} Allowed: ${Ga(Le)}.`};if(n.kind===`integer`){let e=Number(r);return Number.isInteger(e)&&(n.min===void 0||e>=n.min)&&(n.max===void 0||e<=n.max)?void 0:{message:`${i} must be a whole number${n.min!==void 0&&n.max!==void 0?` from ${n.min} to ${n.max}`:n.min===void 0?``:` of at least ${n.min}`}.`}}},wo=Z({id:`invalid-value`,description:`Prop values a component does not support`},(e,t)=>X(e,(n,r)=>{for(let i of to(e,n)){let{attribute:a}=i,o=r.props?.[a.name];if(o&&`kind`in o&&o.kind===`text`){let r=oo(a);(lo(a)||r.known&&typeof r.value!=`string`)&&t(Object.assign(Object.assign({},no(e,i.start,n)),{message:`\`${i.source??a.name}\` on <${n.name}> must be one plain string. Any other value does not render.`}));continue}if(!o)continue;let s=so(a)??co(o,a);if(s===void 0)continue;let c=Co(n,i,o,s);if(!c)continue;let l=`values`in o?So(o,s):void 0;t(Object.assign(Object.assign(Object.assign({},no(e,i.start,n)),c),{edit:typeof l==`string`?po(i,`${a.name}="${l}"`):void 0}))}})),To=e=>e.type===`text`&&!e.value?.trim(),Eo=e=>J(e)&&!e.name||e.type===`paragraph`&&e.children.every(e=>To(e)||e.type===`mdxJsxTextElement`||e.type===`mdxTextExpression`),Do=Z({id:`component-placement`,description:`Components used outside the component they belong in`,pagesOnly:!0},(e,t)=>X(e,(e,n,r,i)=>{let{within:a}=n;if(!a)return;let o=Ba(i,e=>J(e)&&a.includes(e.name??``)),s=i[o];if(!s||!J(s)){t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> only works inside ${Ka(a)}. Here it renders without the layout that component gives it.`}));return}if(!(Y(s.name)?.children)?.includes(e.name??``))return;let c=i.slice(o+1).find(e=>!Eo(e));if(!c)return;let l=J(c)?`<${c.name}>`:`a ${c.type}`;t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> must be a direct child of <${s.name}>; only a fragment may wrap it. Here it is inside ${l}, so <${s.name}> drops it.`}))})),Oo=Z({id:`dropped-child`,description:`Children a component does not render`},(e,t)=>{let n=q(e);X(e,(e,r)=>{if(r.children)for(let i of za(e)){let a=i.name??``;r.children.includes(a)||!Y(a)||n.has(Va(a))||t(Object.assign(Object.assign({},Q(i)),{message:`<${e.name}> holds only ${Ka(r.children)}. This <${a}> is dropped.`}))}})}),ko=e=>e.map(e=>`\`${e}\``).join(` or `),Ao=Z({id:`missing-prop`,description:`Props a component needs to render its main part`},(e,t)=>X(e,(e,n)=>{let{attributes:r}=e,i=e=>{let t=Ba(r,t=>t.type===`mdxJsxAttribute`&&t.name===e),n=r.slice(t+1).some(({type:e})=>e===`mdxJsxExpressionAttribute`),i=r[t];return n||i?.type===`mdxJsxAttribute`&&fo(i)};for(let{props:r,note:a}of n.required??[])r.some(i)||t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> needs ${ko(r)}. ${a}`}))})),jo=e=>{let t=/* @__PURE__ */ new Set,n=e=>{e.type===`definition`&&t.add(String(e.identifier).toLowerCase());for(let t of e.children??[])n(t)};return n(e),t},Mo=(e,t)=>e.type===`link`||e.type===`linkReference`&&t.has(String(e.identifier).toLowerCase())||J(e)&&(e.name===`a`||e.name===`Link`||e.name===`button`),No=(e,t)=>Mo(e,t)||(e.children??[]).some(e=>No(e,t)),Po=e=>e.flatMap(e=>e.type===`paragraph`?Po(e.children):e.type===`text`&&!e.value?.trim()?[]:[e]),Fo=[_o,vo,yo,bo,xo,wo,Ao,Do,Oo,Z({id:`nested-link`,description:`Links inside a component that only works when the link is its whole content`},(e,t)=>{let n=jo(e.tree);X(e,(e,r)=>{if(!r.linksOnlyWhole)return;let i=Po(e.children),[a]=i;i.length===1&&a&&Mo(a,n)||i.some(e=>No(e,n))&&t(Object.assign(Object.assign({},Q(e)),{message:`<${e.name}> around text that contains a link shows no tooltip. Make the whole trigger the link, or move the link out of it.`}))})}),Z({id:`removed-page-mode`,description:`Page modes that no longer exist`,pagesOnly:!0},(e,t)=>{let{mode:n}=e.frontmatter,r=na;if(typeof n!=`string`||!Object.prototype.hasOwnProperty.call(r,n))return;let i=e.content.search(/^mode\s*:/m);t(Object.assign(Object.assign({},i===-1?{}:V(e.content,i)),{message:`\`mode: ${n}\` in the frontmatter is deprecated. ${r[n]} Use custom CSS for a different layout.`}))})],Io=e=>`type`in e&&e.type===`JSXOpeningElement`&&`name`in e&&typeof e.name==`object`&&e.name!==null&&`name`in e.name&&e.name.name===`Latex`,Lo=e=>Array.isArray(e)?e.some(Lo):typeof e!=`object`||!e?!1:Io(e)?!0:Object.entries(e).some(([e,t])=>e!==`loc`&&e!==`range`&&typeof t==`object`&&Lo(t)),Ro=e=>typeof e==`object`&&e&&`data`in e&&typeof e.data==`object`&&e.data!==null&&`estree`in e.data?e.data.estree:void 0,zo=e=>{if(e.type===`math`||e.type===`inlineMath`)return!0;if(e.type===`mdxFlowExpression`||e.type===`mdxTextExpression`)return Lo(Ro(e));if(e.type!==`mdxJsxFlowElement`&&e.type!==`mdxJsxTextElement`)return!1;if(`name`in e&&e.name===`Latex`)return!0;let t=`attributes`in e?e.attributes:void 0;return Array.isArray(t)&&t.some(e=>Lo(Ro(e))||typeof e==`object`&&!!e&&`value`in e&&Lo(Ro(e.value)))},Bo={id:`latex-disabled`,group:`content`,severity:`warning`,theme:2,scope:`file`,description:`math on a site whose docs.json turns LaTeX off`,check:({tree:e,content:t,latex:n})=>{if(n!==!1)return[];let r=[];return O(e,e=>{if(r.length>0)return!1;zo(e)&&(e.type!==`inlineMath`||!rt(e,t)&&!nt(e.value))&&r.push({line:e.position?.start.line,column:e.position?.start.column,message:`This page uses LaTeX math, but docs.json sets "styling": { "latex": false }, so it shows as plain text. Set "latex" to true to render it.`})}),r}};var Vo=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const Ho=({styling:e})=>{let t=e&&typeof e==`object`&&`latex`in e?e.latex:void 0;return typeof t==`boolean`?t:void 0},Uo=e=>{try{let t=JSON.parse(e);return t&&typeof t==`object`?t:{}}catch{return{}}},Wo=Ce,Go=({theme:e,themeVersion:t})=>{let n=Wo[typeof e==`string`?e:`mint`]??1;return typeof t==`number`&&Number.isInteger(t)&&t>=1&&t<=n?t:1},Ko=e=>ut.existsSync(M.join(e,`docs.json`))?`docs.json`:`mint.json`,qo=e=>{try{return Go(Uo(ut.readFileSync(M.join(e,Ko(e)),`utf-8`)))}catch{return Go({})}},Jo=(e,t)=>Vo(void 0,[e,t],void 0,function*(e,{selected:t,localSchema:n}){let{files:r,imports:i}=yield zi(e),a=/* @__PURE__ */ new Map,o=Ko(e),s=t=>{if(!a.has(t))try{a.set(t,ut.readFileSync(M.join(e,t),`utf-8`))}catch{a.set(t,void 0)}return a.get(t)},c=Uo(s(o)??``);return{baseDir:e,files:r,imports:i,selected:t,configFile:o,variables:c.variables&&typeof c.variables==`object`?c.variables:void 0,themeVersion:Go(c),latex:Ho(c),localSchema:n,read:s,locate:(e,t)=>{let n=s(e)??``,r=t?n.indexOf(t):-1;return r===-1?{}:V(n,r)}}});var $=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const Yo=M.join(pt.homedir(),`.mintlify`,`diagnostics`),Xo=(e,t=Yo)=>{let n=M.resolve(e),r=mt(`sha256`).update(n).digest(`hex`).slice(0,12),i=M.basename(n).replace(/[^\w.-]+/g,`-`)||`site`;return M.join(t,`${i}-${r}.json`)},Zo=/\.mdx?$/,Qo=e=>ue(M.extname(e).slice(1)),$o=/* @__PURE__ */ new Set([`docs.json`,`mint.json`,`.mintignore`]),es=(e,t)=>`${e} ${t}${e===1?``:`s`}`,ts=({rule:e,message:t})=>`${e}:${t}`,ns=[...Fo,Bo],rs=new Set(ns.map(({id:e})=>e)),is=e=>e.filter(({rule:e})=>rs.has(e)),as=(e,t)=>{let n=/* @__PURE__ */ new Map;for(let t of e)n.set(ts(t),(n.get(ts(t))??0)+1);return t.filter(e=>{let t=n.get(ts(e))??0;return n.set(ts(e),t-1),t<=0})},os=e=>{let t=e.line?`:${e.line}${e.column?`:${e.column}`:``}`:``;return`${e.file}${t} ${e.rule} ${e.message}`},ss=e=>[...e].sort((e,t)=>(e.line??0)-(t.line??0)||(e.column??0)-(t.column??0)),cs=e=>{let t=/* @__PURE__ */ new Map;for(let n of e)t.set(n.file,[...t.get(n.file)??[],n]);return t},ls=(e,t,n)=>n===void 0?``:Ri(t,se(n,M.join(e,t))),us=e=>{let t=/* @__PURE__ */ new Map;return{read:n=>{if(!t.has(n))try{t.set(n,dt(M.join(e,n),`utf-8`))}catch{t.set(n,void 0)}return t.get(n)},forget:e=>t.delete(e)}},ds=(e,...t)=>$(void 0,[e,...t],void 0,function*(e,{reportDir:t}={}){let i=Xo(e,t),o,s=us(e),c=/* @__PURE__ */ new Map,u,f,h=Promise.resolve(),g=/* @__PURE__ */ new Map,_=/* @__PURE__ */ new Map,v=()=>[...c.values()].flat(),ee=()=>$(void 0,void 0,void 0,function*(){let e=v(),t={version:1,updatedAt:(/* @__PURE__ */ new Date()).toISOString(),summary:{warnings:e.length,files:c.size,fixable:e.filter(({fix:e})=>e).length},diagnostics:e};yield ht.mkdir(M.dirname(i),{recursive:!0});let n=`${i}.${process.pid}.tmp`;yield ht.writeFile(n,`${JSON.stringify(t,null,2)}\n`),yield ht.rename(n,i)}),y=()=>{let e=v().length,t=e===0?void 0:(0,xn.jsx)(p,{message:`${es(e,`content warning`)} in ${es(c.size,`file`)}. Run \`mint validate\` to list them, or read ${i}.`});f&&t?n(f,t):t?m(t):f&&r(f),f=t},te=e=>{h=h.then(e).catch(()=>void 0)},b=(e,t)=>{clearTimeout(g.get(e)),g.set(e,setTimeout(()=>{g.delete(e),te(t)},150))},ne=()=>$(void 0,void 0,void 0,function*(){let t=us(e),n=yield Jo(e,{localSchema:!1});return{site:Object.assign(Object.assign({},n),{read:t.read}),reader:t}}),x=(e,t)=>$(void 0,void 0,void 0,function*(){let n=c.get(t)??[],r=e.files.some(e=>e.file===t)?ss(is(yield ea(Object.assign(Object.assign({},e),{selected:/* @__PURE__ */ new Set([t])}),ns))):[];return r.length>0?c.set(t,r):c.delete(t),as(n,r)}),S=e=>new Map(e.files.map(({file:e,kind:t})=>[e,t])),re=t=>$(void 0,void 0,void 0,function*(){if(!o)return;let n=!1;for(let[r,i]of t){s.forget(r),ls(e,r,s.read(r))!==(o.imports?.get(r)??``)&&(n=!0);let t=Zo.test(r)&&!o.files.some(e=>e.file===r);(i||t)&&(n=!0)}let r=new Set([...t.keys()].filter(e=>Zo.test(e)));if(n){let e=S(o),n;try{n=yield ne()}catch(e){for(let[e,n]of t)_.set(e,(_.get(e)??!1)||n);throw e}o=n.site,s=n.reader;for(let[t,n]of S(o))e.get(t)!==n&&r.add(t);for(let t of e.keys())o.files.some(e=>e.file===t)||r.add(t)}let i=o,a=(yield Promise.all([...r].map(e=>x(i,e)))).flat();for(let e of a.slice(0,5))l((0,xn.jsx)(p,{message:os(e)}));a.length>5&&l((0,xn.jsx)(p,{message:`${es(a.length-5,`more content warning`)}`})),y(),yield ee()}),C=()=>{let e=new Map(_);return _.clear(),re(e)},w=()=>$(void 0,void 0,void 0,function*(){if(qo(e)!==2){yield u?.close(),u=void 0,o=void 0,c=/* @__PURE__ */ new Map,y(),yield ht.rm(i,{force:!0});return}let t=yield he(e),n=yield it(e,{ignored:d(e,t),onEvent:(t,n)=>{let r=M.relative(e,n).split(M.sep).join(`/`);Qo(r)&&(_.set(r,(_.get(r)??!1)||t!==`change`),b(`files`,C))},onError:()=>void 0}),r;try{r=yield ne()}catch(e){throw yield n.close(),e}yield u?.close(),u=n,o=r.site,s=r.reader,c=cs(ss(is(yield ea(o,ns)))),y(),yield ee()}),T=a(()=>{f&&m(f)}),E=ft(e,(e,t)=>{t&&$o.has(String(t))&&b(`config`,w)});return E.on(`error`,()=>void 0),te(w),yield h,{close:()=>$(void 0,void 0,void 0,function*(){E.close(),T();for(let e of g.values())clearTimeout(e);yield h,yield u?.close()})}});export{Bn as C,vr as S,wi as _,Bo as a,Zr as b,ea as c,Ti as d,li as f,Ci as g,gi as h,Jo as i,qi as l,_i as m,Xo as n,Fo as o,Ni as p,ds as r,Ia as s,Yo as t,Pi as u,V as v,Ur as x,ri as y};
|
|
@@ -4,4 +4,4 @@ import { dirname as __mintDirname } from 'node:path';
|
|
|
4
4
|
const require = __mintCreateRequire(import.meta.url);
|
|
5
5
|
const __filename = __mintFileURLToPath(import.meta.url);
|
|
6
6
|
const __dirname = __mintDirname(__filename);
|
|
7
|
-
export{t as isMultiRepoDev,n as multiRepoOptions,r as runMultiRepoDev}from"./multi-repo-command-
|
|
7
|
+
export{t as isMultiRepoDev,n as multiRepoOptions,r as runMultiRepoDev}from"./multi-repo-command-CbXq8sCW.js";
|
|
@@ -98,4 +98,4 @@ Please do one of the following:
|
|
|
98
98
|
- Use a different option key
|
|
99
99
|
https://yargs.js.org/docs/#api-reference-version`,void 0,`versionWarning`),I(this,q,`f`).key[e]=!0,t.alias&&this.alias(e,t.alias);let n=t.deprecate||t.deprecated;n&&this.deprecateOption(e,n);let r=t.demand||t.required||t.require;r&&this.demand(e,r),t.demandOption&&this.demandOption(e,typeof t.demandOption==`string`?t.demandOption:void 0),t.conflicts&&this.conflicts(e,t.conflicts),`default`in t&&this.default(e,t.default),t.implies!==void 0&&this.implies(e,t.implies),t.nargs!==void 0&&this.nargs(e,t.nargs),t.config&&this.config(e,t.configParser),t.normalize&&this.normalize(e),t.choices&&this.choices(e,t.choices),t.coerce&&this.coerce(e,t.coerce),t.group&&this.group(e,t.group),(t.boolean||t.type===`boolean`)&&(this.boolean(e),t.alias&&this.boolean(t.alias)),(t.array||t.type===`array`)&&(this.array(e),t.alias&&this.array(t.alias)),(t.number||t.type===`number`)&&(this.number(e),t.alias&&this.number(t.alias)),(t.string||t.type===`string`)&&(this.string(e),t.alias&&this.string(t.alias)),(t.count||t.type===`count`)&&this.count(e),typeof t.global==`boolean`&&this.global(e,t.global),t.defaultDescription&&(I(this,q,`f`).defaultDescription[e]=t.defaultDescription),t.skipValidation&&this.skipValidation(e);let i=t.describe||t.description||t.desc,a=I(this,Z,`f`).getDescriptions();Object.prototype.hasOwnProperty.call(a,e)&&typeof i!=`string`||this.describe(e,i),t.hidden&&this.hide(e),t.requiresArg&&this.requiresArg(e)}return this}options(e,t){return this.option(e,t)}parse(e,t,n){P(`[string|array] [function|boolean|object] [function]`,[e,t,n],arguments.length),this[Ut](),e===void 0&&(e=I(this,Y,`f`)),typeof t==`object`&&(F(this,At,t,`f`),t=n),typeof t==`function`&&(F(this,J,t,`f`),t=!1),t||F(this,Y,e,`f`),I(this,J,`f`)&&F(this,V,!1,`f`);let r=this[vn](e,!!t),i=this.parsed;return I(this,R,`f`).setParsed(this.parsed),N(r)?r.then(e=>(I(this,J,`f`)&&I(this,J,`f`).call(this,I(this,B,`f`),e,I(this,K,`f`)),e)).catch(e=>{throw I(this,J,`f`)&&I(this,J,`f`)(e,this.parsed.argv,I(this,K,`f`)),e}).finally(()=>{this[rn](),this.parsed=i}):(I(this,J,`f`)&&I(this,J,`f`).call(this,I(this,B,`f`),r,I(this,K,`f`)),this[rn](),this.parsed=i,r)}parseAsync(e,t,n){let r=this.parse(e,t,n);return N(r)?r:Promise.resolve(r)}parseSync(e,t,n){let r=this.parse(e,t,n);if(N(r))throw new j(`.parseSync() must not be used with asynchronous builders, handlers, or middleware`);return r}parserConfiguration(e){return P(`<object>`,[e],arguments.length),F(this,kt,e,`f`),this}pkgConf(e,t){P(`<string> [string]`,[e,t],arguments.length);let n=null,r=this[Xt](t||I(this,bt,`f`));return r[e]&&typeof r[e]==`object`&&(n=gt(r[e],t||I(this,bt,`f`),this[Gt]()[`deep-merge-config`]||!1,I(this,X,`f`)),I(this,q,`f`).configObjects=(I(this,q,`f`).configObjects||[]).concat(n)),this}positional(e,t){P(`<string> <object>`,[e,t],arguments.length);let n=[`default`,`defaultDescription`,`implies`,`normalize`,`choices`,`conflicts`,`coerce`,`type`,`describe`,`desc`,`description`,`alias`];t=$e(t,(e,t)=>e===`type`&&![`string`,`number`,`boolean`].includes(t)?!1:n.includes(e));let r=I(this,xt,`f`).fullCommands[I(this,xt,`f`).fullCommands.length-1],i=r?I(this,L,`f`).cmdToParseOptions(r):{array:[],alias:{},default:{},demand:{}};return Pe(i).forEach(n=>{let r=i[n];Array.isArray(r)?r.indexOf(e)!==-1&&(t[n]=!0):r[e]&&!(n in t)&&(t[n]=r[e])}),this.group(e,I(this,Z,`f`).getPositionalGroupName()),this.option(e,t)}recommendCommands(e=!0){return P(`[boolean]`,[e],arguments.length),F(this,Nt,e,`f`),this}required(e,t,n){return this.demand(e,t,n)}require(e,t,n){return this.demand(e,t,n)}requiresArg(e){return P(`<array|string|object> [number]`,[e],arguments.length),typeof e==`string`&&I(this,q,`f`).narg[e]||this[Qt](this.requiresArg.bind(this),`narg`,e,NaN),this}showCompletionScript(e,t){return P(`[string] [string]`,[e,t],arguments.length),e||=this.$0,I(this,Dt,`f`).log(I(this,R,`f`).generateCompletionScript(e,t||I(this,z,`f`)||`completion`)),this}showHelp(e){if(P(`[string|function]`,[e],arguments.length),F(this,W,!0,`f`),!I(this,Z,`f`).hasCachedHelpMessage()){if(!this.parsed){let t=this[vn](I(this,Y,`f`),void 0,void 0,0,!0);if(N(t))return t.then(()=>{I(this,Z,`f`).showHelp(e)}),this}let t=I(this,L,`f`).runDefaultBuilderOn(this);if(N(t))return t.then(()=>{I(this,Z,`f`).showHelp(e)}),this}return I(this,Z,`f`).showHelp(e),this}scriptName(e){return this.customScriptName=!0,this.$0=e,this}showHelpOnFail(e,t){return P(`[boolean|string] [string]`,[e,t],arguments.length),I(this,Z,`f`).showHelpOnFail(e,t),this}showVersion(e){return P(`[string|function]`,[e],arguments.length),I(this,Z,`f`).showVersion(e),this}skipValidation(e){return P(`<array|string>`,[e],arguments.length),this[Zt](`skipValidation`,e),this}strict(e){return P(`[boolean]`,[e],arguments.length),F(this,Pt,e!==!1,`f`),this}strictCommands(e){return P(`[boolean]`,[e],arguments.length),F(this,Ft,e!==!1,`f`),this}strictOptions(e){return P(`[boolean]`,[e],arguments.length),F(this,It,e!==!1,`f`),this}string(e){return P(`<array|string>`,[e],arguments.length),this[Zt](`string`,e),this[xn](e),this}terminalWidth(){return P([],0),I(this,X,`f`).process.stdColumns}updateLocale(e){return this.updateStrings(e)}updateStrings(e){return P(`<object>`,[e],arguments.length),F(this,Ct,!1,`f`),I(this,X,`f`).y18n.updateLocale(e),this}usage(e,t,n,r){if(P(`<string|null|undefined> [string|boolean] [function|object] [function]`,[e,t,n,r],arguments.length),t!==void 0){if(M(e,null,I(this,X,`f`)),(e||``).match(/^\$0( |$)/))return this.command(e,t,n,r);throw new j(`.usage() description must start with $0 if being used as alias for .command()`)}return I(this,Z,`f`).usage(e),this}usageConfiguration(e){return P(`<object>`,[e],arguments.length),F(this,Lt,e,`f`),this}version(e,t,n){let r=`version`;if(P(`[boolean|string] [string] [string]`,[e,t,n],arguments.length),I(this,Q,`f`)&&(this[Vt](I(this,Q,`f`)),I(this,Z,`f`).version(void 0),F(this,Q,null,`f`)),arguments.length===0)n=this[Jt](),e=r;else if(arguments.length===1){if(e===!1)return this;n=e,e=r}else arguments.length===2&&(n=t,t=void 0);return F(this,Q,typeof e==`string`?e:r,`f`),t||=I(this,Z,`f`).deferY18nLookup(`Show version number`),I(this,Z,`f`).version(n||void 0),this.boolean(I(this,Q,`f`)),this.describe(I(this,Q,`f`),t),this}wrap(e){return P(`<number|null|undefined>`,[e],arguments.length),I(this,Z,`f`).wrap(e),this}[(L=/* @__PURE__ */ new WeakMap,bt=/* @__PURE__ */ new WeakMap,xt=/* @__PURE__ */ new WeakMap,R=/* @__PURE__ */ new WeakMap,z=/* @__PURE__ */ new WeakMap,St=/* @__PURE__ */ new WeakMap,B=/* @__PURE__ */ new WeakMap,Ct=/* @__PURE__ */ new WeakMap,wt=/* @__PURE__ */ new WeakMap,V=/* @__PURE__ */ new WeakMap,Tt=/* @__PURE__ */ new WeakMap,H=/* @__PURE__ */ new WeakMap,U=/* @__PURE__ */ new WeakMap,W=/* @__PURE__ */ new WeakMap,G=/* @__PURE__ */ new WeakMap,Et=/* @__PURE__ */ new WeakMap,Dt=/* @__PURE__ */ new WeakMap,K=/* @__PURE__ */ new WeakMap,q=/* @__PURE__ */ new WeakMap,Ot=/* @__PURE__ */ new WeakMap,kt=/* @__PURE__ */ new WeakMap,J=/* @__PURE__ */ new WeakMap,At=/* @__PURE__ */ new WeakMap,jt=/* @__PURE__ */ new WeakMap,Mt=/* @__PURE__ */ new WeakMap,Y=/* @__PURE__ */ new WeakMap,Nt=/* @__PURE__ */ new WeakMap,X=/* @__PURE__ */ new WeakMap,Pt=/* @__PURE__ */ new WeakMap,Ft=/* @__PURE__ */ new WeakMap,It=/* @__PURE__ */ new WeakMap,Z=/* @__PURE__ */ new WeakMap,Lt=/* @__PURE__ */ new WeakMap,Q=/* @__PURE__ */ new WeakMap,$=/* @__PURE__ */ new WeakMap,zt)](e){if(!e._||!e[`--`])return e;e._.push.apply(e._,e[`--`]);try{delete e[`--`]}catch{}return e}[Bt](){return{log:(...e)=>{this[pn]()||console.log(...e),F(this,W,!0,`f`),I(this,K,`f`).length&&F(this,K,I(this,K,`f`)+`
|
|
100
100
|
`,`f`),F(this,K,I(this,K,`f`)+e.join(` `),`f`)},error:(...e)=>{this[pn]()||console.error(...e),F(this,W,!0,`f`),I(this,K,`f`).length&&F(this,K,I(this,K,`f`)+`
|
|
101
|
-
`,`f`),F(this,K,I(this,K,`f`)+e.join(` `),`f`)}}}[Vt](e){Pe(I(this,q,`f`)).forEach(t=>{if((e=>e===`configObjects`)(t))return;let n=I(this,q,`f`)[t];Array.isArray(n)?n.includes(e)&&n.splice(n.indexOf(e),1):typeof n==`object`&&delete n[e]}),delete I(this,Z,`f`).getDescriptions()[e]}[Ht](e,t,n){I(this,wt,`f`)[n]||(I(this,X,`f`).process.emitWarning(e,t),I(this,wt,`f`)[n]=!0)}[Ut](){I(this,Tt,`f`).push({options:I(this,q,`f`),configObjects:I(this,q,`f`).configObjects.slice(0),exitProcess:I(this,V,`f`),groups:I(this,U,`f`),strict:I(this,Pt,`f`),strictCommands:I(this,Ft,`f`),strictOptions:I(this,It,`f`),completionCommand:I(this,z,`f`),output:I(this,K,`f`),exitError:I(this,B,`f`),hasOutput:I(this,W,`f`),parsed:this.parsed,parseFn:I(this,J,`f`),parseContext:I(this,At,`f`)}),I(this,Z,`f`).freeze(),I(this,$,`f`).freeze(),I(this,L,`f`).freeze(),I(this,H,`f`).freeze()}[Wt](){let e=``,t;return t=/\b(node|iojs|electron)(\.exe)?$/.test(I(this,X,`f`).process.argv()[0])?I(this,X,`f`).process.argv().slice(1,2):I(this,X,`f`).process.argv().slice(0,1),e=t.map(e=>{let t=this[gn](I(this,bt,`f`),e);return e.match(/^(\/|([a-zA-Z]:)?\\)/)&&t.length<e.length?t:e}).join(` `).trim(),I(this,X,`f`).getEnv(`_`)&&I(this,X,`f`).getProcessArgvBin()===I(this,X,`f`).getEnv(`_`)&&(e=I(this,X,`f`).getEnv(`_`).replace(`${I(this,X,`f`).path.dirname(I(this,X,`f`).process.execPath())}/`,``)),e}[Gt](){return I(this,kt,`f`)}[Kt](){return I(this,Lt,`f`)}[qt](){if(!I(this,Ct,`f`))return;let e=I(this,X,`f`).getEnv(`LC_ALL`)||I(this,X,`f`).getEnv(`LC_MESSAGES`)||I(this,X,`f`).getEnv(`LANG`)||I(this,X,`f`).getEnv(`LANGUAGE`)||`en_US`;this.locale(e.replace(/[.:].*/,``))}[Jt](){return this[Xt]().version||`unknown`}[Yt](e){let t=e[`--`]?e[`--`]:e._;for(let e=0,n;(n=t[e])!==void 0;e++)I(this,X,`f`).Parser.looksLikeNumber(n)&&Number.isSafeInteger(Math.floor(parseFloat(`${n}`)))&&(t[e]=Number(n));return e}[Xt](e){let t=e||`*`;if(I(this,jt,`f`)[t])return I(this,jt,`f`)[t];let n={};try{let t=e||I(this,X,`f`).mainFilename;!e&&I(this,X,`f`).path.extname(t)&&(t=I(this,X,`f`).path.dirname(t));let r=I(this,X,`f`).findUp(t,(e,t)=>{if(t.includes(`package.json`))return`package.json`});M(r,void 0,I(this,X,`f`)),n=JSON.parse(I(this,X,`f`).readFileSync(r,`utf8`))}catch{}return I(this,jt,`f`)[t]=n||{},I(this,jt,`f`)[t]}[Zt](e,t){t=[].concat(t),t.forEach(t=>{t=this[tn](t),I(this,q,`f`)[e].push(t)})}[Qt](e,t,n,r){this[en](e,t,n,r,(e,t,n)=>{I(this,q,`f`)[e][t]=n})}[$t](e,t,n,r){this[en](e,t,n,r,(e,t,n)=>{I(this,q,`f`)[e][t]=(I(this,q,`f`)[e][t]||[]).concat(n)})}[en](e,t,n,r,i){if(Array.isArray(n))n.forEach(t=>{e(t,r)});else if((e=>typeof e==`object`)(n))for(let t of Pe(n))e(t,n[t]);else i(t,this[tn](n),r)}[tn](e){return e===`__proto__`?`___proto___`:e}[nn](e,t){return this[Qt](this[nn].bind(this),`key`,e,t),this}[rn](){var e,t,n,r,i,a,o,s,c,l,u,d;let f=I(this,Tt,`f`).pop();M(f,void 0,I(this,X,`f`));let p;e=this,t=this,n=this,r=this,i=this,a=this,o=this,s=this,c=this,l=this,u=this,d=this,{options:{set value(t){F(e,q,t,`f`)}}.value,configObjects:p,exitProcess:{set value(e){F(t,V,e,`f`)}}.value,groups:{set value(e){F(n,U,e,`f`)}}.value,output:{set value(e){F(r,K,e,`f`)}}.value,exitError:{set value(e){F(i,B,e,`f`)}}.value,hasOutput:{set value(e){F(a,W,e,`f`)}}.value,parsed:this.parsed,strict:{set value(e){F(o,Pt,e,`f`)}}.value,strictCommands:{set value(e){F(s,Ft,e,`f`)}}.value,strictOptions:{set value(e){F(c,It,e,`f`)}}.value,completionCommand:{set value(e){F(l,z,e,`f`)}}.value,parseFn:{set value(e){F(u,J,e,`f`)}}.value,parseContext:{set value(e){F(d,At,e,`f`)}}.value}=f,I(this,q,`f`).configObjects=p,I(this,Z,`f`).unfreeze(),I(this,$,`f`).unfreeze(),I(this,L,`f`).unfreeze(),I(this,H,`f`).unfreeze()}[an](e,t){return He(t,t=>(e(t),t))}getInternalMethods(){return{getCommandInstance:this[on].bind(this),getContext:this[sn].bind(this),getHasOutput:this[cn].bind(this),getLoggerInstance:this[ln].bind(this),getParseContext:this[un].bind(this),getParserConfiguration:this[Gt].bind(this),getUsageConfiguration:this[Kt].bind(this),getUsageInstance:this[dn].bind(this),getValidationInstance:this[fn].bind(this),hasParseCallback:this[pn].bind(this),isGlobalContext:this[mn].bind(this),postProcess:this[hn].bind(this),reset:this[_n].bind(this),runValidation:this[yn].bind(this),runYargsParserAndExecuteCommands:this[vn].bind(this),setHasOutput:this[bn].bind(this)}}[on](){return I(this,L,`f`)}[sn](){return I(this,xt,`f`)}[cn](){return I(this,W,`f`)}[ln](){return I(this,Dt,`f`)}[un](){return I(this,At,`f`)||{}}[dn](){return I(this,Z,`f`)}[fn](){return I(this,$,`f`)}[pn](){return!!I(this,J,`f`)}[mn](){return I(this,Et,`f`)}[hn](e,t,n,r){return n||N(e)||(t||(e=this[zt](e)),(this[Gt]()[`parse-positional-numbers`]||this[Gt]()[`parse-positional-numbers`]===void 0)&&(e=this[Yt](e)),r&&(e=Ve(e,this,I(this,H,`f`).getMiddleware(),!1))),e}[_n](e={}){F(this,q,I(this,q,`f`)||{},`f`);let t={};t.local=I(this,q,`f`).local||[],t.configObjects=I(this,q,`f`).configObjects||[];let n={};return t.local.forEach(t=>{n[t]=!0,(e[t]||[]).forEach(e=>{n[e]=!0})}),Object.assign(I(this,Mt,`f`),Object.keys(I(this,U,`f`)).reduce((e,t)=>{let r=I(this,U,`f`)[t].filter(e=>!(e in n));return r.length>0&&(e[t]=r),e},{})),F(this,U,{},`f`),[`array`,`boolean`,`string`,`skipValidation`,`count`,`normalize`,`number`,`hiddenOptions`].forEach(e=>{t[e]=(I(this,q,`f`)[e]||[]).filter(e=>!n[e])}),[`narg`,`key`,`alias`,`default`,`defaultDescription`,`config`,`choices`,`demandedOptions`,`demandedCommands`,`deprecatedOptions`].forEach(e=>{t[e]=$e(I(this,q,`f`)[e],e=>!n[e])}),t.envPrefix=I(this,q,`f`).envPrefix,F(this,q,t,`f`),F(this,Z,I(this,Z,`f`)?I(this,Z,`f`).reset(n):nt(this,I(this,X,`f`)),`f`),F(this,$,I(this,$,`f`)?I(this,$,`f`).reset(n):pt(this,I(this,Z,`f`),I(this,X,`f`)),`f`),F(this,L,I(this,L,`f`)?I(this,L,`f`).reset():qe(I(this,Z,`f`),I(this,$,`f`),I(this,H,`f`),I(this,X,`f`)),`f`),I(this,R,`f`)||F(this,R,ct(this,I(this,Z,`f`),I(this,L,`f`),I(this,X,`f`)),`f`),I(this,H,`f`).reset(),F(this,z,null,`f`),F(this,K,``,`f`),F(this,B,null,`f`),F(this,W,!1,`f`),this.parsed=!1,this}[gn](e,t){return I(this,X,`f`).path.relative(e,t)}[vn](e,t,n,r=0,i=!1){let a=!!n||i;e||=I(this,Y,`f`),I(this,q,`f`).__=I(this,X,`f`).y18n.__,I(this,q,`f`).configuration=this[Gt]();let o=!!I(this,q,`f`).configuration[`populate--`],s=Object.assign({},I(this,q,`f`).configuration,{"populate--":!0}),c=I(this,X,`f`).Parser.detailed(e,Object.assign({},I(this,q,`f`),{configuration:{"parse-positional-numbers":!1,...s}})),l=Object.assign(c.argv,I(this,At,`f`)),u,d=c.aliases,f=!1,p=!1;Object.keys(l).forEach(e=>{e===I(this,G,`f`)&&l[e]?f=!0:e===I(this,Q,`f`)&&l[e]&&(p=!0)}),l.$0=this.$0,this.parsed=c,r===0&&I(this,Z,`f`).clearCachedHelpMessage();try{if(this[qt](),t)return this[hn](l,o,!!n,!1);I(this,G,`f`)&&[I(this,G,`f`)].concat(d[I(this,G,`f`)]||[]).filter(e=>e.length>1).includes(``+l._[l._.length-1])&&(l._.pop(),f=!0),F(this,Et,!1,`f`);let s=I(this,L,`f`).getCommands(),m=I(this,R,`f`).completionKey in l,h=f||m||i;if(l._.length){if(s.length){let e;for(let t=r||0,a;l._[t]!==void 0;t++){if(a=String(l._[t]),s.includes(a)&&a!==I(this,z,`f`)){let e=I(this,L,`f`).runCommand(a,this,c,t+1,i,f||p||i);return this[hn](e,o,!!n,!1)}if(!e&&a!==I(this,z,`f`)){e=a;break}}!I(this,L,`f`).hasDefaultCommand()&&I(this,Nt,`f`)&&e&&!h&&I(this,$,`f`).recommendCommands(e,s)}I(this,z,`f`)&&l._.includes(I(this,z,`f`))&&!m&&(I(this,V,`f`)&&et(!0),this.showCompletionScript(),this.exit(0))}if(I(this,L,`f`).hasDefaultCommand()&&!h){let e=I(this,L,`f`).runCommand(null,this,c,0,i,f||p||i);return this[hn](e,o,!!n,!1)}if(m){I(this,V,`f`)&&et(!0),e=[].concat(e);let t=e.slice(e.indexOf(`--${I(this,R,`f`).completionKey}`)+1);return I(this,R,`f`).getCompletion(t,(e,t)=>{if(e)throw new j(e.message);(t||[]).forEach(e=>{I(this,Dt,`f`).log(e)}),this.exit(0)}),this[hn](l,!o,!!n,!1)}if(I(this,W,`f`)||(f?(I(this,V,`f`)&&et(!0),a=!0,this.showHelp(`log`),this.exit(0)):p&&(I(this,V,`f`)&&et(!0),a=!0,I(this,Z,`f`).showVersion(`log`),this.exit(0))),!a&&I(this,q,`f`).skipValidation.length>0&&(a=Object.keys(l).some(e=>I(this,q,`f`).skipValidation.indexOf(e)>=0&&l[e]===!0)),!a){if(c.error)throw new j(c.error.message);if(!m){let e=this[yn](d,{},c.error);n||(u=Ve(l,this,I(this,H,`f`).getMiddleware(),!0)),u=this[an](e,u??l),N(u)&&!n&&(u=u.then(()=>Ve(l,this,I(this,H,`f`).getMiddleware(),!1)))}}}catch(e){if(e instanceof j)I(this,Z,`f`).fail(e.message,e);else throw e}return this[hn](u??l,o,!!n,!0)}[yn](e,t,n,r){let i={...this.getDemandedOptions()};return a=>{if(n)throw new j(n.message);I(this,$,`f`).nonOptionCount(a),I(this,$,`f`).requiredArguments(a,i);let o=!1;I(this,Ft,`f`)&&(o=I(this,$,`f`).unknownCommands(a)),I(this,Pt,`f`)&&!o?I(this,$,`f`).unknownArguments(a,e,t,!!r):I(this,It,`f`)&&I(this,$,`f`).unknownArguments(a,e,{},!1,!1),I(this,$,`f`).limitedChoices(a),I(this,$,`f`).implications(a),I(this,$,`f`).conflicting(a)}}[bn](){F(this,W,!0,`f`)}[xn](e){if(typeof e==`string`)I(this,q,`f`).key[e]=!0;else for(let t of e)I(this,q,`f`).key[t]=!0}};function Cn(e){return!!e&&typeof e.getInternalMethods==`function`}const wn=Rt(Me);var Tn=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const En=e=>e.option(`multi-repo`,{type:`boolean`,description:`Compose local repositories; set up a workspace if no config exists`}).option(`workspace`,{type:`string`,requiresArg:!0,description:`Path to a local multi-repo config (implies --multi-repo)`}).option(`setup`,{type:`boolean`,description:`Review saved setup (requires --multi-repo or --workspace); preserve cache`}).option(`non-interactive`,{type:`boolean`,description:`Never prompt (requires --multi-repo or --workspace and a valid config)`}).wrap(null).epilog(n),Dn=(e,t)=>En(wn(e).scriptName(t).usage(`$0 dev --multi-repo [options]`)).option(`port`,{type:`number`,default:3e3,description:`Local preview port`}).option(`open`,{type:`boolean`,default:!1,description:`Open the preview in a browser`}).option(`client-version`,{type:`string`,hidden:!0}).option(`local-client-version`,{type:`string`,hidden:!0}).option(`local-schema`,{type:`boolean`,hidden:!0}).option(`classic`,{type:`boolean`,default:!1,description:`Preview with the classic client`}).option(`beta`,{type:`boolean`,default:!1,hidden:!0}).option(`groups`,{type:`array`,description:`Mock user groups`}).option(`signed-in`,{type:`boolean`,default:!1}).option(`disable-openapi`,{type:`boolean`,default:!1}).option(`disable-prefetch`,{type:`boolean`,default:!1}).option(`host`,{type:`boolean`,default:!1}).option(`telemetry`,{alias:`t`,type:`boolean`}).help().alias(`help`,`h`).exitProcess(!1).strictOptions().fail(e=>{throw Error(e)});function On(e){return Dn(e,`mint`).help(!1).version(!1).strictOptions(!1).parseSync()._[0]===`dev`}function kn(e,n,r,i){return Tn(this,void 0,void 0,function*(){let a=Dn(e,n).parseSync();if(a.help||a.version)return;if(a.workspace!==void 0&&!a.workspace.trim())throw Error(`--workspace requires a config path.`);if(!a[`multi-repo`]&&!a.workspace)throw Error(`Use --multi-repo with --setup or --non-interactive.`);if(!Number.isInteger(a.port)||a.port<1||a.port>65535)throw Error(`--port must be an integer from 1 to 65535.`);let{resolveWorkspace:o}=yield import(`./multi-repo-setup-C0jIlw0Q.js`),s;console.log(`Checking multi-repo configuration…`);let c=yield o({cwd:process.cwd(),workspace:a.workspace,setup:a.setup,nonInteractive:a[`non-interactive`],onSaved:e=>{s=`Saved ${e}. Keep machine-specific paths out of Git; add the local config to .gitignore.`}}),{prepareMultiRepoPreview:l}=yield import(`./multi-repo-preview-cTNsNnFK.js`),f=performance.now(),p=0,m=yield l(c,!0,{compositionCacheDirectory:d.join(u.homedir(),`.mintlify`,`multi-repo-compositions`),onProgress:e=>{e.stage===`cold`&&console.log(`Preparing the workspace for the first time. Large repositories can take around two minutes; later runs reuse the saved workspace.`),e.stage===`cached`&&console.log(`Checking the saved workspace for changes…`),e.stage===`watching`&&console.log(`Starting repository watchers…`),e.stage===`files`&&performance.now()-p>=1e3&&(p=performance.now(),console.log(`Checked ${e.files.toLocaleString()} files…`))}});r(m.close);let h=m.getStats();console.log(`Workspace ready in ${((performance.now()-f)/1e3).toFixed(1)}s: ${h?.reusedFiles??0} files reused. Starting preview…`);for(let e of m.sources)console.log(` ${e.repo} → /${e.mountPath}`);if(process.chdir(m.directory),typeof a.telemetry==`boolean`){let{setTelemetryEnabled:e}=yield import(`./config-BaacO1QY.js`);yield e(a.telemetry)}let[{dev:g,Logs:ee},{render:_},{createElement:te}]=yield Promise.all([import(`./dist-BIlW23vs.js`),import(`./build-B-oc3MuD.js`),import(`./react-CA8V--cT.js`).then(e=>/* @__PURE__ */ t(e.default,1))]);if(_(te(ee)),a.classic!==!0){let{watchComponentUsage:e}=yield import(`./live-DD6wtFs0.js`);e(m.directory).catch(()=>void 0)}yield g(Object.assign(Object.assign({},a),{groups:a.groups??(a[`signed-in`]?[]:void 0),packageName:n,previewReadyMessage:s,onExit:i}))})}export{A as a,wn as i,En as n,kn as r,On as t};
|
|
101
|
+
`,`f`),F(this,K,I(this,K,`f`)+e.join(` `),`f`)}}}[Vt](e){Pe(I(this,q,`f`)).forEach(t=>{if((e=>e===`configObjects`)(t))return;let n=I(this,q,`f`)[t];Array.isArray(n)?n.includes(e)&&n.splice(n.indexOf(e),1):typeof n==`object`&&delete n[e]}),delete I(this,Z,`f`).getDescriptions()[e]}[Ht](e,t,n){I(this,wt,`f`)[n]||(I(this,X,`f`).process.emitWarning(e,t),I(this,wt,`f`)[n]=!0)}[Ut](){I(this,Tt,`f`).push({options:I(this,q,`f`),configObjects:I(this,q,`f`).configObjects.slice(0),exitProcess:I(this,V,`f`),groups:I(this,U,`f`),strict:I(this,Pt,`f`),strictCommands:I(this,Ft,`f`),strictOptions:I(this,It,`f`),completionCommand:I(this,z,`f`),output:I(this,K,`f`),exitError:I(this,B,`f`),hasOutput:I(this,W,`f`),parsed:this.parsed,parseFn:I(this,J,`f`),parseContext:I(this,At,`f`)}),I(this,Z,`f`).freeze(),I(this,$,`f`).freeze(),I(this,L,`f`).freeze(),I(this,H,`f`).freeze()}[Wt](){let e=``,t;return t=/\b(node|iojs|electron)(\.exe)?$/.test(I(this,X,`f`).process.argv()[0])?I(this,X,`f`).process.argv().slice(1,2):I(this,X,`f`).process.argv().slice(0,1),e=t.map(e=>{let t=this[gn](I(this,bt,`f`),e);return e.match(/^(\/|([a-zA-Z]:)?\\)/)&&t.length<e.length?t:e}).join(` `).trim(),I(this,X,`f`).getEnv(`_`)&&I(this,X,`f`).getProcessArgvBin()===I(this,X,`f`).getEnv(`_`)&&(e=I(this,X,`f`).getEnv(`_`).replace(`${I(this,X,`f`).path.dirname(I(this,X,`f`).process.execPath())}/`,``)),e}[Gt](){return I(this,kt,`f`)}[Kt](){return I(this,Lt,`f`)}[qt](){if(!I(this,Ct,`f`))return;let e=I(this,X,`f`).getEnv(`LC_ALL`)||I(this,X,`f`).getEnv(`LC_MESSAGES`)||I(this,X,`f`).getEnv(`LANG`)||I(this,X,`f`).getEnv(`LANGUAGE`)||`en_US`;this.locale(e.replace(/[.:].*/,``))}[Jt](){return this[Xt]().version||`unknown`}[Yt](e){let t=e[`--`]?e[`--`]:e._;for(let e=0,n;(n=t[e])!==void 0;e++)I(this,X,`f`).Parser.looksLikeNumber(n)&&Number.isSafeInteger(Math.floor(parseFloat(`${n}`)))&&(t[e]=Number(n));return e}[Xt](e){let t=e||`*`;if(I(this,jt,`f`)[t])return I(this,jt,`f`)[t];let n={};try{let t=e||I(this,X,`f`).mainFilename;!e&&I(this,X,`f`).path.extname(t)&&(t=I(this,X,`f`).path.dirname(t));let r=I(this,X,`f`).findUp(t,(e,t)=>{if(t.includes(`package.json`))return`package.json`});M(r,void 0,I(this,X,`f`)),n=JSON.parse(I(this,X,`f`).readFileSync(r,`utf8`))}catch{}return I(this,jt,`f`)[t]=n||{},I(this,jt,`f`)[t]}[Zt](e,t){t=[].concat(t),t.forEach(t=>{t=this[tn](t),I(this,q,`f`)[e].push(t)})}[Qt](e,t,n,r){this[en](e,t,n,r,(e,t,n)=>{I(this,q,`f`)[e][t]=n})}[$t](e,t,n,r){this[en](e,t,n,r,(e,t,n)=>{I(this,q,`f`)[e][t]=(I(this,q,`f`)[e][t]||[]).concat(n)})}[en](e,t,n,r,i){if(Array.isArray(n))n.forEach(t=>{e(t,r)});else if((e=>typeof e==`object`)(n))for(let t of Pe(n))e(t,n[t]);else i(t,this[tn](n),r)}[tn](e){return e===`__proto__`?`___proto___`:e}[nn](e,t){return this[Qt](this[nn].bind(this),`key`,e,t),this}[rn](){var e,t,n,r,i,a,o,s,c,l,u,d;let f=I(this,Tt,`f`).pop();M(f,void 0,I(this,X,`f`));let p;e=this,t=this,n=this,r=this,i=this,a=this,o=this,s=this,c=this,l=this,u=this,d=this,{options:{set value(t){F(e,q,t,`f`)}}.value,configObjects:p,exitProcess:{set value(e){F(t,V,e,`f`)}}.value,groups:{set value(e){F(n,U,e,`f`)}}.value,output:{set value(e){F(r,K,e,`f`)}}.value,exitError:{set value(e){F(i,B,e,`f`)}}.value,hasOutput:{set value(e){F(a,W,e,`f`)}}.value,parsed:this.parsed,strict:{set value(e){F(o,Pt,e,`f`)}}.value,strictCommands:{set value(e){F(s,Ft,e,`f`)}}.value,strictOptions:{set value(e){F(c,It,e,`f`)}}.value,completionCommand:{set value(e){F(l,z,e,`f`)}}.value,parseFn:{set value(e){F(u,J,e,`f`)}}.value,parseContext:{set value(e){F(d,At,e,`f`)}}.value}=f,I(this,q,`f`).configObjects=p,I(this,Z,`f`).unfreeze(),I(this,$,`f`).unfreeze(),I(this,L,`f`).unfreeze(),I(this,H,`f`).unfreeze()}[an](e,t){return He(t,t=>(e(t),t))}getInternalMethods(){return{getCommandInstance:this[on].bind(this),getContext:this[sn].bind(this),getHasOutput:this[cn].bind(this),getLoggerInstance:this[ln].bind(this),getParseContext:this[un].bind(this),getParserConfiguration:this[Gt].bind(this),getUsageConfiguration:this[Kt].bind(this),getUsageInstance:this[dn].bind(this),getValidationInstance:this[fn].bind(this),hasParseCallback:this[pn].bind(this),isGlobalContext:this[mn].bind(this),postProcess:this[hn].bind(this),reset:this[_n].bind(this),runValidation:this[yn].bind(this),runYargsParserAndExecuteCommands:this[vn].bind(this),setHasOutput:this[bn].bind(this)}}[on](){return I(this,L,`f`)}[sn](){return I(this,xt,`f`)}[cn](){return I(this,W,`f`)}[ln](){return I(this,Dt,`f`)}[un](){return I(this,At,`f`)||{}}[dn](){return I(this,Z,`f`)}[fn](){return I(this,$,`f`)}[pn](){return!!I(this,J,`f`)}[mn](){return I(this,Et,`f`)}[hn](e,t,n,r){return n||N(e)||(t||(e=this[zt](e)),(this[Gt]()[`parse-positional-numbers`]||this[Gt]()[`parse-positional-numbers`]===void 0)&&(e=this[Yt](e)),r&&(e=Ve(e,this,I(this,H,`f`).getMiddleware(),!1))),e}[_n](e={}){F(this,q,I(this,q,`f`)||{},`f`);let t={};t.local=I(this,q,`f`).local||[],t.configObjects=I(this,q,`f`).configObjects||[];let n={};return t.local.forEach(t=>{n[t]=!0,(e[t]||[]).forEach(e=>{n[e]=!0})}),Object.assign(I(this,Mt,`f`),Object.keys(I(this,U,`f`)).reduce((e,t)=>{let r=I(this,U,`f`)[t].filter(e=>!(e in n));return r.length>0&&(e[t]=r),e},{})),F(this,U,{},`f`),[`array`,`boolean`,`string`,`skipValidation`,`count`,`normalize`,`number`,`hiddenOptions`].forEach(e=>{t[e]=(I(this,q,`f`)[e]||[]).filter(e=>!n[e])}),[`narg`,`key`,`alias`,`default`,`defaultDescription`,`config`,`choices`,`demandedOptions`,`demandedCommands`,`deprecatedOptions`].forEach(e=>{t[e]=$e(I(this,q,`f`)[e],e=>!n[e])}),t.envPrefix=I(this,q,`f`).envPrefix,F(this,q,t,`f`),F(this,Z,I(this,Z,`f`)?I(this,Z,`f`).reset(n):nt(this,I(this,X,`f`)),`f`),F(this,$,I(this,$,`f`)?I(this,$,`f`).reset(n):pt(this,I(this,Z,`f`),I(this,X,`f`)),`f`),F(this,L,I(this,L,`f`)?I(this,L,`f`).reset():qe(I(this,Z,`f`),I(this,$,`f`),I(this,H,`f`),I(this,X,`f`)),`f`),I(this,R,`f`)||F(this,R,ct(this,I(this,Z,`f`),I(this,L,`f`),I(this,X,`f`)),`f`),I(this,H,`f`).reset(),F(this,z,null,`f`),F(this,K,``,`f`),F(this,B,null,`f`),F(this,W,!1,`f`),this.parsed=!1,this}[gn](e,t){return I(this,X,`f`).path.relative(e,t)}[vn](e,t,n,r=0,i=!1){let a=!!n||i;e||=I(this,Y,`f`),I(this,q,`f`).__=I(this,X,`f`).y18n.__,I(this,q,`f`).configuration=this[Gt]();let o=!!I(this,q,`f`).configuration[`populate--`],s=Object.assign({},I(this,q,`f`).configuration,{"populate--":!0}),c=I(this,X,`f`).Parser.detailed(e,Object.assign({},I(this,q,`f`),{configuration:{"parse-positional-numbers":!1,...s}})),l=Object.assign(c.argv,I(this,At,`f`)),u,d=c.aliases,f=!1,p=!1;Object.keys(l).forEach(e=>{e===I(this,G,`f`)&&l[e]?f=!0:e===I(this,Q,`f`)&&l[e]&&(p=!0)}),l.$0=this.$0,this.parsed=c,r===0&&I(this,Z,`f`).clearCachedHelpMessage();try{if(this[qt](),t)return this[hn](l,o,!!n,!1);I(this,G,`f`)&&[I(this,G,`f`)].concat(d[I(this,G,`f`)]||[]).filter(e=>e.length>1).includes(``+l._[l._.length-1])&&(l._.pop(),f=!0),F(this,Et,!1,`f`);let s=I(this,L,`f`).getCommands(),m=I(this,R,`f`).completionKey in l,h=f||m||i;if(l._.length){if(s.length){let e;for(let t=r||0,a;l._[t]!==void 0;t++){if(a=String(l._[t]),s.includes(a)&&a!==I(this,z,`f`)){let e=I(this,L,`f`).runCommand(a,this,c,t+1,i,f||p||i);return this[hn](e,o,!!n,!1)}if(!e&&a!==I(this,z,`f`)){e=a;break}}!I(this,L,`f`).hasDefaultCommand()&&I(this,Nt,`f`)&&e&&!h&&I(this,$,`f`).recommendCommands(e,s)}I(this,z,`f`)&&l._.includes(I(this,z,`f`))&&!m&&(I(this,V,`f`)&&et(!0),this.showCompletionScript(),this.exit(0))}if(I(this,L,`f`).hasDefaultCommand()&&!h){let e=I(this,L,`f`).runCommand(null,this,c,0,i,f||p||i);return this[hn](e,o,!!n,!1)}if(m){I(this,V,`f`)&&et(!0),e=[].concat(e);let t=e.slice(e.indexOf(`--${I(this,R,`f`).completionKey}`)+1);return I(this,R,`f`).getCompletion(t,(e,t)=>{if(e)throw new j(e.message);(t||[]).forEach(e=>{I(this,Dt,`f`).log(e)}),this.exit(0)}),this[hn](l,!o,!!n,!1)}if(I(this,W,`f`)||(f?(I(this,V,`f`)&&et(!0),a=!0,this.showHelp(`log`),this.exit(0)):p&&(I(this,V,`f`)&&et(!0),a=!0,I(this,Z,`f`).showVersion(`log`),this.exit(0))),!a&&I(this,q,`f`).skipValidation.length>0&&(a=Object.keys(l).some(e=>I(this,q,`f`).skipValidation.indexOf(e)>=0&&l[e]===!0)),!a){if(c.error)throw new j(c.error.message);if(!m){let e=this[yn](d,{},c.error);n||(u=Ve(l,this,I(this,H,`f`).getMiddleware(),!0)),u=this[an](e,u??l),N(u)&&!n&&(u=u.then(()=>Ve(l,this,I(this,H,`f`).getMiddleware(),!1)))}}}catch(e){if(e instanceof j)I(this,Z,`f`).fail(e.message,e);else throw e}return this[hn](u??l,o,!!n,!0)}[yn](e,t,n,r){let i={...this.getDemandedOptions()};return a=>{if(n)throw new j(n.message);I(this,$,`f`).nonOptionCount(a),I(this,$,`f`).requiredArguments(a,i);let o=!1;I(this,Ft,`f`)&&(o=I(this,$,`f`).unknownCommands(a)),I(this,Pt,`f`)&&!o?I(this,$,`f`).unknownArguments(a,e,t,!!r):I(this,It,`f`)&&I(this,$,`f`).unknownArguments(a,e,{},!1,!1),I(this,$,`f`).limitedChoices(a),I(this,$,`f`).implications(a),I(this,$,`f`).conflicting(a)}}[bn](){F(this,W,!0,`f`)}[xn](e){if(typeof e==`string`)I(this,q,`f`).key[e]=!0;else for(let t of e)I(this,q,`f`).key[t]=!0}};function Cn(e){return!!e&&typeof e.getInternalMethods==`function`}const wn=Rt(Me);var Tn=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const En=e=>e.option(`multi-repo`,{type:`boolean`,description:`Compose local repositories; set up a workspace if no config exists`}).option(`workspace`,{type:`string`,requiresArg:!0,description:`Path to a local multi-repo config (implies --multi-repo)`}).option(`setup`,{type:`boolean`,description:`Review saved setup (requires --multi-repo or --workspace); preserve cache`}).option(`non-interactive`,{type:`boolean`,description:`Never prompt (requires --multi-repo or --workspace and a valid config)`}).wrap(null).epilog(n),Dn=(e,t)=>En(wn(e).scriptName(t).usage(`$0 dev --multi-repo [options]`)).option(`port`,{type:`number`,default:3e3,description:`Local preview port`}).option(`open`,{type:`boolean`,default:!1,description:`Open the preview in a browser`}).option(`client-version`,{type:`string`,hidden:!0}).option(`local-client-version`,{type:`string`,hidden:!0}).option(`local-schema`,{type:`boolean`,hidden:!0}).option(`classic`,{type:`boolean`,default:!1,description:`Preview with the classic client`}).option(`beta`,{type:`boolean`,default:!1,hidden:!0}).option(`groups`,{type:`array`,description:`Mock user groups`}).option(`signed-in`,{type:`boolean`,default:!1}).option(`disable-openapi`,{type:`boolean`,default:!1}).option(`disable-prefetch`,{type:`boolean`,default:!1}).option(`host`,{type:`boolean`,default:!1}).option(`telemetry`,{alias:`t`,type:`boolean`}).help().alias(`help`,`h`).exitProcess(!1).strictOptions().fail(e=>{throw Error(e)});function On(e){return Dn(e,`mint`).help(!1).version(!1).strictOptions(!1).parseSync()._[0]===`dev`}function kn(e,n,r,i){return Tn(this,void 0,void 0,function*(){let a=Dn(e,n).parseSync();if(a.help||a.version)return;if(a.workspace!==void 0&&!a.workspace.trim())throw Error(`--workspace requires a config path.`);if(!a[`multi-repo`]&&!a.workspace)throw Error(`Use --multi-repo with --setup or --non-interactive.`);if(!Number.isInteger(a.port)||a.port<1||a.port>65535)throw Error(`--port must be an integer from 1 to 65535.`);let{resolveWorkspace:o}=yield import(`./multi-repo-setup-C0jIlw0Q.js`),s;console.log(`Checking multi-repo configuration…`);let c=yield o({cwd:process.cwd(),workspace:a.workspace,setup:a.setup,nonInteractive:a[`non-interactive`],onSaved:e=>{s=`Saved ${e}. Keep machine-specific paths out of Git; add the local config to .gitignore.`}}),{prepareMultiRepoPreview:l}=yield import(`./multi-repo-preview-cTNsNnFK.js`),f=performance.now(),p=0,m=yield l(c,!0,{compositionCacheDirectory:d.join(u.homedir(),`.mintlify`,`multi-repo-compositions`),onProgress:e=>{e.stage===`cold`&&console.log(`Preparing the workspace for the first time. Large repositories can take around two minutes; later runs reuse the saved workspace.`),e.stage===`cached`&&console.log(`Checking the saved workspace for changes…`),e.stage===`watching`&&console.log(`Starting repository watchers…`),e.stage===`files`&&performance.now()-p>=1e3&&(p=performance.now(),console.log(`Checked ${e.files.toLocaleString()} files…`))}});r(m.close);let h=m.getStats();console.log(`Workspace ready in ${((performance.now()-f)/1e3).toFixed(1)}s: ${h?.reusedFiles??0} files reused. Starting preview…`);for(let e of m.sources)console.log(` ${e.repo} → /${e.mountPath}`);if(process.chdir(m.directory),typeof a.telemetry==`boolean`){let{setTelemetryEnabled:e}=yield import(`./config-BaacO1QY.js`);yield e(a.telemetry)}let[{dev:g,Logs:ee},{render:_},{createElement:te}]=yield Promise.all([import(`./dist-BIlW23vs.js`),import(`./build-B-oc3MuD.js`),import(`./react-CA8V--cT.js`).then(e=>/* @__PURE__ */ t(e.default,1))]);if(_(te(ee)),a.classic!==!0){let{watchComponentUsage:e}=yield import(`./live-CdptobvR.js`);e(m.directory).catch(()=>void 0)}yield g(Object.assign(Object.assign({},a),{groups:a.groups??(a[`signed-in`]?[]:void 0),packageName:n,previewReadyMessage:s,onExit:i}))})}export{A as a,wn as i,En as n,kn as r,On as t};
|
package/dist/start.js
CHANGED
|
@@ -5,4 +5,4 @@ import { dirname as __mintDirname } from 'node:path';
|
|
|
5
5
|
const require = __mintCreateRequire(import.meta.url);
|
|
6
6
|
const __filename = __mintFileURLToPath(import.meta.url);
|
|
7
7
|
const __dirname = __mintDirname(__filename);
|
|
8
|
-
import{r as e}from"./client-DXQ6Tgw0.js";var t=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};function n(e,n=e=>process.exit(e)){let r;return i=>(r??=t(this,void 0,void 0,function*(){try{yield e()}catch(e){return console.error(`Preview cleanup failed:`,e),n(1)}return n(i)}),r)}var r=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const i=process.env.MINTLIFY_PACKAGE_NAME??`mint`;let a;function o(){return r(this,void 0,void 0,function*(){let e=a;a=void 0,yield e?.()})}function s(){return r(this,void 0,void 0,function*(){let e=process.argv.slice(2);if(e.some(e=>[`--multi-repo`,`--workspace`,`--setup`,`--non-interactive`].includes(e.split(`=`)[0]??``))){let{isMultiRepoDev:t,runMultiRepoDev:n}=yield import(`./multi-repo-command-
|
|
8
|
+
import{r as e}from"./client-DXQ6Tgw0.js";var t=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};function n(e,n=e=>process.exit(e)){let r;return i=>(r??=t(this,void 0,void 0,function*(){try{yield e()}catch(e){return console.error(`Preview cleanup failed:`,e),n(1)}return n(i)}),r)}var r=function(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})};const i=process.env.MINTLIFY_PACKAGE_NAME??`mint`;let a;function o(){return r(this,void 0,void 0,function*(){let e=a;a=void 0,yield e?.()})}function s(){return r(this,void 0,void 0,function*(){let e=process.argv.slice(2);if(e.some(e=>[`--multi-repo`,`--workspace`,`--setup`,`--non-interactive`].includes(e.split(`=`)[0]??``))){let{isMultiRepoDev:t,runMultiRepoDev:n}=yield import(`./multi-repo-command-CQL_HD4n.js`);if(t(e)){yield n(e,i,e=>{a=e},()=>c(0));return}}let{cli:t}=yield import(`./cli-eZs65L66.js`);yield t({packageName:i})})}s().catch(e=>r(void 0,void 0,void 0,function*(){console.error(e instanceof Error?e.message:e),yield c(1)}));const c=n(()=>r(void 0,void 0,void 0,function*(){try{yield o()}finally{yield e()}}));process.once(`beforeExit`,()=>r(void 0,void 0,void 0,function*(){try{yield o(),yield e()}catch{}})),process.on(`SIGINT`,()=>{c(130)}),process.on(`SIGTERM`,()=>{c(143)});export{};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mintlify/cli",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.87",
|
|
4
4
|
"description": "The Mintlify CLI",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": ">=18.0.0"
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"sharp": "0.33.5"
|
|
48
48
|
},
|
|
49
49
|
"optionalDependencies": {
|
|
50
|
-
"@mintlify/package-builder": "0.0.
|
|
50
|
+
"@mintlify/package-builder": "0.0.196",
|
|
51
51
|
"@parcel/watcher": "2.5.1",
|
|
52
52
|
"fsevents": "2.3.3",
|
|
53
53
|
"keytar": "7.9.0"
|
|
@@ -55,13 +55,13 @@
|
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"@babel/parser": "7.21.2",
|
|
57
57
|
"@inquirer/prompts": "7.9.0",
|
|
58
|
-
"@mintlify/common": "1.0.
|
|
59
|
-
"@mintlify/editor": "0.0.
|
|
60
|
-
"@mintlify/link-rot": "3.0.
|
|
58
|
+
"@mintlify/common": "1.0.1407",
|
|
59
|
+
"@mintlify/editor": "0.0.687",
|
|
60
|
+
"@mintlify/link-rot": "3.0.1664",
|
|
61
61
|
"@mintlify/models": "0.0.405",
|
|
62
|
-
"@mintlify/og": "0.0.
|
|
63
|
-
"@mintlify/prebuild": "1.0.
|
|
64
|
-
"@mintlify/previewing": "4.0.
|
|
62
|
+
"@mintlify/og": "0.0.206",
|
|
63
|
+
"@mintlify/prebuild": "1.0.1587",
|
|
64
|
+
"@mintlify/previewing": "4.0.1679",
|
|
65
65
|
"@mintlify/ts-config": "2.0.2",
|
|
66
66
|
"@mintlify/validation": "0.1.991",
|
|
67
67
|
"@tsconfig/recommended": "1.0.2",
|
|
@@ -110,5 +110,5 @@
|
|
|
110
110
|
"yargs": "17.7.1",
|
|
111
111
|
"zod": "4.3.6"
|
|
112
112
|
},
|
|
113
|
-
"gitHead": "
|
|
113
|
+
"gitHead": "846dcfa2b7835d51267320e3fb19193b60f6a4d5"
|
|
114
114
|
}
|