UNPKG

evalite

Version:

Test your LLM-powered apps with a TypeScript-native, Vitest-based eval runner. No API key required.

41 lines 229 kB
import{o as Di,g as _i,R,r as te,c as lr,j as z,B as Ti,s as Yt,t as Ao,d as Wt,v as Io}from"./index-BNs2eCDL.js";/**
 * @license lucide-react v0.464.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Fo=Di("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
 * @license lucide-react v0.464.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Do=Di("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]),_o=(e,t)=>e.reduce((n,r)=>n+(t(r)||0),0),Zb=(e,t)=>_o(e,t)/e.length,To=e=>typeof e=="object"&&e!==null&&"__EvaliteFile"in e&&e.__EvaliteFile===!0,Po={fromPath:e=>({__EvaliteFile:!0,path:e}),isEvaliteFile:To};var Pi={exports:{}},Li={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},Oi={exports:{}},Lo=function(t){return!t||typeof t=="string"?!1:t instanceof Array||Array.isArray(t)||t.length>=0&&(t.splice instanceof Function||Object.getOwnPropertyDescriptor(t,t.length-1)&&t.constructor.name!=="String")},Oo=Lo,Mo=Array.prototype.concat,Ro=Array.prototype.slice,sr=Oi.exports=function(t){for(var n=[],r=0,i=t.length;r<i;r++){var o=t[r];Oo(o)?n=Mo.call(n,Ro.call(o)):n.push(o)}return n};sr.wrap=function(e){return function(){return e(sr(arguments))}};var zo=Oi.exports,ut=Li,bt=zo,Mi=Object.hasOwnProperty,Ri=Object.create(null);for(var Xt in ut)Mi.call(ut,Xt)&&(Ri[ut[Xt]]=Xt);var ce=Pi.exports={to:{},get:{}};ce.get=function(e){var t=e.substring(0,3).toLowerCase(),n,r;switch(t){case"hsl":n=ce.get.hsl(e),r="hsl";break;case"hwb":n=ce.get.hwb(e),r="hwb";break;default:n=ce.get.rgb(e),r="rgb";break}return n?{model:r,value:n}:null};ce.get.rgb=function(e){if(!e)return null;var t=/^#([a-f0-9]{3,4})$/i,n=/^#([a-f0-9]{6})([a-f0-9]{2})?$/i,r=/^rgba?\(\s*([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)(?=[\s,])\s*(?:,\s*)?([+-]?\d+)\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,i=/^rgba?\(\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*,?\s*([+-]?[\d\.]+)\%\s*(?:[,|\/]\s*([+-]?[\d\.]+)(%?)\s*)?\)$/,o=/^(\w+)$/,a=[0,0,0,1],l,s,u;if(l=e.match(n)){for(u=l[2],l=l[1],s=0;s<3;s++){var f=s*2;a[s]=parseInt(l.slice(f,f+2),16)}u&&(a[3]=parseInt(u,16)/255)}else if(l=e.match(t)){for(l=l[1],u=l[3],s=0;s<3;s++)a[s]=parseInt(l[s]+l[s],16);u&&(a[3]=parseInt(u+u,16)/255)}else if(l=e.match(r)){for(s=0;s<3;s++)a[s]=parseInt(l[s+1],0);l[4]&&(l[5]?a[3]=parseFloat(l[4])*.01:a[3]=parseFloat(l[4]))}else if(l=e.match(i)){for(s=0;s<3;s++)a[s]=Math.round(parseFloat(l[s+1])*2.55);l[4]&&(l[5]?a[3]=parseFloat(l[4])*.01:a[3]=parseFloat(l[4]))}else return(l=e.match(o))?l[1]==="transparent"?[0,0,0,0]:Mi.call(ut,l[1])?(a=ut[l[1]],a[3]=1,a):null:null;for(s=0;s<3;s++)a[s]=De(a[s],0,255);return a[3]=De(a[3],0,1),a};ce.get.hsl=function(e){if(!e)return null;var t=/^hsla?\(\s*([+-]?(?:\d{0,3}\.)?\d+)(?:deg)?\s*,?\s*([+-]?[\d\.]+)%\s*,?\s*([+-]?[\d\.]+)%\s*(?:[,|\/]\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,n=e.match(t);if(n){var r=parseFloat(n[4]),i=(parseFloat(n[1])%360+360)%360,o=De(parseFloat(n[2]),0,100),a=De(parseFloat(n[3]),0,100),l=De(isNaN(r)?1:r,0,1);return[i,o,a,l]}return null};ce.get.hwb=function(e){if(!e)return null;var t=/^hwb\(\s*([+-]?\d{0,3}(?:\.\d+)?)(?:deg)?\s*,\s*([+-]?[\d\.]+)%\s*,\s*([+-]?[\d\.]+)%\s*(?:,\s*([+-]?(?=\.\d|\d)(?:0|[1-9]\d*)?(?:\.\d*)?(?:[eE][+-]?\d+)?)\s*)?\)$/,n=e.match(t);if(n){var r=parseFloat(n[4]),i=(parseFloat(n[1])%360+360)%360,o=De(parseFloat(n[2]),0,100),a=De(parseFloat(n[3]),0,100),l=De(isNaN(r)?1:r,0,1);return[i,o,a,l]}return null};ce.to.hex=function(){var e=bt(arguments);return"#"+wt(e[0])+wt(e[1])+wt(e[2])+(e[3]<1?wt(Math.round(e[3]*255)):"")};ce.to.rgb=function(){var e=bt(arguments);return e.length<4||e[3]===1?"rgb("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+")":"rgba("+Math.round(e[0])+", "+Math.round(e[1])+", "+Math.round(e[2])+", "+e[3]+")"};ce.to.rgb.percent=function(){var e=bt(arguments),t=Math.round(e[0]/255*100),n=Math.round(e[1]/255*100),r=Math.round(e[2]/255*100);return e.length<4||e[3]===1?"rgb("+t+"%, "+n+"%, "+r+"%)":"rgba("+t+"%, "+n+"%, "+r+"%, "+e[3]+")"};ce.to.hsl=function(){var e=bt(arguments);return e.length<4||e[3]===1?"hsl("+e[0]+", "+e[1]+"%, "+e[2]+"%)":"hsla("+e[0]+", "+e[1]+"%, "+e[2]+"%, "+e[3]+")"};ce.to.hwb=function(){var e=bt(arguments),t="";return e.length>=4&&e[3]!==1&&(t=", "+e[3]),"hwb("+e[0]+", "+e[1]+"%, "+e[2]+"%"+t+")"};ce.to.keyword=function(e){return Ri[e.slice(0,3)]};function De(e,t,n){return Math.min(Math.max(t,e),n)}function wt(e){var t=Math.round(e).toString(16).toUpperCase();return t.length<2?"0"+t:t}var No=Pi.exports;const ht=Li,zi={};for(const e of Object.keys(ht))zi[ht[e]]=e;const I={rgb:{channels:3,labels:"rgb"},hsl:{channels:3,labels:"hsl"},hsv:{channels:3,labels:"hsv"},hwb:{channels:3,labels:"hwb"},cmyk:{channels:4,labels:"cmyk"},xyz:{channels:3,labels:"xyz"},lab:{channels:3,labels:"lab"},lch:{channels:3,labels:"lch"},hex:{channels:1,labels:["hex"]},keyword:{channels:1,labels:["keyword"]},ansi16:{channels:1,labels:["ansi16"]},ansi256:{channels:1,labels:["ansi256"]},hcg:{channels:3,labels:["h","c","g"]},apple:{channels:3,labels:["r16","g16","b16"]},gray:{channels:1,labels:["gray"]}};var Ni=I;for(const e of Object.keys(I)){if(!("channels"in I[e]))throw new Error("missing channels property: "+e);if(!("labels"in I[e]))throw new Error("missing channel labels property: "+e);if(I[e].labels.length!==I[e].channels)throw new Error("channel and label counts mismatch: "+e);const{channels:t,labels:n}=I[e];delete I[e].channels,delete I[e].labels,Object.defineProperty(I[e],"channels",{value:t}),Object.defineProperty(I[e],"labels",{value:n})}I.rgb.hsl=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=o-i;let l,s;o===i?l=0:t===o?l=(n-r)/a:n===o?l=2+(r-t)/a:r===o&&(l=4+(t-n)/a),l=Math.min(l*60,360),l<0&&(l+=360);const u=(i+o)/2;return o===i?s=0:u<=.5?s=a/(o+i):s=a/(2-o-i),[l,s*100,u*100]};I.rgb.hsv=function(e){let t,n,r,i,o;const a=e[0]/255,l=e[1]/255,s=e[2]/255,u=Math.max(a,l,s),f=u-Math.min(a,l,s),c=function(p){return(u-p)/6/f+1/2};return f===0?(i=0,o=0):(o=f/u,t=c(a),n=c(l),r=c(s),a===u?i=r-n:l===u?i=1/3+t-r:s===u&&(i=2/3+n-t),i<0?i+=1:i>1&&(i-=1)),[i*360,o*100,u*100]};I.rgb.hwb=function(e){const t=e[0],n=e[1];let r=e[2];const i=I.rgb.hsl(e)[0],o=1/255*Math.min(t,Math.min(n,r));return r=1-1/255*Math.max(t,Math.max(n,r)),[i,o*100,r*100]};I.rgb.cmyk=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(1-t,1-n,1-r),o=(1-t-i)/(1-i)||0,a=(1-n-i)/(1-i)||0,l=(1-r-i)/(1-i)||0;return[o*100,a*100,l*100,i*100]};function Bo(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2+(e[2]-t[2])**2}I.rgb.keyword=function(e){const t=zi[e];if(t)return t;let n=1/0,r;for(const i of Object.keys(ht)){const o=ht[i],a=Bo(e,o);a<n&&(n=a,r=i)}return r};I.keyword.rgb=function(e){return ht[e]};I.rgb.xyz=function(e){let t=e[0]/255,n=e[1]/255,r=e[2]/255;t=t>.04045?((t+.055)/1.055)**2.4:t/12.92,n=n>.04045?((n+.055)/1.055)**2.4:n/12.92,r=r>.04045?((r+.055)/1.055)**2.4:r/12.92;const i=t*.4124+n*.3576+r*.1805,o=t*.2126+n*.7152+r*.0722,a=t*.0193+n*.1192+r*.9505;return[i*100,o*100,a*100]};I.rgb.lab=function(e){const t=I.rgb.xyz(e);let n=t[0],r=t[1],i=t[2];n/=95.047,r/=100,i/=108.883,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116,i=i>.008856?i**(1/3):7.787*i+16/116;const o=116*r-16,a=500*(n-r),l=200*(r-i);return[o,a,l]};I.hsl.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;let i,o,a;if(n===0)return a=r*255,[a,a,a];r<.5?i=r*(1+n):i=r+n-r*n;const l=2*r-i,s=[0,0,0];for(let u=0;u<3;u++)o=t+1/3*-(u-1),o<0&&o++,o>1&&o--,6*o<1?a=l+(i-l)*6*o:2*o<1?a=i:3*o<2?a=l+(i-l)*(2/3-o)*6:a=l,s[u]=a*255;return s};I.hsl.hsv=function(e){const t=e[0];let n=e[1]/100,r=e[2]/100,i=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,i*=o<=1?o:2-o;const a=(r+n)/2,l=r===0?2*i/(o+i):2*n/(r+n);return[t,l*100,a*100]};I.hsv.rgb=function(e){const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const i=Math.floor(t)%6,o=t-Math.floor(t),a=255*r*(1-n),l=255*r*(1-n*o),s=255*r*(1-n*(1-o));switch(r*=255,i){case 0:return[r,s,a];case 1:return[l,r,a];case 2:return[a,r,s];case 3:return[a,l,r];case 4:return[s,a,r];case 5:return[r,a,l]}};I.hsv.hsl=function(e){const t=e[0],n=e[1]/100,r=e[2]/100,i=Math.max(r,.01);let o,a;a=(2-n)*r;const l=(2-n)*i;return o=n*i,o/=l<=1?l:2-l,o=o||0,a/=2,[t,o*100,a*100]};I.hwb.rgb=function(e){const t=e[0]/360;let n=e[1]/100,r=e[2]/100;const i=n+r;let o;i>1&&(n/=i,r/=i);const a=Math.floor(6*t),l=1-r;o=6*t-a,a&1&&(o=1-o);const s=n+o*(l-n);let u,f,c;switch(a){default:case 6:case 0:u=l,f=s,c=n;break;case 1:u=s,f=l,c=n;break;case 2:u=n,f=l,c=s;break;case 3:u=n,f=s,c=l;break;case 4:u=s,f=n,c=l;break;case 5:u=l,f=n,c=s;break}return[u*255,f*255,c*255]};I.cmyk.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100,i=e[3]/100,o=1-Math.min(1,t*(1-i)+i),a=1-Math.min(1,n*(1-i)+i),l=1-Math.min(1,r*(1-i)+i);return[o*255,a*255,l*255]};I.xyz.rgb=function(e){const t=e[0]/100,n=e[1]/100,r=e[2]/100;let i,o,a;return i=t*3.2406+n*-1.5372+r*-.4986,o=t*-.9689+n*1.8758+r*.0415,a=t*.0557+n*-.204+r*1.057,i=i>.0031308?1.055*i**(1/2.4)-.055:i*12.92,o=o>.0031308?1.055*o**(1/2.4)-.055:o*12.92,a=a>.0031308?1.055*a**(1/2.4)-.055:a*12.92,i=Math.min(Math.max(0,i),1),o=Math.min(Math.max(0,o),1),a=Math.min(Math.max(0,a),1),[i*255,o*255,a*255]};I.xyz.lab=function(e){let t=e[0],n=e[1],r=e[2];t/=95.047,n/=100,r/=108.883,t=t>.008856?t**(1/3):7.787*t+16/116,n=n>.008856?n**(1/3):7.787*n+16/116,r=r>.008856?r**(1/3):7.787*r+16/116;const i=116*n-16,o=500*(t-n),a=200*(n-r);return[i,o,a]};I.lab.xyz=function(e){const t=e[0],n=e[1],r=e[2];let i,o,a;o=(t+16)/116,i=n/500+o,a=o-r/200;const l=o**3,s=i**3,u=a**3;return o=l>.008856?l:(o-16/116)/7.787,i=s>.008856?s:(i-16/116)/7.787,a=u>.008856?u:(a-16/116)/7.787,i*=95.047,o*=100,a*=108.883,[i,o,a]};I.lab.lch=function(e){const t=e[0],n=e[1],r=e[2];let i;i=Math.atan2(r,n)*360/2/Math.PI,i<0&&(i+=360);const a=Math.sqrt(n*n+r*r);return[t,a,i]};I.lch.lab=function(e){const t=e[0],n=e[1],i=e[2]/360*2*Math.PI,o=n*Math.cos(i),a=n*Math.sin(i);return[t,o,a]};I.rgb.ansi16=function(e,t=null){const[n,r,i]=e;let o=t===null?I.rgb.hsv(e)[2]:t;if(o=Math.round(o/50),o===0)return 30;let a=30+(Math.round(i/255)<<2|Math.round(r/255)<<1|Math.round(n/255));return o===2&&(a+=60),a};I.hsv.ansi16=function(e){return I.rgb.ansi16(I.hsv.rgb(e),e[2])};I.rgb.ansi256=function(e){const t=e[0],n=e[1],r=e[2];return t===n&&n===r?t<8?16:t>248?231:Math.round((t-8)/247*24)+232:16+36*Math.round(t/255*5)+6*Math.round(n/255*5)+Math.round(r/255*5)};I.ansi16.rgb=function(e){let t=e%10;if(t===0||t===7)return e>50&&(t+=3.5),t=t/10.5*255,[t,t,t];const n=(~~(e>50)+1)*.5,r=(t&1)*n*255,i=(t>>1&1)*n*255,o=(t>>2&1)*n*255;return[r,i,o]};I.ansi256.rgb=function(e){if(e>=232){const o=(e-232)*10+8;return[o,o,o]}e-=16;let t;const n=Math.floor(e/36)/5*255,r=Math.floor((t=e%36)/6)/5*255,i=t%6/5*255;return[n,r,i]};I.rgb.hex=function(e){const n=(((Math.round(e[0])&255)<<16)+((Math.round(e[1])&255)<<8)+(Math.round(e[2])&255)).toString(16).toUpperCase();return"000000".substring(n.length)+n};I.hex.rgb=function(e){const t=e.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);if(!t)return[0,0,0];let n=t[0];t[0].length===3&&(n=n.split("").map(l=>l+l).join(""));const r=parseInt(n,16),i=r>>16&255,o=r>>8&255,a=r&255;return[i,o,a]};I.rgb.hcg=function(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.max(Math.max(t,n),r),o=Math.min(Math.min(t,n),r),a=i-o;let l,s;return a<1?l=o/(1-a):l=0,a<=0?s=0:i===t?s=(n-r)/a%6:i===n?s=2+(r-t)/a:s=4+(t-n)/a,s/=6,s%=1,[s*360,a*100,l*100]};I.hsl.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=n<.5?2*t*n:2*t*(1-n);let i=0;return r<1&&(i=(n-.5*r)/(1-r)),[e[0],r*100,i*100]};I.hsv.hcg=function(e){const t=e[1]/100,n=e[2]/100,r=t*n;let i=0;return r<1&&(i=(n-r)/(1-r)),[e[0],r*100,i*100]};I.hcg.rgb=function(e){const t=e[0]/360,n=e[1]/100,r=e[2]/100;if(n===0)return[r*255,r*255,r*255];const i=[0,0,0],o=t%1*6,a=o%1,l=1-a;let s=0;switch(Math.floor(o)){case 0:i[0]=1,i[1]=a,i[2]=0;break;case 1:i[0]=l,i[1]=1,i[2]=0;break;case 2:i[0]=0,i[1]=1,i[2]=a;break;case 3:i[0]=0,i[1]=l,i[2]=1;break;case 4:i[0]=a,i[1]=0,i[2]=1;break;default:i[0]=1,i[1]=0,i[2]=l}return s=(1-n)*r,[(n*i[0]+s)*255,(n*i[1]+s)*255,(n*i[2]+s)*255]};I.hcg.hsv=function(e){const t=e[1]/100,n=e[2]/100,r=t+n*(1-t);let i=0;return r>0&&(i=t/r),[e[0],i*100,r*100]};I.hcg.hsl=function(e){const t=e[1]/100,r=e[2]/100*(1-t)+.5*t;let i=0;return r>0&&r<.5?i=t/(2*r):r>=.5&&r<1&&(i=t/(2*(1-r))),[e[0],i*100,r*100]};I.hcg.hwb=function(e){const t=e[1]/100,n=e[2]/100,r=t+n*(1-t);return[e[0],(r-t)*100,(1-r)*100]};I.hwb.hcg=function(e){const t=e[1]/100,r=1-e[2]/100,i=r-t;let o=0;return i<1&&(o=(r-i)/(1-i)),[e[0],i*100,o*100]};I.apple.rgb=function(e){return[e[0]/65535*255,e[1]/65535*255,e[2]/65535*255]};I.rgb.apple=function(e){return[e[0]/255*65535,e[1]/255*65535,e[2]/255*65535]};I.gray.rgb=function(e){return[e[0]/100*255,e[0]/100*255,e[0]/100*255]};I.gray.hsl=function(e){return[0,0,e[0]]};I.gray.hsv=I.gray.hsl;I.gray.hwb=function(e){return[0,100,e[0]]};I.gray.cmyk=function(e){return[0,0,0,e[0]]};I.gray.lab=function(e){return[e[0],0,0]};I.gray.hex=function(e){const t=Math.round(e[0]/100*255)&255,r=((t<<16)+(t<<8)+t).toString(16).toUpperCase();return"000000".substring(r.length)+r};I.rgb.gray=function(e){return[(e[0]+e[1]+e[2])/3/255*100]};const _t=Ni;function jo(){const e={},t=Object.keys(_t);for(let n=t.length,r=0;r<n;r++)e[t[r]]={distance:-1,parent:null};return e}function $o(e){const t=jo(),n=[e];for(t[e].distance=0;n.length;){const r=n.pop(),i=Object.keys(_t[r]);for(let o=i.length,a=0;a<o;a++){const l=i[a],s=t[l];s.distance===-1&&(s.distance=t[r].distance+1,s.parent=r,n.unshift(l))}}return t}function Wo(e,t){return function(n){return t(e(n))}}function Uo(e,t){const n=[t[e].parent,e];let r=_t[t[e].parent][e],i=t[e].parent;for(;t[i].parent;)n.unshift(t[i].parent),r=Wo(_t[t[i].parent][i],r),i=t[i].parent;return r.conversion=n,r}var Ho=function(e){const t=$o(e),n={},r=Object.keys(t);for(let i=r.length,o=0;o<i;o++){const a=r[o];t[a].parent!==null&&(n[a]=Uo(a,t))}return n};const xn=Ni,qo=Ho,He={},Vo=Object.keys(xn);function Go(e){const t=function(...n){const r=n[0];return r==null?r:(r.length>1&&(n=r),e(n))};return"conversion"in e&&(t.conversion=e.conversion),t}function Yo(e){const t=function(...n){const r=n[0];if(r==null)return r;r.length>1&&(n=r);const i=e(n);if(typeof i=="object")for(let o=i.length,a=0;a<o;a++)i[a]=Math.round(i[a]);return i};return"conversion"in e&&(t.conversion=e.conversion),t}Vo.forEach(e=>{He[e]={},Object.defineProperty(He[e],"channels",{value:xn[e].channels}),Object.defineProperty(He[e],"labels",{value:xn[e].labels});const t=qo(e);Object.keys(t).forEach(r=>{const i=t[r];He[e][r]=Yo(i),He[e][r].raw=Go(i)})});var Xo=He;const qe=No,ue=Xo,Bi=["keyword","gray","hex"],kn={};for(const e of Object.keys(ue))kn[[...ue[e].labels].sort().join("")]=e;const Tt={};function Q(e,t){if(!(this instanceof Q))return new Q(e,t);if(t&&t in Bi&&(t=null),t&&!(t in ue))throw new Error("Unknown model: "+t);let n,r;if(e==null)this.model="rgb",this.color=[0,0,0],this.valpha=1;else if(e instanceof Q)this.model=e.model,this.color=[...e.color],this.valpha=e.valpha;else if(typeof e=="string"){const i=qe.get(e);if(i===null)throw new Error("Unable to parse color from string: "+e);this.model=i.model,r=ue[this.model].channels,this.color=i.value.slice(0,r),this.valpha=typeof i.value[r]=="number"?i.value[r]:1}else if(e.length>0){this.model=t||"rgb",r=ue[this.model].channels;const i=Array.prototype.slice.call(e,0,r);this.color=wn(i,r),this.valpha=typeof e[r]=="number"?e[r]:1}else if(typeof e=="number")this.model="rgb",this.color=[e>>16&255,e>>8&255,e&255],this.valpha=1;else{this.valpha=1;const i=Object.keys(e);"alpha"in e&&(i.splice(i.indexOf("alpha"),1),this.valpha=typeof e.alpha=="number"?e.alpha:0);const o=i.sort().join("");if(!(o in kn))throw new Error("Unable to parse color from object: "+JSON.stringify(e));this.model=kn[o];const{labels:a}=ue[this.model],l=[];for(n=0;n<a.length;n++)l.push(e[a[n]]);this.color=wn(l)}if(Tt[this.model])for(r=ue[this.model].channels,n=0;n<r;n++){const i=Tt[this.model][n];i&&(this.color[n]=i(this.color[n]))}this.valpha=Math.max(0,Math.min(1,this.valpha)),Object.freeze&&Object.freeze(this)}Q.prototype={toString(){return this.string()},toJSON(){return this[this.model]()},string(e){let t=this.model in qe.to?this:this.rgb();t=t.round(typeof e=="number"?e:1);const n=t.valpha===1?t.color:[...t.color,this.valpha];return qe.to[t.model](n)},percentString(e){const t=this.rgb().round(typeof e=="number"?e:1),n=t.valpha===1?t.color:[...t.color,this.valpha];return qe.to.rgb.percent(n)},array(){return this.valpha===1?[...this.color]:[...this.color,this.valpha]},object(){const e={},{channels:t}=ue[this.model],{labels:n}=ue[this.model];for(let r=0;r<t;r++)e[n[r]]=this.color[r];return this.valpha!==1&&(e.alpha=this.valpha),e},unitArray(){const e=this.rgb().color;return e[0]/=255,e[1]/=255,e[2]/=255,this.valpha!==1&&e.push(this.valpha),e},unitObject(){const e=this.rgb().object();return e.r/=255,e.g/=255,e.b/=255,this.valpha!==1&&(e.alpha=this.valpha),e},round(e){return e=Math.max(e||0,0),new Q([...this.color.map(Ko(e)),this.valpha],this.model)},alpha(e){return e!==void 0?new Q([...this.color,Math.max(0,Math.min(1,e))],this.model):this.valpha},red:X("rgb",0,K(255)),green:X("rgb",1,K(255)),blue:X("rgb",2,K(255)),hue:X(["hsl","hsv","hsl","hwb","hcg"],0,e=>(e%360+360)%360),saturationl:X("hsl",1,K(100)),lightness:X("hsl",2,K(100)),saturationv:X("hsv",1,K(100)),value:X("hsv",2,K(100)),chroma:X("hcg",1,K(100)),gray:X("hcg",2,K(100)),white:X("hwb",1,K(100)),wblack:X("hwb",2,K(100)),cyan:X("cmyk",0,K(100)),magenta:X("cmyk",1,K(100)),yellow:X("cmyk",2,K(100)),black:X("cmyk",3,K(100)),x:X("xyz",0,K(95.047)),y:X("xyz",1,K(100)),z:X("xyz",2,K(108.833)),l:X("lab",0,K(100)),a:X("lab",1),b:X("lab",2),keyword(e){return e!==void 0?new Q(e):ue[this.model].keyword(this.color)},hex(e){return e!==void 0?new Q(e):qe.to.hex(this.rgb().round().color)},hexa(e){if(e!==void 0)return new Q(e);const t=this.rgb().round().color;let n=Math.round(this.valpha*255).toString(16).toUpperCase();return n.length===1&&(n="0"+n),qe.to.hex(t)+n},rgbNumber(){const e=this.rgb().color;return(e[0]&255)<<16|(e[1]&255)<<8|e[2]&255},luminosity(){const e=this.rgb().color,t=[];for(const[n,r]of e.entries()){const i=r/255;t[n]=i<=.04045?i/12.92:((i+.055)/1.055)**2.4}return .2126*t[0]+.7152*t[1]+.0722*t[2]},contrast(e){const t=this.luminosity(),n=e.luminosity();return t>n?(t+.05)/(n+.05):(n+.05)/(t+.05)},level(e){const t=this.contrast(e);return t>=7?"AAA":t>=4.5?"AA":""},isDark(){const e=this.rgb().color;return(e[0]*2126+e[1]*7152+e[2]*722)/1e4<128},isLight(){return!this.isDark()},negate(){const e=this.rgb();for(let t=0;t<3;t++)e.color[t]=255-e.color[t];return e},lighten(e){const t=this.hsl();return t.color[2]+=t.color[2]*e,t},darken(e){const t=this.hsl();return t.color[2]-=t.color[2]*e,t},saturate(e){const t=this.hsl();return t.color[1]+=t.color[1]*e,t},desaturate(e){const t=this.hsl();return t.color[1]-=t.color[1]*e,t},whiten(e){const t=this.hwb();return t.color[1]+=t.color[1]*e,t},blacken(e){const t=this.hwb();return t.color[2]+=t.color[2]*e,t},grayscale(){const e=this.rgb().color,t=e[0]*.3+e[1]*.59+e[2]*.11;return Q.rgb(t,t,t)},fade(e){return this.alpha(this.valpha-this.valpha*e)},opaquer(e){return this.alpha(this.valpha+this.valpha*e)},rotate(e){const t=this.hsl();let n=t.color[0];return n=(n+e)%360,n=n<0?360+n:n,t.color[0]=n,t},mix(e,t){if(!e||!e.rgb)throw new Error('Argument to "mix" was not a Color instance, but rather an instance of '+typeof e);const n=e.rgb(),r=this.rgb(),i=t===void 0?.5:t,o=2*i-1,a=n.alpha()-r.alpha(),l=((o*a===-1?o:(o+a)/(1+o*a))+1)/2,s=1-l;return Q.rgb(l*n.red()+s*r.red(),l*n.green()+s*r.green(),l*n.blue()+s*r.blue(),n.alpha()*i+r.alpha()*(1-i))}};for(const e of Object.keys(ue)){if(Bi.includes(e))continue;const{channels:t}=ue[e];Q.prototype[e]=function(...n){return this.model===e?new Q(this):n.length>0?new Q(n,e):new Q([...Qo(ue[this.model][e].raw(this.color)),this.valpha],e)},Q[e]=function(...n){let r=n[0];return typeof r=="number"&&(r=wn(n,t)),new Q(r,e)}}function Jo(e,t){return Number(e.toFixed(t))}function Ko(e){return function(t){return Jo(t,e)}}function X(e,t,n){e=Array.isArray(e)?e:[e];for(const r of e)(Tt[r]||(Tt[r]=[]))[t]=n;return e=e[0],function(r){let i;return r!==void 0?(n&&(r=n(r)),i=this[e](),i.color[t]=r,i):(i=this[e]().color[t],n&&(i=n(i)),i)}}function K(e){return function(t){return Math.max(0,Math.min(e,t))}}function Qo(e){return Array.isArray(e)?e:[e]}function wn(e,t){for(let n=0;n<t;n++)typeof e[n]!="number"&&(e[n]=0);return e}var Zo=Q;const ur=_i(Zo);var el=typeof global=="object"&&global&&global.Object===Object&&global,tl=typeof self=="object"&&self&&self.Object===Object&&self,ze=el||tl||Function("return this")(),Pt=ze.Symbol,ji=Object.prototype,nl=ji.hasOwnProperty,rl=ji.toString,rt=Pt?Pt.toStringTag:void 0;function il(e){var t=nl.call(e,rt),n=e[rt];try{e[rt]=void 0;var r=!0}catch{}var i=rl.call(e);return r&&(t?e[rt]=n:delete e[rt]),i}var al=Object.prototype,ol=al.toString;function ll(e){return ol.call(e)}var sl="[object Null]",ul="[object Undefined]",cr=Pt?Pt.toStringTag:void 0;function $i(e){return e==null?e===void 0?ul:sl:cr&&cr in Object(e)?il(e):ll(e)}function Wi(e){return e!=null&&typeof e=="object"}var cl="[object Symbol]";function fl(e){return typeof e=="symbol"||Wi(e)&&$i(e)==cl}var hl=Array.isArray,pl=/\s/;function dl(e){for(var t=e.length;t--&&pl.test(e.charAt(t)););return t}var ml=/^\s+/;function bl(e){return e&&e.slice(0,dl(e)+1).replace(ml,"")}function Ye(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var fr=NaN,gl=/^[-+]0x[0-9a-f]+$/i,yl=/^0b[01]+$/i,xl=/^0o[0-7]+$/i,kl=parseInt;function wl(e){if(typeof e=="number")return e;if(fl(e))return fr;if(Ye(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Ye(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=bl(e);var n=yl.test(e);return n||xl.test(e)?kl(e.slice(2),n?2:8):gl.test(e)?fr:+e}var hr=1/0,vl=17976931348623157e292;function Cl(e){if(!e)return e===0?e:0;if(e=wl(e),e===hr||e===-hr){var t=e<0?-1:1;return t*vl}return e===e?e:0}function pr(e){var t=Cl(e),n=t%1;return t===t?n?t-n:t:0}function Ui(e){return e}var Sl="[object AsyncFunction]",El="[object Function]",Al="[object GeneratorFunction]",Il="[object Proxy]";function Fl(e){if(!Ye(e))return!1;var t=$i(e);return t==El||t==Al||t==Sl||t==Il}var Jt=ze["__core-js_shared__"],dr=function(){var e=/[^.]+$/.exec(Jt&&Jt.keys&&Jt.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function Dl(e){return!!dr&&dr in e}var _l=Function.prototype,Tl=_l.toString;function Pl(e){if(e!=null){try{return Tl.call(e)}catch{}try{return e+""}catch{}}return""}var Ll=/[\\^$.*+?()[\]{}|]/g,Ol=/^\[object .+?Constructor\]$/,Ml=Function.prototype,Rl=Object.prototype,zl=Ml.toString,Nl=Rl.hasOwnProperty,Bl=RegExp("^"+zl.call(Nl).replace(Ll,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function jl(e){if(!Ye(e)||Dl(e))return!1;var t=Fl(e)?Bl:Ol;return t.test(Pl(e))}function $l(e,t){return e==null?void 0:e[t]}function Hi(e,t){var n=$l(e,t);return jl(n)?n:void 0}var mr=Hi(ze,"WeakMap"),Lt=mr&&new mr,qi=Lt?function(e,t){return Lt.set(e,t),e}:Ui,br=Object.create,Ln=function(){function e(){}return function(t){if(!Ye(t))return{};if(br)return br(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function pt(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=Ln(e.prototype),r=e.apply(n,t);return Ye(r)?r:n}}var Wl=1;function Ul(e,t,n){var r=t&Wl,i=pt(e);function o(){var a=this&&this!==ze&&this instanceof o?i:e;return a.apply(r?n:this,arguments)}return o}function Vi(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}var Hl=Math.max;function Gi(e,t,n,r){for(var i=-1,o=e.length,a=n.length,l=-1,s=t.length,u=Hl(o-a,0),f=Array(s+u),c=!r;++l<s;)f[l]=t[l];for(;++i<a;)(c||i<o)&&(f[n[i]]=e[i]);for(;u--;)f[l++]=e[i++];return f}var ql=Math.max;function Yi(e,t,n,r){for(var i=-1,o=e.length,a=-1,l=n.length,s=-1,u=t.length,f=ql(o-l,0),c=Array(f+u),p=!r;++i<f;)c[i]=e[i];for(var h=i;++s<u;)c[h+s]=t[s];for(;++a<l;)(p||i<o)&&(c[h+n[a]]=e[i++]);return c}function Vl(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}function On(){}var Gl=4294967295;function Xe(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Gl,this.__views__=[]}Xe.prototype=Ln(On.prototype);Xe.prototype.constructor=Xe;function Yl(){}var Xi=Lt?function(e){return Lt.get(e)}:Yl,gr={},Xl=Object.prototype,Jl=Xl.hasOwnProperty;function Kl(e){for(var t=e.name+"",n=gr[t],r=Jl.call(gr,t)?n.length:0;r--;){var i=n[r],o=i.func;if(o==null||o==e)return i.name}return t}function Je(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}Je.prototype=Ln(On.prototype);Je.prototype.constructor=Je;function Ji(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}function Ql(e){if(e instanceof Xe)return e.clone();var t=new Je(e.__wrapped__,e.__chain__);return t.__actions__=Ji(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var Zl=Object.prototype,es=Zl.hasOwnProperty;function Ot(e){if(Wi(e)&&!hl(e)&&!(e instanceof Xe)){if(e instanceof Je)return e;if(es.call(e,"__wrapped__"))return Ql(e)}return new Je(e)}Ot.prototype=On.prototype;Ot.prototype.constructor=Ot;function ts(e){var t=Kl(e),n=Ot[t];if(typeof n!="function"||!(t in Xe.prototype))return!1;if(e===n)return!0;var r=Xi(n);return!!r&&e===r[0]}var ns=800,rs=16,is=Date.now;function Ki(e){var t=0,n=0;return function(){var r=is(),i=rs-(r-n);if(n=r,i>0){if(++t>=ns)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Qi=Ki(qi),as=/\{\n\/\* \[wrapped with (.+)\] \*/,os=/,? & /;function ls(e){var t=e.match(as);return t?t[1].split(os):[]}var ss=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function us(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(ss,`{
/* [wrapped with `+t+`] */
`)}function cs(e){return function(){return e}}var yr=function(){try{var e=Hi(Object,"defineProperty");return e({},"",{}),e}catch{}}(),fs=yr?function(e,t){return yr(e,"toString",{configurable:!0,enumerable:!1,value:cs(t),writable:!0})}:Ui,hs=Ki(fs);function ps(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}function ds(e,t,n,r){for(var i=e.length,o=n+-1;++o<i;)if(t(e[o],o,e))return o;return-1}function ms(e){return e!==e}function bs(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function gs(e,t,n){return t===t?bs(e,t,n):ds(e,ms,n)}function ys(e,t){var n=e==null?0:e.length;return!!n&&gs(e,t,0)>-1}var xs=1,ks=2,ws=8,vs=16,Cs=32,Ss=64,Es=128,As=256,Is=512,Fs=[["ary",Es],["bind",xs],["bindKey",ks],["curry",ws],["curryRight",vs],["flip",Is],["partial",Cs],["partialRight",Ss],["rearg",As]];function Ds(e,t){return ps(Fs,function(n){var r="_."+n[0];t&n[1]&&!ys(e,r)&&e.push(r)}),e.sort()}function Zi(e,t,n){var r=t+"";return hs(e,us(r,Ds(ls(r),n)))}var _s=1,Ts=2,Ps=4,Ls=8,xr=32,kr=64;function ea(e,t,n,r,i,o,a,l,s,u){var f=t&Ls,c=f?a:void 0,p=f?void 0:a,h=f?o:void 0,d=f?void 0:o;t|=f?xr:kr,t&=~(f?kr:xr),t&Ps||(t&=~(_s|Ts));var g=[e,t,i,h,c,d,p,l,s,u],C=n.apply(void 0,g);return ts(e)&&Qi(C,g),C.placeholder=r,Zi(C,e,t)}function ta(e){var t=e;return t.placeholder}var Os=9007199254740991,Ms=/^(?:0|[1-9]\d*)$/;function Rs(e,t){var n=typeof e;return t=t??Os,!!t&&(n=="number"||n!="symbol"&&Ms.test(e))&&e>-1&&e%1==0&&e<t}var zs=Math.min;function Ns(e,t){for(var n=e.length,r=zs(t.length,n),i=Ji(e);r--;){var o=t[r];e[r]=Rs(o,n)?i[o]:void 0}return e}var wr="__lodash_placeholder__";function Mt(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n];(a===t||a===wr)&&(e[n]=wr,o[i++]=n)}return o}var Bs=1,js=2,$s=8,Ws=16,Us=128,Hs=512;function Mn(e,t,n,r,i,o,a,l,s,u){var f=t&Us,c=t&Bs,p=t&js,h=t&($s|Ws),d=t&Hs,g=p?void 0:pt(e);function C(){for(var y=arguments.length,v=Array(y),S=y;S--;)v[S]=arguments[S];if(h)var P=ta(C),D=Vl(v,P);if(r&&(v=Gi(v,r,i,h)),o&&(v=Yi(v,o,a,h)),y-=D,h&&y<u){var k=Mt(v,P);return ea(e,t,Mn,C.placeholder,n,v,k,l,s,u-y)}var M=c?n:this,W=p?M[e]:e;return y=v.length,l?v=Ns(v,l):d&&y>1&&v.reverse(),f&&s<y&&(v.length=s),this&&this!==ze&&this instanceof C&&(W=g||pt(W)),W.apply(M,v)}return C}function qs(e,t,n){var r=pt(e);function i(){for(var o=arguments.length,a=Array(o),l=o,s=ta(i);l--;)a[l]=arguments[l];var u=o<3&&a[0]!==s&&a[o-1]!==s?[]:Mt(a,s);if(o-=u.length,o<n)return ea(e,t,Mn,i.placeholder,void 0,a,u,void 0,void 0,n-o);var f=this&&this!==ze&&this instanceof i?r:e;return Vi(f,this,a)}return i}var Vs=1;function Gs(e,t,n,r){var i=t&Vs,o=pt(e);function a(){for(var l=-1,s=arguments.length,u=-1,f=r.length,c=Array(f+s),p=this&&this!==ze&&this instanceof a?o:e;++u<f;)c[u]=r[u];for(;s--;)c[u++]=arguments[++l];return Vi(p,i?n:this,c)}return a}var vr="__lodash_placeholder__",Kt=1,Ys=2,Xs=4,Cr=8,it=128,Sr=256,Js=Math.min;function Ks(e,t){var n=e[1],r=t[1],i=n|r,o=i<(Kt|Ys|it),a=r==it&&n==Cr||r==it&&n==Sr&&e[7].length<=t[8]||r==(it|Sr)&&t[7].length<=t[8]&&n==Cr;if(!(o||a))return e;r&Kt&&(e[2]=t[2],i|=n&Kt?0:Xs);var l=t[3];if(l){var s=e[3];e[3]=s?Gi(s,l,t[4]):l,e[4]=s?Mt(e[3],vr):t[4]}return l=t[5],l&&(s=e[5],e[5]=s?Yi(s,l,t[6]):l,e[6]=s?Mt(e[5],vr):t[6]),l=t[7],l&&(e[7]=l),r&it&&(e[8]=e[8]==null?t[8]:Js(e[8],t[8])),e[9]==null&&(e[9]=t[9]),e[0]=t[0],e[1]=i,e}var Qs="Expected a function",Er=1,Zs=2,Qt=8,Zt=16,en=32,Ar=64,Ir=Math.max;function eu(e,t,n,r,i,o,a,l){var s=t&Zs;if(!s&&typeof e!="function")throw new TypeError(Qs);var u=r?r.length:0;if(u||(t&=~(en|Ar),r=i=void 0),a=a===void 0?a:Ir(pr(a),0),l=l===void 0?l:pr(l),u-=i?i.length:0,t&Ar){var f=r,c=i;r=i=void 0}var p=s?void 0:Xi(e),h=[e,t,n,r,i,f,c,o,a,l];if(p&&Ks(h,p),e=h[0],t=h[1],n=h[2],r=h[3],i=h[4],l=h[9]=h[9]===void 0?s?0:e.length:Ir(h[9]-u,0),!l&&t&(Qt|Zt)&&(t&=~(Qt|Zt)),!t||t==Er)var d=Ul(e,t,n);else t==Qt||t==Zt?d=qs(e,t,l):(t==en||t==(Er|en))&&!i.length?d=Gs(e,t,n,r):d=Mn.apply(void 0,h);var g=p?qi:Qi;return Zi(g(d,h),e,t)}var tu=8;function Rt(e,t,n){t=n?void 0:t;var r=eu(e,tu,void 0,void 0,void 0,void 0,void 0,t);return r.placeholder=Rt.placeholder,r}Rt.placeholder={};function nu(e){const t=e[0],n=e[1],r=e[2];let i,o,a;return i=t*1+n*0+r*1.13983,o=t*1+n*-.39465+r*-.5806,a=t*1+n*2.02311+r*0,i=Math.min(Math.max(0,i),1),o=Math.min(Math.max(0,o),1),a=Math.min(Math.max(0,a),1),[i*255,o*255,a*255]}function ru(e){const t=e[0]/255,n=e[1]/255,r=e[2]/255,i=t*.299+n*.587+r*.114,o=t*-.14713+n*-.28886+r*.436,a=t*.615+n*-.51499+r*-.10001;return[i,o,a]}const iu={scheme:"threezerotwofour",author:"jan t. sott (http://github.com/idleberg)",base00:"#090300",base01:"#3a3432",base02:"#4a4543",base03:"#5c5855",base04:"#807d7c",base05:"#a5a2a2",base06:"#d6d5d4",base07:"#f7f7f7",base08:"#db2d20",base09:"#e8bbd0",base0A:"#fded02",base0B:"#01a252",base0C:"#b5e4f4",base0D:"#01a0e4",base0E:"#a16a94",base0F:"#cdab53"},au={scheme:"apathy",author:"jannik siebert (https://github.com/janniks)",base00:"#031A16",base01:"#0B342D",base02:"#184E45",base03:"#2B685E",base04:"#5F9C92",base05:"#81B5AC",base06:"#A7CEC8",base07:"#D2E7E4",base08:"#3E9688",base09:"#3E7996",base0A:"#3E4C96",base0B:"#883E96",base0C:"#963E4C",base0D:"#96883E",base0E:"#4C963E",base0F:"#3E965B"},ou={scheme:"ashes",author:"jannik siebert (https://github.com/janniks)",base00:"#1C2023",base01:"#393F45",base02:"#565E65",base03:"#747C84",base04:"#ADB3BA",base05:"#C7CCD1",base06:"#DFE2E5",base07:"#F3F4F5",base08:"#C7AE95",base09:"#C7C795",base0A:"#AEC795",base0B:"#95C7AE",base0C:"#95AEC7",base0D:"#AE95C7",base0E:"#C795AE",base0F:"#C79595"},lu={scheme:"atelier dune",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune)",base00:"#20201d",base01:"#292824",base02:"#6e6b5e",base03:"#7d7a68",base04:"#999580",base05:"#a6a28c",base06:"#e8e4cf",base07:"#fefbec",base08:"#d73737",base09:"#b65611",base0A:"#cfb017",base0B:"#60ac39",base0C:"#1fad83",base0D:"#6684e1",base0E:"#b854d4",base0F:"#d43552"},su={scheme:"atelier forest",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest)",base00:"#1b1918",base01:"#2c2421",base02:"#68615e",base03:"#766e6b",base04:"#9c9491",base05:"#a8a19f",base06:"#e6e2e0",base07:"#f1efee",base08:"#f22c40",base09:"#df5320",base0A:"#d5911a",base0B:"#5ab738",base0C:"#00ad9c",base0D:"#407ee7",base0E:"#6666ea",base0F:"#c33ff3"},uu={scheme:"atelier heath",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath)",base00:"#1b181b",base01:"#292329",base02:"#695d69",base03:"#776977",base04:"#9e8f9e",base05:"#ab9bab",base06:"#d8cad8",base07:"#f7f3f7",base08:"#ca402b",base09:"#a65926",base0A:"#bb8a35",base0B:"#379a37",base0C:"#159393",base0D:"#516aec",base0E:"#7b59c0",base0F:"#cc33cc"},cu={scheme:"atelier lakeside",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside/)",base00:"#161b1d",base01:"#1f292e",base02:"#516d7b",base03:"#5a7b8c",base04:"#7195a8",base05:"#7ea2b4",base06:"#c1e4f6",base07:"#ebf8ff",base08:"#d22d72",base09:"#935c25",base0A:"#8a8a0f",base0B:"#568c3b",base0C:"#2d8f6f",base0D:"#257fad",base0E:"#5d5db1",base0F:"#b72dd2"},fu={scheme:"atelier seaside",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside/)",base00:"#131513",base01:"#242924",base02:"#5e6e5e",base03:"#687d68",base04:"#809980",base05:"#8ca68c",base06:"#cfe8cf",base07:"#f0fff0",base08:"#e6193c",base09:"#87711d",base0A:"#c3c322",base0B:"#29a329",base0C:"#1999b3",base0D:"#3d62f5",base0E:"#ad2bee",base0F:"#e619c3"},hu={scheme:"bespin",author:"jan t. sott",base00:"#28211c",base01:"#36312e",base02:"#5e5d5c",base03:"#666666",base04:"#797977",base05:"#8a8986",base06:"#9d9b97",base07:"#baae9e",base08:"#cf6a4c",base09:"#cf7d34",base0A:"#f9ee98",base0B:"#54be0d",base0C:"#afc4db",base0D:"#5ea6ea",base0E:"#9b859d",base0F:"#937121"},pu={scheme:"brewer",author:"timothée poisot (http://github.com/tpoisot)",base00:"#0c0d0e",base01:"#2e2f30",base02:"#515253",base03:"#737475",base04:"#959697",base05:"#b7b8b9",base06:"#dadbdc",base07:"#fcfdfe",base08:"#e31a1c",base09:"#e6550d",base0A:"#dca060",base0B:"#31a354",base0C:"#80b1d3",base0D:"#3182bd",base0E:"#756bb1",base0F:"#b15928"},du={scheme:"bright",author:"chris kempson (http://chriskempson.com)",base00:"#000000",base01:"#303030",base02:"#505050",base03:"#b0b0b0",base04:"#d0d0d0",base05:"#e0e0e0",base06:"#f5f5f5",base07:"#ffffff",base08:"#fb0120",base09:"#fc6d24",base0A:"#fda331",base0B:"#a1c659",base0C:"#76c7b7",base0D:"#6fb3d2",base0E:"#d381c3",base0F:"#be643c"},mu={scheme:"chalk",author:"chris kempson (http://chriskempson.com)",base00:"#151515",base01:"#202020",base02:"#303030",base03:"#505050",base04:"#b0b0b0",base05:"#d0d0d0",base06:"#e0e0e0",base07:"#f5f5f5",base08:"#fb9fb1",base09:"#eda987",base0A:"#ddb26f",base0B:"#acc267",base0C:"#12cfc0",base0D:"#6fc2ef",base0E:"#e1a3ee",base0F:"#deaf8f"},bu={scheme:"codeschool",author:"brettof86",base00:"#232c31",base01:"#1c3657",base02:"#2a343a",base03:"#3f4944",base04:"#84898c",base05:"#9ea7a6",base06:"#a7cfa3",base07:"#b5d8f6",base08:"#2a5491",base09:"#43820d",base0A:"#a03b1e",base0B:"#237986",base0C:"#b02f30",base0D:"#484d79",base0E:"#c59820",base0F:"#c98344"},gu={scheme:"colors",author:"mrmrs (http://clrs.cc)",base00:"#111111",base01:"#333333",base02:"#555555",base03:"#777777",base04:"#999999",base05:"#bbbbbb",base06:"#dddddd",base07:"#ffffff",base08:"#ff4136",base09:"#ff851b",base0A:"#ffdc00",base0B:"#2ecc40",base0C:"#7fdbff",base0D:"#0074d9",base0E:"#b10dc9",base0F:"#85144b"},yu={scheme:"default",author:"chris kempson (http://chriskempson.com)",base00:"#181818",base01:"#282828",base02:"#383838",base03:"#585858",base04:"#b8b8b8",base05:"#d8d8d8",base06:"#e8e8e8",base07:"#f8f8f8",base08:"#ab4642",base09:"#dc9656",base0A:"#f7ca88",base0B:"#a1b56c",base0C:"#86c1b9",base0D:"#7cafc2",base0E:"#ba8baf",base0F:"#a16946"},xu={scheme:"eighties",author:"chris kempson (http://chriskempson.com)",base00:"#2d2d2d",base01:"#393939",base02:"#515151",base03:"#747369",base04:"#a09f93",base05:"#d3d0c8",base06:"#e8e6df",base07:"#f2f0ec",base08:"#f2777a",base09:"#f99157",base0A:"#ffcc66",base0B:"#99cc99",base0C:"#66cccc",base0D:"#6699cc",base0E:"#cc99cc",base0F:"#d27b53"},ku={scheme:"embers",author:"jannik siebert (https://github.com/janniks)",base00:"#16130F",base01:"#2C2620",base02:"#433B32",base03:"#5A5047",base04:"#8A8075",base05:"#A39A90",base06:"#BEB6AE",base07:"#DBD6D1",base08:"#826D57",base09:"#828257",base0A:"#6D8257",base0B:"#57826D",base0C:"#576D82",base0D:"#6D5782",base0E:"#82576D",base0F:"#825757"},wu={scheme:"flat",author:"chris kempson (http://chriskempson.com)",base00:"#2C3E50",base01:"#34495E",base02:"#7F8C8D",base03:"#95A5A6",base04:"#BDC3C7",base05:"#e0e0e0",base06:"#f5f5f5",base07:"#ECF0F1",base08:"#E74C3C",base09:"#E67E22",base0A:"#F1C40F",base0B:"#2ECC71",base0C:"#1ABC9C",base0D:"#3498DB",base0E:"#9B59B6",base0F:"#be643c"},vu={scheme:"google",author:"seth wright (http://sethawright.com)",base00:"#1d1f21",base01:"#282a2e",base02:"#373b41",base03:"#969896",base04:"#b4b7b4",base05:"#c5c8c6",base06:"#e0e0e0",base07:"#ffffff",base08:"#CC342B",base09:"#F96A38",base0A:"#FBA922",base0B:"#198844",base0C:"#3971ED",base0D:"#3971ED",base0E:"#A36AC7",base0F:"#3971ED"},Cu={scheme:"grayscale",author:"alexandre gavioli (https://github.com/alexx2/)",base00:"#101010",base01:"#252525",base02:"#464646",base03:"#525252",base04:"#ababab",base05:"#b9b9b9",base06:"#e3e3e3",base07:"#f7f7f7",base08:"#7c7c7c",base09:"#999999",base0A:"#a0a0a0",base0B:"#8e8e8e",base0C:"#868686",base0D:"#686868",base0E:"#747474",base0F:"#5e5e5e"},Su={scheme:"green screen",author:"chris kempson (http://chriskempson.com)",base00:"#001100",base01:"#003300",base02:"#005500",base03:"#007700",base04:"#009900",base05:"#00bb00",base06:"#00dd00",base07:"#00ff00",base08:"#007700",base09:"#009900",base0A:"#007700",base0B:"#00bb00",base0C:"#005500",base0D:"#009900",base0E:"#00bb00",base0F:"#005500"},Eu={scheme:"harmonic16",author:"jannik siebert (https://github.com/janniks)",base00:"#0b1c2c",base01:"#223b54",base02:"#405c79",base03:"#627e99",base04:"#aabcce",base05:"#cbd6e2",base06:"#e5ebf1",base07:"#f7f9fb",base08:"#bf8b56",base09:"#bfbf56",base0A:"#8bbf56",base0B:"#56bf8b",base0C:"#568bbf",base0D:"#8b56bf",base0E:"#bf568b",base0F:"#bf5656"},Au={scheme:"hopscotch",author:"jan t. sott",base00:"#322931",base01:"#433b42",base02:"#5c545b",base03:"#797379",base04:"#989498",base05:"#b9b5b8",base06:"#d5d3d5",base07:"#ffffff",base08:"#dd464c",base09:"#fd8b19",base0A:"#fdcc59",base0B:"#8fc13e",base0C:"#149b93",base0D:"#1290bf",base0E:"#c85e7c",base0F:"#b33508"},Iu={scheme:"isotope",author:"jan t. sott",base00:"#000000",base01:"#404040",base02:"#606060",base03:"#808080",base04:"#c0c0c0",base05:"#d0d0d0",base06:"#e0e0e0",base07:"#ffffff",base08:"#ff0000",base09:"#ff9900",base0A:"#ff0099",base0B:"#33ff00",base0C:"#00ffff",base0D:"#0066ff",base0E:"#cc00ff",base0F:"#3300ff"},Fu={scheme:"marrakesh",author:"alexandre gavioli (http://github.com/alexx2/)",base00:"#201602",base01:"#302e00",base02:"#5f5b17",base03:"#6c6823",base04:"#86813b",base05:"#948e48",base06:"#ccc37a",base07:"#faf0a5",base08:"#c35359",base09:"#b36144",base0A:"#a88339",base0B:"#18974e",base0C:"#75a738",base0D:"#477ca1",base0E:"#8868b3",base0F:"#b3588e"},Du={scheme:"mocha",author:"chris kempson (http://chriskempson.com)",base00:"#3B3228",base01:"#534636",base02:"#645240",base03:"#7e705a",base04:"#b8afad",base05:"#d0c8c6",base06:"#e9e1dd",base07:"#f5eeeb",base08:"#cb6077",base09:"#d28b71",base0A:"#f4bc87",base0B:"#beb55b",base0C:"#7bbda4",base0D:"#8ab3b5",base0E:"#a89bb9",base0F:"#bb9584"},_u={scheme:"monokai",author:"wimer hazenberg (http://www.monokai.nl)",base00:"#272822",base01:"#383830",base02:"#49483e",base03:"#75715e",base04:"#a59f85",base05:"#f8f8f2",base06:"#f5f4f1",base07:"#f9f8f5",base08:"#f92672",base09:"#fd971f",base0A:"#f4bf75",base0B:"#a6e22e",base0C:"#a1efe4",base0D:"#66d9ef",base0E:"#ae81ff",base0F:"#cc6633"},Tu={scheme:"nicinabox",author:"nicinabox (http://github.com/nicinabox)",base00:"#2A2F3A",base01:"#3C444F",base02:"#4F5A65",base03:"#BEBEBE",base04:"#b0b0b0",base05:"#d0d0d0",base06:"#FFFFFF",base07:"#f5f5f5",base08:"#fb9fb1",base09:"#FC6D24",base0A:"#ddb26f",base0B:"#A1C659",base0C:"#12cfc0",base0D:"#6FB3D2",base0E:"#D381C3",base0F:"#deaf8f"},Pu={scheme:"ocean",author:"chris kempson (http://chriskempson.com)",base00:"#2b303b",base01:"#343d46",base02:"#4f5b66",base03:"#65737e",base04:"#a7adba",base05:"#c0c5ce",base06:"#dfe1e8",base07:"#eff1f5",base08:"#bf616a",base09:"#d08770",base0A:"#ebcb8b",base0B:"#a3be8c",base0C:"#96b5b4",base0D:"#8fa1b3",base0E:"#b48ead",base0F:"#ab7967"},Lu={scheme:"paraiso",author:"jan t. sott",base00:"#2f1e2e",base01:"#41323f",base02:"#4f424c",base03:"#776e71",base04:"#8d8687",base05:"#a39e9b",base06:"#b9b6b0",base07:"#e7e9db",base08:"#ef6155",base09:"#f99b15",base0A:"#fec418",base0B:"#48b685",base0C:"#5bc4bf",base0D:"#06b6ef",base0E:"#815ba4",base0F:"#e96ba8"},Ou={scheme:"pop",author:"chris kempson (http://chriskempson.com)",base00:"#000000",base01:"#202020",base02:"#303030",base03:"#505050",base04:"#b0b0b0",base05:"#d0d0d0",base06:"#e0e0e0",base07:"#ffffff",base08:"#eb008a",base09:"#f29333",base0A:"#f8ca12",base0B:"#37b349",base0C:"#00aabb",base0D:"#0e5a94",base0E:"#b31e8d",base0F:"#7a2d00"},Mu={scheme:"railscasts",author:"ryan bates (http://railscasts.com)",base00:"#2b2b2b",base01:"#272935",base02:"#3a4055",base03:"#5a647e",base04:"#d4cfc9",base05:"#e6e1dc",base06:"#f4f1ed",base07:"#f9f7f3",base08:"#da4939",base09:"#cc7833",base0A:"#ffc66d",base0B:"#a5c261",base0C:"#519f50",base0D:"#6d9cbe",base0E:"#b6b3eb",base0F:"#bc9458"},Ru={scheme:"shapeshifter",author:"tyler benziger (http://tybenz.com)",base00:"#000000",base01:"#040404",base02:"#102015",base03:"#343434",base04:"#555555",base05:"#ababab",base06:"#e0e0e0",base07:"#f9f9f9",base08:"#e92f2f",base09:"#e09448",base0A:"#dddd13",base0B:"#0ed839",base0C:"#23edda",base0D:"#3b48e3",base0E:"#f996e2",base0F:"#69542d"},zu={scheme:"solarized",author:"ethan schoonover (http://ethanschoonover.com/solarized)",base00:"#002b36",base01:"#073642",base02:"#586e75",base03:"#657b83",base04:"#839496",base05:"#93a1a1",base06:"#eee8d5",base07:"#fdf6e3",base08:"#dc322f",base09:"#cb4b16",base0A:"#b58900",base0B:"#859900",base0C:"#2aa198",base0D:"#268bd2",base0E:"#6c71c4",base0F:"#d33682"},Nu={scheme:"summerfruit",author:"christopher corley (http://cscorley.github.io/)",base00:"#151515",base01:"#202020",base02:"#303030",base03:"#505050",base04:"#B0B0B0",base05:"#D0D0D0",base06:"#E0E0E0",base07:"#FFFFFF",base08:"#FF0086",base09:"#FD8900",base0A:"#ABA800",base0B:"#00C918",base0C:"#1faaaa",base0D:"#3777E6",base0E:"#AD00A1",base0F:"#cc6633"},Bu={scheme:"tomorrow",author:"chris kempson (http://chriskempson.com)",base00:"#1d1f21",base01:"#282a2e",base02:"#373b41",base03:"#969896",base04:"#b4b7b4",base05:"#c5c8c6",base06:"#e0e0e0",base07:"#ffffff",base08:"#cc6666",base09:"#de935f",base0A:"#f0c674",base0B:"#b5bd68",base0C:"#8abeb7",base0D:"#81a2be",base0E:"#b294bb",base0F:"#a3685a"},ju={scheme:"london tube",author:"jan t. sott",base00:"#231f20",base01:"#1c3f95",base02:"#5a5758",base03:"#737171",base04:"#959ca1",base05:"#d9d8d8",base06:"#e7e7e8",base07:"#ffffff",base08:"#ee2e24",base09:"#f386a1",base0A:"#ffd204",base0B:"#00853e",base0C:"#85cebc",base0D:"#009ddc",base0E:"#98005d",base0F:"#b06110"},$u={scheme:"twilight",author:"david hart (http://hart-dev.com)",base00:"#1e1e1e",base01:"#323537",base02:"#464b50",base03:"#5f5a60",base04:"#838184",base05:"#a7a7a7",base06:"#c3c3c3",base07:"#ffffff",base08:"#cf6a4c",base09:"#cda869",base0A:"#f9ee98",base0B:"#8f9d6a",base0C:"#afc4db",base0D:"#7587a6",base0E:"#9b859d",base0F:"#9b703f"},na={threezerotwofour:iu,apathy:au,ashes:ou,atelierDune:lu,atelierForest:su,atelierHeath:uu,atelierLakeside:cu,atelierSeaside:fu,bespin:hu,brewer:pu,bright:du,chalk:mu,codeschool:bu,colors:gu,default:yu,eighties:xu,embers:ku,flat:wu,google:vu,grayscale:Cu,greenscreen:Su,harmonic:Eu,hopscotch:Au,isotope:Iu,marrakesh:Fu,mocha:Du,monokai:_u,nicinabox:Tu,ocean:Pu,paraiso:Lu,pop:Ou,railscasts:Mu,shapeshifter:Ru,solarized:zu,summerfruit:Nu,tomorrow:Bu,tube:ju,twilight:$u},ra=na.default,Fr=Object.keys(ra),Wu=e=>e<.25?1:e<.5?.9-e:1.1-e,Uu=e=>{const t=ur(e),[n,r,i]=ru(t.array()),o=[Wu(n),r,i],a=nu(o);return ur.rgb(a).hex()},We=e=>t=>({className:[t.className,e.className].filter(Boolean).join(" "),style:{...t.style||{},...e.style||{}}}),Hu=(e,t)=>{if(e===void 0)return t;if(t===void 0)return e;const n=typeof e,r=typeof t;switch(n){case"string":switch(r){case"string":return[t,e].filter(Boolean).join(" ");case"object":return We({className:e,style:t});case"function":return(i,...o)=>We({className:e})(t(i,...o))}break;case"object":switch(r){case"string":return We({className:t,style:e});case"object":return{...t,...e};case"function":return(i,...o)=>We({style:e})(t(i,...o))}break;case"function":switch(r){case"string":return(i,...o)=>e(We(i)({className:t}),...o);case"object":return(i,...o)=>e(We(i)({style:t}),...o);case"function":return(i,...o)=>e(t(i,...o),...o)}}},qu=(e,t)=>{const n=Object.keys(t);for(const r in e)n.indexOf(r)===-1&&n.push(r);return n.reduce((r,i)=>(r[i]=Hu(e[i],t[i]),r),{})},Vu=(e,t,...n)=>{if(t===null)return e;Array.isArray(t)||(t=[t]);const i=t.map(o=>e[o]).filter(Boolean).reduce((o,a)=>(typeof a=="string"?o.className=[o.className,a].filter(Boolean).join(" "):typeof a=="object"?o.style={...o.style,...a}:typeof a=="function"&&(o={...o,...a(o,...n)}),o),{className:"",style:{}});return i.className||delete i.className,Object.keys(i.style).length===0&&delete i.style,i},vn=e=>Object.keys(e).reduce((t,n)=>(t[n]=/^base/.test(n)?Uu(e[n]):n==="scheme"?e[n]+":inverted":e[n],t),{}),Gu=Rt((e,t={},n={},...r)=>{const{defaultBase16:i=ra,base16Themes:o=null}=t,a=Yu(n,o);a&&(n={...a,...n});const l=Fr.reduce((c,p)=>(c[p]=n[p]||i[p],c),{}),s=Object.keys(n).reduce((c,p)=>(Fr.indexOf(p)===-1&&(c[p]=n[p]),c),{}),u=e(l),f=qu(s,u);return Rt(Vu,2)(f,...r)},3),ia=e=>!!e.extend,Yu=(e,t)=>{if(e&&ia(e)&&e.extend&&(e=e.extend),typeof e=="string"){const[n,r]=e.split(":");t?e=t[n]:e=na[n],r==="inverted"&&(e=vn(e))}return e&&Object.prototype.hasOwnProperty.call(e,"base00")?e:void 0},Xu=e=>typeof e=="string"?`${e}:inverted`:e&&ia(e)&&e.extend?typeof e.extend=="string"?{...e,extend:`${e.extend}:inverted`}:{...e,extend:vn(e.extend)}:e&&vn(e);function Ju(e){const t=Object.prototype.toString.call(e).slice(8,-1);return t==="Object"&&typeof e[Symbol.iterator]=="function"?"Iterable":t==="Custom"&&e.constructor!==Object&&e instanceof Object?"Object":t}function aa({styling:e,arrowStyle:t="single",expanded:n,nodeType:r,onClick:i}){return R.createElement("div",{...e("arrowContainer",t),onClick:i},R.createElement("div",{...e(["arrow","arrowSign"],r,n,t)},"▶",t==="double"&&R.createElement("div",{...e(["arrowSign","arrowSignInner"])},"▶")))}function Ku(e,t){return e==="Object"?Object.keys(t).length:e==="Array"?t.length:1/0}function Qu(e){return typeof e.set=="function"}function Zu(e,t,n,r=0,i=1/0){let o;if(e==="Object"){let a=Object.getOwnPropertyNames(t);n&&a.sort(n===!0?void 0:n),a=a.slice(r,i+1),o={entries:a.map(l=>({key:l,value:t[l]}))}}else if(e==="Array")o={entries:t.slice(r,i+1).map((a,l)=>({key:l+r,value:a}))};else{let a=0;const l=[];let s=!0;const u=Qu(t);for(const f of t){if(a>i){s=!1;break}r<=a&&(u&&Array.isArray(f)?typeof f[0]=="string"||typeof f[0]=="number"?l.push({key:f[0],value:f[1]}):l.push({key:`[entry ${a}]`,value:{"[key]":f[0],"[value]":f[1]}}):l.push({key:a,value:f})),a++}o={hasMore:!s,entries:l}}return o}function tn(e,t,n){const r=[];for(;t-e>n*n;)n=n*n;for(let i=e;i<=t;i+=n)r.push({from:i,to:Math.min(t,i+n-1)});return r}function ec(e,t,n,r,i=0,o=1/0){const a=Zu.bind(null,e,t,n);if(!r)return a().entries;const l=o<1/0,s=Math.min(o-i,Ku(e,t));if(e!=="Iterable"){if(s<=r||r<7)return a(i,o).entries}else if(s<=r&&!l)return a(i,o).entries;let u;if(e==="Iterable"){const{hasMore:f,entries:c}=a(i,i+r-1);u=f?[...c,...tn(i+r,i+2*r-1,r)]:c}else u=l?tn(i,o,r):[...a(0,r-5).entries,...tn(r-4,s-5,r),...a(s-4,s-1).entries];return u}function tc(e){const{styling:t,from:n,to:r,renderChildNodes:i,nodeType:o}=e,[a,l]=te.useState(!1),s=te.useCallback(()=>{l(!a)},[a]);return a?R.createElement("div",{...t("itemRange",a)},i(e,n,r)):R.createElement("div",{...t("itemRange",a),onClick:s},R.createElement(aa,{nodeType:o,styling:t,expanded:!1,onClick:s,arrowStyle:"double"}),`${n} ... ${r}`)}function nc(e){return e.to!==void 0}function oa(e,t,n){const{nodeType:r,data:i,collectionLimit:o,circularCache:a,keyPath:l,postprocessValue:s,sortObjectKeys:u}=e,f=[];return ec(r,i,u,o,t,n).forEach(c=>{if(nc(c))f.push(R.createElement(tc,{...e,key:`ItemRange--${c.from}-${c.to}`,from:c.from,to:c.to,renderChildNodes:oa}));else{const{key:p,value:h}=c,d=a.indexOf(h)!==-1;f.push(R.createElement(la,{...e,postprocessValue:s,collectionLimit:o,key:`Node--${p}`,keyPath:[p,...l],value:s(h),circularCache:[...a,h],isCircular:d,hideRoot:!1}))}}),f}function Rn(e){const{circularCache:t=[],collectionLimit:n,createItemString:r,data:i,expandable:o,getItemString:a,hideRoot:l,isCircular:s,keyPath:u,labelRenderer:f,level:c=0,nodeType:p,nodeTypeIndicator:h,shouldExpandNodeInitially:d,styling:g}=e,[C,y]=te.useState(s?!1:d(u,i,c)),v=te.useCallback(()=>{o&&y(!C)},[o,C]),S=C||l&&c===0?oa({...e,circularCache:t,level:c+1}):null,P=R.createElement("span",{...g("nestedNodeItemType",C)},h),D=a(p,i,P,r(i,n),u),k=[u,p,C,o];return l?R.createElement("li",{...g("rootNode",...k)},R.createElement("ul",{...g("rootNodeChildren",...k)},S)):R.createElement("li",{...g("nestedNode",...k)},o&&R.createElement(aa,{styling:g,nodeType:p,expanded:C,onClick:v}),R.createElement("label",{...g(["label","nestedNodeLabel"],...k),onClick:v},f(...k)),R.createElement("span",{...g("nestedNodeItemString",...k),onClick:v},D),R.createElement("ul",{...g("nestedNodeChildren",...k)},S))}function rc(e){const t=Object.getOwnPropertyNames(e).length;return`${t} ${t!==1?"keys":"key"}`}function ic({data:e,...t}){return R.createElement(Rn,{...t,data:e,nodeType:"Object",nodeTypeIndicator:t.nodeType==="Error"?"Error()":"{}",createItemString:rc,expandable:Object.getOwnPropertyNames(e).length>0})}function ac(e){return`${e.length} ${e.length!==1?"items":"item"}`}function oc({data:e,...t}){return R.createElement(Rn,{...t,data:e,nodeType:"Array",nodeTypeIndicator:"[]",createItemString:ac,expandable:e.length>0})}function lc(e,t){let n=0,r=!1;if(Number.isSafeInteger(e.size))n=e.size;else for(const i of e){if(t&&n+1>t){r=!0;break}n+=1}return`${r?">":""}${n} ${n!==1?"entries":"entry"}`}function sc(e){return R.createElement(Rn,{...e,nodeType:"Iterable",nodeTypeIndicator:"()",createItemString:lc,expandable:!0})}function Ee({nodeType:e,styling:t,labelRenderer:n,keyPath:r,valueRenderer:i,value:o,valueGetter:a=l=>l}){return R.createElement("li",{...t("value",e,r)},R.createElement("label",{...t(["label","valueLabel"],e,r)},n(r,e,!1,!1)),R.createElement("span",{...t("valueText",e,r)},i(a(o),o,...r)))}function la({getItemString:e,keyPath:t,labelRenderer:n,styling:r,value:i,valueRenderer:o,isCustomNode:a,...l}){const s=a(i)?"Custom":Ju(i),u={getItemString:e,key:t[0],keyPath:t,labelRenderer:n,nodeType:s,styling:r,value:i,valueRenderer:o},f={...l,...u,data:i,isCustomNode:a};switch(s){case"Object":case"Error":case"WeakMap":case"WeakSet":return R.createElement(ic,{...f});case"Array":return R.createElement(oc,{...f});case"Iterable":case"Map":case"Set":return R.createElement(sc,{...f});case"String":return R.createElement(Ee,{...u,valueGetter:c=>`"${c}"`});case"Number":return R.createElement(Ee,{...u});case"Boolean":return R.createElement(Ee,{...u,valueGetter:c=>c?"true":"false"});case"Date":return R.createElement(Ee,{...u,valueGetter:c=>c.toISOString()});case"Null":return R.createElement(Ee,{...u,valueGetter:()=>"null"});case"Undefined":return R.createElement(Ee,{...u,valueGetter:()=>"undefined"});case"Function":case"Symbol":return R.createElement(Ee,{...u,valueGetter:c=>c.toString()});case"Custom":return R.createElement(Ee,{...u});default:return R.createElement(Ee,{...u,valueGetter:()=>`<${s}>`})}}const uc={scheme:"solarized",author:"ethan schoonover (http://ethanschoonover.com/solarized)",base00:"#002b36",base01:"#073642",base02:"#586e75",base03:"#657b83",base04:"#839496",base05:"#93a1a1",base06:"#eee8d5",base07:"#fdf6e3",base08:"#dc322f",base09:"#cb4b16",base0A:"#b58900",base0B:"#859900",base0C:"#2aa198",base0D:"#268bd2",base0E:"#6c71c4",base0F:"#d33682"},cc=e=>({BACKGROUND_COLOR:e.base00,TEXT_COLOR:e.base07,STRING_COLOR:e.base0B,DATE_COLOR:e.base0B,NUMBER_COLOR:e.base09,BOOLEAN_COLOR:e.base09,NULL_COLOR:e.base08,UNDEFINED_COLOR:e.base08,FUNCTION_COLOR:e.base08,SYMBOL_COLOR:e.base08,LABEL_COLOR:e.base0D,ARROW_COLOR:e.base0D,ITEM_STRING_COLOR:e.base0B,ITEM_STRING_EXPANDED_COLOR:e.base03}),fc=e=>({String:e.STRING_COLOR,Date:e.DATE_COLOR,Number:e.NUMBER_COLOR,Boolean:e.BOOLEAN_COLOR,Null:e.NULL_COLOR,Undefined:e.UNDEFINED_COLOR,Function:e.FUNCTION_COLOR,Symbol:e.SYMBOL_COLOR}),hc=e=>{const t=cc(e);return{tree:{border:0,padding:0,marginTop:"0.5em",marginBottom:"0.5em",marginLeft:"0.125em",marginRight:0,listStyle:"none",MozUserSelect:"none",WebkitUserSelect:"none",backgroundColor:t.BACKGROUND_COLOR},value:({style:n},r,i)=>({style:{...n,paddingTop:"0.25em",paddingRight:0,marginLeft:"0.875em",WebkitUserSelect:"text",MozUserSelect:"text",wordWrap:"break-word",paddingLeft:i.length>1?"2.125em":"1.25em",textIndent:"-0.5em",wordBreak:"break-all"}}),label:{display:"inline-block",color:t.LABEL_COLOR},valueLabel:{margin:"0 0.5em 0 0"},valueText:({style:n},r)=>({style:{...n,color:fc(t)[r]}}),itemRange:(n,r)=>({style:{paddingTop:r?0:"0.25em",cursor:"pointer",color:t.LABEL_COLOR}}),arrow:({style:n},r,i)=>({style:{...n,marginLeft:0,transition:"150ms",WebkitTransition:"150ms",MozTransition:"150ms",WebkitTransform:i?"rotateZ(90deg)":"rotateZ(0deg)",MozTransform:i?"rotateZ(90deg)":"rotateZ(0deg)",transform:i?"rotateZ(90deg)":"rotateZ(0deg)",transformOrigin:"45% 50%",WebkitTransformOrigin:"45% 50%",MozTransformOrigin:"45% 50%",position:"relative",lineHeight:"1.1em",fontSize:"0.75em"}}),arrowContainer:({style:n},r)=>({style:{...n,display:"inline-block",paddingRight:"0.5em",paddingLeft:r==="double"?"1em":0,cursor:"pointer"}}),arrowSign:{color:t.ARROW_COLOR},arrowSignInner:{position:"absolute",top:0,left:"-0.4em"},nestedNode:({style:n},r,i,o,a)=>({style:{...n,position:"relative",paddingTop:"0.25em",marginLeft:r.length>1?"0.875em":0,paddingLeft:a?0:"1.125em"}}),rootNode:{padding:0,margin:0},nestedNodeLabel:({style:n},r,i,o,a)=>({style:{...n,margin:0,padding:0,WebkitUserSelect:a?"inherit":"text",MozUserSelect:a?"inherit":"text",cursor:a?"pointer":"default"}}),nestedNodeItemString:({style:n},r,i,o)=>({style:{...n,paddingLeft:"0.5em",cursor:"default",color:o?t.ITEM_STRING_EXPANDED_COLOR:t.ITEM_STRING_COLOR}}),nestedNodeItemType:{marginLeft:"0.3em",marginRight:"0.3em"},nestedNodeChildren:({style:n},r,i)=>({style:{...n,padding:0,margin:0,listStyle:"none",display:i?"block":"none"}}),rootNodeChildren:{padding:0,margin:0,listStyle:"none"}}},pc=Gu(hc,{defaultBase16:uc}),Dr=e=>e,dc=(e,t,n)=>n===0,mc=(e,t,n,r)=>R.createElement("span",null,n," ",r),bc=([e])=>R.createElement("span",null,e,":"),gc=()=>!1;function yc({data:e,theme:t,invertTheme:n,keyPath:r=["root"],labelRenderer:i=bc,valueRenderer:o=Dr,shouldExpandNodeInitially:a=dc,hideRoot:l=!1,getItemString:s=mc,postprocessValue:u=Dr,isCustomNode:f=gc,collectionLimit:c=50,sortObjectKeys:p=!1}){const h=te.useMemo(()=>pc(n?Xu(t):t),[t,n]);return R.createElement("ul",{...h("tree")},R.createElement(la,{keyPath:l?[]:r,value:u(e),isCustomNode:f,styling:h,labelRenderer:i,valueRenderer:o,shouldExpandNodeInitially:a,hideRoot:l,getItemString:s,postprocessValue:u,collectionLimit:c,sortObjectKeys:p}))}function xc(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const kc=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,wc=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,vc={};function _r(e,t){return(vc.jsx?wc:kc).test(e)}const Cc=/[ \t\n\f\r]/g;function Sc(e){return typeof e=="object"?e.type==="text"?Tr(e.value):!1:Tr(e)}function Tr(e){return e.replace(Cc,"")===""}class gt{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}gt.prototype.property={};gt.prototype.normal={};gt.prototype.space=null;function sa(e,t){const n={},r={};let i=-1;for(;++i<e.length;)Object.assign(n,e[i].property),Object.assign(r,e[i].normal);return new gt(n,r,t)}function Cn(e){return e.toLowerCase()}class pe{constructor(t,n){this.property=t,this.attribute=n}}pe.prototype.space=null;pe.prototype.boolean=!1;pe.prototype.booleanish=!1;pe.prototype.overloadedBoolean=!1;pe.prototype.number=!1;pe.prototype.commaSeparated=!1;pe.prototype.spaceSeparated=!1;pe.prototype.commaOrSpaceSeparated=!1;pe.prototype.mustUseProperty=!1;pe.prototype.defined=!1;let Ec=0;const O=Ne(),J=Ne(),ua=Ne(),E=Ne(),G=Ne(),Ge=Ne(),se=Ne();function Ne(){return 2**++Ec}const Sn=Object.freeze(Object.defineProperty({__proto__:null,boolean:O,booleanish:J,commaOrSpaceSeparated:se,commaSeparated:Ge,number:E,overloadedBoolean:ua,spaceSeparated:G},Symbol.toStringTag,{value:"Module"})),nn=Object.keys(Sn);class zn extends pe{constructor(t,n,r,i){let o=-1;if(super(t,n),Pr(this,"space",i),typeof r=="number")for(;++o<nn.length;){const a=nn[o];Pr(this,nn[o],(r&Sn[a])===Sn[a])}}}zn.prototype.defined=!0;function Pr(e,t,n){n&&(e[t]=n)}const Ac={}.hasOwnProperty;function Qe(e){const t={},n={};let r;for(r in e.properties)if(Ac.call(e.properties,r)){const i=e.properties[r],o=new zn(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(o.mustUseProperty=!0),t[r]=o,n[Cn(r)]=r,n[Cn(o.attribute)]=r}return new gt(t,n,e.space)}const ca=Qe({space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),fa=Qe({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function ha(e,t){return t in e?e[t]:t}function pa(e,t){return ha(e,t.toLowerCase())}const da=Qe({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:pa,properties:{xmlns:null,xmlnsXLink:null}}),ma=Qe({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:J,ariaAutoComplete:null,ariaBusy:J,ariaChecked:J,ariaColCount:E,ariaColIndex:E,ariaColSpan:E,ariaControls:G,ariaCurrent:null,ariaDescribedBy:G,ariaDetails:null,ariaDisabled:J,ariaDropEffect:G,ariaErrorMessage:null,ariaExpanded:J,ariaFlowTo:G,ariaGrabbed:J,ariaHasPopup:null,ariaHidden:J,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:G,ariaLevel:E,ariaLive:null,ariaModal:J,ariaMultiLine:J,ariaMultiSelectable:J,ariaOrientation:null,ariaOwns:G,ariaPlaceholder:null,ariaPosInSet:E,ariaPressed:J,ariaReadOnly:J,ariaRelevant:null,ariaRequired:J,ariaRoleDescription:G,ariaRowCount:E,ariaRowIndex:E,ariaRowSpan:E,ariaSelected:J,ariaSetSize:E,ariaSort:null,ariaValueMax:E,ariaValueMin:E,ariaValueNow:E,ariaValueText:null,role:null}}),Ic=Qe({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:pa,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Ge,acceptCharset:G,accessKey:G,action:null,allow:null,allowFullScreen:O,allowPaymentRequest:O,allowUserMedia:O,alt:null,as:null,async:O,autoCapitalize:null,autoComplete:G,autoFocus:O,autoPlay:O,blocking:G,capture:null,charSet:null,checked:O,cite:null,className:G,cols:E,colSpan:null,content:null,contentEditable:J,controls:O,controlsList:G,coords:E|Ge,crossOrigin:null,data:null,dateTime:null,decoding:null,default:O,defer:O,dir:null,dirName:null,disabled:O,download:ua,draggable:J,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:O,formTarget:null,headers:G,height:E,hidden:O,high:E,href:null,hrefLang:null,htmlFor:G,httpEquiv:G,id:null,imageSizes:null,imageSrcSet:null,inert:O,inputMode:null,integrity:null,is:null,isMap:O,itemId:null,itemProp:G,itemRef:G,itemScope:O,itemType:G,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:O,low:E,manifest:null,max:null,maxLength:E,media:null,method:null,min:null,minLength:E,multiple:O,muted:O,name:null,nonce:null,noModule:O,noValidate:O,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:O,optimum:E,pattern:null,ping:G,placeholder:null,playsInline:O,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:O,referrerPolicy:null,rel:G,required:O,reversed:O,rows:E,rowSpan:E,sandbox:G,scope:null,scoped:O,seamless:O,selected:O,shadowRootClonable:O,shadowRootDelegatesFocus:O,shadowRootMode:null,shape:null,size:E,sizes:null,slot:null,span:E,spellCheck:J,src:null,srcDoc:null,srcLang:null,srcSet:null,start:E,step:null,style:null,tabIndex:E,target:null,title:null,translate:null,type:null,typeMustMatch:O,useMap:null,value:J,width:E,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:G,axis:null,background:null,bgColor:null,border:E,borderColor:null,bottomMargin:E,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:O,declare:O,event:null,face:null,frame:null,frameBorder:null,hSpace:E,leftMargin:E,link:null,longDesc:null,lowSrc:null,marginHeight:E,marginWidth:E,noResize:O,noHref:O,noShade:O,noWrap:O,object:null,profile:null,prompt:null,rev:null,rightMargin:E,rules:null,scheme:null,scrolling:J,standby:null,summary:null,text:null,topMargin:E,valueType:null,version:null,vAlign:null,vLink:null,vSpace:E,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:O,disableRemotePlayback:O,prefix:null,property:null,results:E,security:null,unselectable:null}}),Fc=Qe({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:ha,properties:{about:se,accentHeight:E,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:E,amplitude:E,arabicForm:null,ascent:E,attributeName:null,attributeType:null,azimuth:E,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:E,by:null,calcMode:null,capHeight:E,className:G,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:E,diffuseConstant:E,direction:null,display:null,dur:null,divisor:E,dominantBaseline:null,download:O,dx:null,dy:null,edgeMode:null,editable:null,elevation:E,enableBackground:null,end:null,event:null,exponent:E,externalResourcesRequired:null,fill:null,fillOpacity:E,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Ge,g2:Ge,glyphName:Ge,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:E,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:E,horizOriginX:E,horizOriginY:E,id:null,ideographic:E,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:E,k:E,k1:E,k2:E,k3:E,k4:E,kernelMatrix:se,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:E,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:E,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:E,overlineThickness:E,paintOrder:null,panose1:null,path:null,pathLength:E,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:G,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:E,pointsAtY:E,pointsAtZ:E,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:se,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:se,rev:se,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:se,requiredFeatures:se,requiredFonts:se,requiredFormats:se,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:E,specularExponent:E,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:E,strikethroughThickness:E,string:null,stroke:null,strokeDashArray:se,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:E,strokeOpacity:E,strokeWidth:null,style:null,surfaceScale:E,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:se,tabIndex:E,tableValues:null,target:null,targetX:E,targetY:E,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:se,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:E,underlineThickness:E,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:E,values:null,vAlphabetic:E,vMathematical:E,vectorEffect:null,vHanging:E,vIdeographic:E,version:null,vertAdvY:E,vertOriginX:E,vertOriginY:E,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:E,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),Dc=/^data[-\w.:]+$/i,Lr=/-[a-z]/g,_c=/[A-Z]/g;function Tc(e,t){const n=Cn(t);let r=t,i=pe;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&Dc.test(t)){if(t.charAt(4)==="-"){const o=t.slice(5).replace(Lr,Lc);r="data"+o.charAt(0).toUpperCase()+o.slice(1)}else{const o=t.slice(4);if(!Lr.test(o)){let a=o.replace(_c,Pc);a.charAt(0)!=="-"&&(a="-"+a),t="data"+a}}i=zn}return new i(r,t)}function Pc(e){return"-"+e.toLowerCase()}function Lc(e){return e.charAt(1).toUpperCase()}const Oc={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},Mc=sa([fa,ca,da,ma,Ic],"html"),Nn=sa([fa,ca,da,ma,Fc],"svg");function Rc(e){return e.join(" ").trim()}var ba={},Or=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,zc=/\n/g,Nc=/^\s*/,Bc=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,jc=/^:\s*/,$c=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,Wc=/^[;\s]*/,Uc=/^\s+|\s+$/g,Hc=`
`,Mr="/",Rr="*",Me="",qc="comment",Vc="declaration",Gc=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function i(d){var g=d.match(zc);g&&(n+=g.length);var C=d.lastIndexOf(Hc);r=~C?d.length-C:r+d.length}function o(){var d={line:n,column:r};return function(g){return g.position=new a(d),u(),g}}function a(d){this.start=d,this.end={line:n,column:r},this.source=t.source}a.prototype.content=e;function l(d){var g=new Error(t.source+":"+n+":"+r+": "+d);if(g.reason=d,g.filename=t.source,g.line=n,g.column=r,g.source=e,!t.silent)throw g}function s(d){var g=d.exec(e);if(g){var C=g[0];return i(C),e=e.slice(C.length),g}}function u(){s(Nc)}function f(d){var g;for(d=d||[];g=c();)g!==!1&&d.push(g);return d}function c(){var d=o();if(!(Mr!=e.charAt(0)||Rr!=e.charAt(1))){for(var g=2;Me!=e.charAt(g)&&(Rr!=e.charAt(g)||Mr!=e.charAt(g+1));)++g;if(g+=2,Me===e.charAt(g-1))return l("End of comment missing");var C=e.slice(2,g-2);return r+=2,i(C),e=e.slice(g),r+=2,d({type:qc,comment:C})}}function p(){var d=o(),g=s(Bc);if(g){if(c(),!s(jc))return l("property missing ':'");var C=s($c),y=d({type:Vc,property:zr(g[0].replace(Or,Me)),value:C?zr(C[0].replace(Or,Me)):Me});return s(Wc),y}}function h(){var d=[];f(d);for(var g;g=p();)g!==!1&&(d.push(g),f(d));return d}return u(),h()};function zr(e){return e?e.replace(Uc,Me):Me}var Yc=lr&&lr.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ba,"__esModule",{value:!0});var Nr=ba.default=Jc,Xc=Yc(Gc);function Jc(e,t){var n=null;if(!e||typeof e!="string")return n;var r=(0,Xc.default)(e),i=typeof t=="function";return r.forEach(function(o){if(o.type==="declaration"){var a=o.property,l=o.value;i?t(a,l,o):l&&(n=n||{},n[a]=l)}}),n}const Kc=Nr.default||Nr,ga=ya("end"),Bn=ya("start");function ya(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function Qc(e){const t=Bn(e),n=ga(e);if(t&&n)return{start:t,end:n}}function ct(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?Br(e.position):"start"in e||"end"in e?Br(e):"line"in e||"column"in e?En(e):""}function En(e){return jr(e&&e.line)+":"+jr(e&&e.column)}function Br(e){return En(e&&e.start)+"-"+En(e&&e.end)}function jr(e){return e&&typeof e=="number"?e:1}class ie extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let i="",o={},a=!1;if(n&&("line"in n&&"column"in n?o={place:n}:"start"in n&&"end"in n?o={place:n}:"type"in n?o={ancestors:[n],place:n.position}:o={...n}),typeof t=="string"?i=t:!o.cause&&t&&(a=!0,i=t.message,o.cause=t),!o.ruleId&&!o.source&&typeof r=="string"){const s=r.indexOf(":");s===-1?o.ruleId=r:(o.source=r.slice(0,s),o.ruleId=r.slice(s+1))}if(!o.place&&o.ancestors&&o.ancestors){const s=o.ancestors[o.ancestors.length-1];s&&(o.place=s.position)}const l=o.place&&"start"in o.place?o.place.start:o.place;this.ancestors=o.ancestors||void 0,this.cause=o.cause||void 0,this.column=l?l.column:void 0,this.fatal=void 0,this.file,this.message=i,this.line=l?l.line:void 0,this.name=ct(o.place)||"1:1",this.place=o.place||void 0,this.reason=this.message,this.ruleId=o.ruleId||void 0,this.source=o.source||void 0,this.stack=a&&o.cause&&typeof o.cause.stack=="string"?o.cause.stack:"",this.actual,this.expected,this.note,this.url}}ie.prototype.file="";ie.prototype.name="";ie.prototype.reason="";ie.prototype.message="";ie.prototype.stack="";ie.prototype.column=void 0;ie.prototype.line=void 0;ie.prototype.ancestors=void 0;ie.prototype.cause=void 0;ie.prototype.fatal=void 0;ie.prototype.place=void 0;ie.prototype.ruleId=void 0;ie.prototype.source=void 0;const jn={}.hasOwnProperty,Zc=new Map,ef=/[A-Z]/g,tf=/-([a-z])/g,nf=new Set(["table","tbody","thead","tfoot","tr"]),rf=new Set(["td","th"]),xa="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function af(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=pf(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=hf(n,t.jsx,t.jsxs)}const i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?Nn:Mc,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},o=ka(i,e,void 0);return o&&typeof o!="string"?o:i.create(e,i.Fragment,{children:o||void 0},void 0)}function ka(e,t,n){if(t.type==="element")return of(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return lf(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return uf(e,t,n);if(t.type==="mdxjsEsm")return sf(e,t);if(t.type==="root")return cf(e,t,n);if(t.type==="text")return ff(e,t)}function of(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=Nn,e.schema=i),e.ancestors.push(t);const o=va(e,t.tagName,!1),a=df(e,t);let l=Wn(e,t);return nf.has(t.tagName)&&(l=l.filter(function(s){return typeof s=="string"?!Sc(s):!0})),wa(e,a,o,t),$n(a,l),e.ancestors.pop(),e.schema=r,e.create(t,o,a,n)}function lf(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return r.type,e.evaluater.evaluateExpression(r.expression)}dt(e,t.position)}function sf(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);dt(e,t.position)}function uf(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=Nn,e.schema=i),e.ancestors.push(t);const o=t.name===null?e.Fragment:va(e,t.name,!0),a=mf(e,t),l=Wn(e,t);return wa(e,a,o,t),$n(a,l),e.ancestors.pop(),e.schema=r,e.create(t,o,a,n)}function cf(e,t,n){const r={};return $n(r,Wn(e,t)),e.create(t,e.Fragment,r,n)}function ff(e,t){return t.value}function wa(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function $n(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function hf(e,t,n){return r;function r(i,o,a,l){const u=Array.isArray(a.children)?n:t;return l?u(o,a,l):u(o,a)}}function pf(e,t){return n;function n(r,i,o,a){const l=Array.isArray(o.children),s=Bn(r);return t(i,o,a,l,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.line:void 0},void 0)}}function df(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&jn.call(t.properties,i)){const o=bf(e,i,t.properties[i]);if(o){const[a,l]=o;e.tableCellAlignToStyle&&a==="align"&&typeof l=="string"&&rf.has(t.tagName)?r=l:n[a]=l}}if(r){const o=n.style||(n.style={});o[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function mf(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const o=r.data.estree.body[0];o.type;const a=o.expression;a.type;const l=a.properties[0];l.type,Object.assign(n,e.evaluater.evaluateExpression(l.argument))}else dt(e,t.position);else{const i=r.name;let o;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const l=r.value.data.estree.body[0];l.type,o=e.evaluater.evaluateExpression(l.expression)}else dt(e,t.position);else o=r.value===null?!0:r.value;n[i]=o}return n}function Wn(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:Zc;for(;++r<t.children.length;){const o=t.children[r];let a;if(e.passKeys){const s=o.type==="element"?o.tagName:o.type==="mdxJsxFlowElement"||o.type==="mdxJsxTextElement"?o.name:void 0;if(s){const u=i.get(s)||0;a=s+"-"+u,i.set(s,u+1)}}const l=ka(e,o,a);l!==void 0&&n.push(l)}return n}function bf(e,t,n){const r=Tc(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?xc(n):Rc(n)),r.property==="style"){let i=typeof n=="object"?n:gf(e,String(n));return e.stylePropertyNameCase==="css"&&(i=yf(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?Oc[r.property]||r.property:r.attribute,n]}}function gf(e,t){const n={};try{Kc(t,r)}catch(i){if(!e.ignoreInvalidStyle){const o=i,a=new ie("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:o,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw a.file=e.filePath||void 0,a.url=xa+"#cannot-parse-style-attribute",a}}return n;function r(i,o){let a=i;a.slice(0,2)!=="--"&&(a.slice(0,4)==="-ms-"&&(a="ms-"+a.slice(4)),a=a.replace(tf,kf)),n[a]=o}}function va(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const i=t.split(".");let o=-1,a;for(;++o<i.length;){const l=_r(i[o])?{type:"Identifier",name:i[o]}:{type:"Literal",value:i[o]};a=a?{type:"MemberExpression",object:a,property:l,computed:!!(o&&l.type==="Literal"),optional:!1}:l}r=a}else r=_r(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return jn.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);dt(e)}function dt(e,t){const n=new ie("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=xa+"#cannot-handle-mdx-estrees-without-createevaluater",n}function yf(e){const t={};let n;for(n in e)jn.call(e,n)&&(t[xf(n)]=e[n]);return t}function xf(e){let t=e.replace(ef,wf);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function kf(e,t){return t.toUpperCase()}function wf(e){return"-"+e.toLowerCase()}const rn={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},vf={};function Un(e,t){const n=vf,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return Ca(e,r,i)}function Ca(e,t,n){if(Cf(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return $r(e.children,t,n)}return Array.isArray(e)?$r(e,t,n):""}function $r(e,t,n){const r=[];let i=-1;for(;++i<e.length;)r[i]=Ca(e[i],t,n);return r.join("")}function Cf(e){return!!(e&&typeof e=="object")}const Wr=document.createElement("i");function Hn(e){const t="&"+e+";";Wr.innerHTML=t;const n=Wr.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function fe(e,t,n,r){const i=e.length;let o=0,a;if(t<0?t=-t>i?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)a=Array.from(r),a.unshift(t,n),e.splice(...a);else for(n&&e.splice(t,n);o<r.length;)a=r.slice(o,o+1e4),a.unshift(t,0),e.splice(...a),o+=1e4,t+=1e4}function he(e,t){return e.length>0?(fe(e,e.length,0,t),e):t}const Ur={}.hasOwnProperty;function Sa(e){const t={};let n=-1;for(;++n<e.length;)Sf(t,e[n]);return t}function Sf(e,t){let n;for(n in t){const i=(Ur.call(e,n)?e[n]:void 0)||(e[n]={}),o=t[n];let a;if(o)for(a in o){Ur.call(i,a)||(i[a]=[]);const l=o[a];Ef(i[a],Array.isArray(l)?l:l?[l]:[])}}}function Ef(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);fe(e,0,0,r)}function Ea(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function ye(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const ae=Te(/[A-Za-z]/),re=Te(/[\dA-Za-z]/),Af=Te(/[#-'*+\--9=?A-Z^-~]/);function zt(e){return e!==null&&(e<32||e===127)}const An=Te(/\d/),If=Te(/[\dA-Fa-f]/),Ff=Te(/[!-/:-@[-`{-~]/);function T(e){return e!==null&&e<-2}function V(e){return e!==null&&(e<0||e===32)}function N(e){return e===-2||e===-1||e===32}const Ut=Te(new RegExp("\\p{P}|\\p{S}","u")),Re=Te(/\s/);function Te(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function Ze(e){const t=[];let n=-1,r=0,i=0;for(;++n<e.length;){const o=e.charCodeAt(n);let a="";if(o===37&&re(e.charCodeAt(n+1))&&re(e.charCodeAt(n+2)))i=2;else if(o<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(o))||(a=String.fromCharCode(o));else if(o>55295&&o<57344){const l=e.charCodeAt(n+1);o<56320&&l>56319&&l<57344?(a=String.fromCharCode(o,l),i=1):a="�"}else a=String.fromCharCode(o);a&&(t.push(e.slice(r,n),encodeURIComponent(a)),r=n+i+1,a=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function j(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let o=0;return a;function a(s){return N(s)?(e.enter(n),l(s)):t(s)}function l(s){return N(s)&&o++<i?(e.consume(s),l):(e.exit(n),t(s))}}const Df={tokenize:_f};function _f(e){const t=e.attempt(this.parser.constructs.contentInitial,r,i);let n;return t;function r(l){if(l===null){e.consume(l);return}return e.enter("lineEnding"),e.consume(l),e.exit("lineEnding"),j(e,t,"linePrefix")}function i(l){return e.enter("paragraph"),o(l)}function o(l){const s=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=s),n=s,a(l)}function a(l){if(l===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(l);return}return T(l)?(e.consume(l),e.exit("chunkText"),o):(e.consume(l),a)}}const Tf={tokenize:Pf},Hr={tokenize:Lf};function Pf(e){const t=this,n=[];let r=0,i,o,a;return l;function l(S){if(r<n.length){const P=n[r];return t.containerState=P[1],e.attempt(P[0].continuation,s,u)(S)}return u(S)}function s(S){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&v();const P=t.events.length;let D=P,k;for(;D--;)if(t.events[D][0]==="exit"&&t.events[D][1].type==="chunkFlow"){k=t.events[D][1].end;break}y(r);let M=P;for(;M<t.events.length;)t.events[M][1].end={...k},M++;return fe(t.events,D+1,0,t.events.slice(P)),t.events.length=M,u(S)}return l(S)}function u(S){if(r===n.length){if(!i)return p(S);if(i.currentConstruct&&i.currentConstruct.concrete)return d(S);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(Hr,f,c)(S)}function f(S){return i&&v(),y(r),p(S)}function c(S){return t.parser.lazy[t.now().line]=r!==n.length,a=t.now().offset,d(S)}function p(S){return t.containerState={},e.attempt(Hr,h,d)(S)}function h(S){return r++,n.push([t.currentConstruct,t.containerState]),p(S)}function d(S){if(S===null){i&&v(),y(0),e.consume(S);return}return i=i||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:i,contentType:"flow",previous:o}),g(S)}function g(S){if(S===null){C(e.exit("chunkFlow"),!0),y(0),e.consume(S);return}return T(S)?(e.consume(S),C(e.exit("chunkFlow")),r=0,t.interrupt=void 0,l):(e.consume(S),g)}function C(S,P){const D=t.sliceStream(S);if(P&&D.push(null),S.previous=o,o&&(o.next=S),o=S,i.defineSkip(S.start),i.write(D),t.parser.lazy[S.start.line]){let k=i.events.length;for(;k--;)if(i.events[k][1].start.offset<a&&(!i.events[k][1].end||i.events[k][1].end.offset>a))return;const M=t.events.length;let W=M,U,x;for(;W--;)if(t.events[W][0]==="exit"&&t.events[W][1].type==="chunkFlow"){if(U){x=t.events[W][1].end;break}U=!0}for(y(r),k=M;k<t.events.length;)t.events[k][1].end={...x},k++;fe(t.events,W+1,0,t.events.slice(M)),t.events.length=k}}function y(S){let P=n.length;for(;P-- >S;){const D=n[P];t.containerState=D[1],D[0].exit.call(t,e)}n.length=S}function v(){i.write([null]),o=void 0,i=void 0,t.containerState._closeFlow=void 0}}function Lf(e,t,n){return j(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function Ke(e){if(e===null||V(e)||Re(e))return 1;if(Ut(e))return 2}function Ht(e,t,n){const r=[];let i=-1;for(;++i<e.length;){const o=e[i].resolveAll;o&&!r.includes(o)&&(t=o(t,n),r.push(o))}return t}const In={name:"attention",resolveAll:Of,tokenize:Mf};function Of(e,t){let n=-1,r,i,o,a,l,s,u,f;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;s=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const c={...e[r][1].end},p={...e[n][1].start};qr(c,-s),qr(p,s),a={type:s>1?"strongSequence":"emphasisSequence",start:c,end:{...e[r][1].end}},l={type:s>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:p},o={type:s>1?"strongText":"emphasisText",start:{...e[r][1].end},end:{...e[n][1].start}},i={type:s>1?"strong":"emphasis",start:{...a.start},end:{...l.end}},e[r][1].end={...a.start},e[n][1].start={...l.end},u=[],e[r][1].end.offset-e[r][1].start.offset&&(u=he(u,[["enter",e[r][1],t],["exit",e[r][1],t]])),u=he(u,[["enter",i,t],["enter",a,t],["exit",a,t],["enter",o,t]]),u=he(u,Ht(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),u=he(u,[["exit",o,t],["enter",l,t],["exit",l,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(f=2,u=he(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):f=0,fe(e,r-1,n-r+3,u),n=r+u.length-f-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function Mf(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=Ke(r);let o;return a;function a(s){return o=s,e.enter("attentionSequence"),l(s)}function l(s){if(s===o)return e.consume(s),l;const u=e.exit("attentionSequence"),f=Ke(s),c=!f||f===2&&i||n.includes(s),p=!i||i===2&&f||n.includes(r);return u._open=!!(o===42?c:c&&(i||!p)),u._close=!!(o===42?p:p&&(f||!c)),t(s)}}function qr(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const Rf={name:"autolink",tokenize:zf};function zf(e,t,n){let r=0;return i;function i(h){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(h),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),o}function o(h){return ae(h)?(e.consume(h),a):h===64?n(h):u(h)}function a(h){return h===43||h===45||h===46||re(h)?(r=1,l(h)):u(h)}function l(h){return h===58?(e.consume(h),r=0,s):(h===43||h===45||h===46||re(h))&&r++<32?(e.consume(h),l):(r=0,u(h))}function s(h){return h===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(h),e.exit("autolinkMarker"),e.exit("autolink"),t):h===null||h===32||h===60||zt(h)?n(h):(e.consume(h),s)}function u(h){return h===64?(e.consume(h),f):Af(h)?(e.consume(h),u):n(h)}function f(h){return re(h)?c(h):n(h)}function c(h){return h===46?(e.consume(h),r=0,f):h===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(h),e.exit("autolinkMarker"),e.exit("autolink"),t):p(h)}function p(h){if((h===45||re(h))&&r++<63){const d=h===45?p:c;return e.consume(h),d}return n(h)}}const yt={partial:!0,tokenize:Nf};function Nf(e,t,n){return r;function r(o){return N(o)?j(e,i,"linePrefix")(o):i(o)}function i(o){return o===null||T(o)?t(o):n(o)}}const Aa={continuation:{tokenize:jf},exit:$f,name:"blockQuote",tokenize:Bf};function Bf(e,t,n){const r=this;return i;function i(a){if(a===62){const l=r.containerState;return l.open||(e.enter("blockQuote",{_container:!0}),l.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(a),e.exit("blockQuoteMarker"),o}return n(a)}function o(a){return N(a)?(e.enter("blockQuotePrefixWhitespace"),e.consume(a),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(a))}}function jf(e,t,n){const r=this;return i;function i(a){return N(a)?j(e,o,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(a):o(a)}function o(a){return e.attempt(Aa,t,n)(a)}}function $f(e){e.exit("blockQuote")}const Ia={name:"characterEscape",tokenize:Wf};function Wf(e,t,n){return r;function r(o){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(o),e.exit("escapeMarker"),i}function i(o){return Ff(o)?(e.enter("characterEscapeValue"),e.consume(o),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(o)}}const Fa={name:"characterReference",tokenize:Uf};function Uf(e,t,n){const r=this;let i=0,o,a;return l;function l(c){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(c),e.exit("characterReferenceMarker"),s}function s(c){return c===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(c),e.exit("characterReferenceMarkerNumeric"),u):(e.enter("characterReferenceValue"),o=31,a=re,f(c))}function u(c){return c===88||c===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(c),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),o=6,a=If,f):(e.enter("characterReferenceValue"),o=7,a=An,f(c))}function f(c){if(c===59&&i){const p=e.exit("characterReferenceValue");return a===re&&!Hn(r.sliceSerialize(p))?n(c):(e.enter("characterReferenceMarker"),e.consume(c),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return a(c)&&i++<o?(e.consume(c),f):n(c)}}const Vr={partial:!0,tokenize:qf},Gr={concrete:!0,name:"codeFenced",tokenize:Hf};function Hf(e,t,n){const r=this,i={partial:!0,tokenize:D};let o=0,a=0,l;return s;function s(k){return u(k)}function u(k){const M=r.events[r.events.length-1];return o=M&&M[1].type==="linePrefix"?M[2].sliceSerialize(M[1],!0).length:0,l=k,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),f(k)}function f(k){return k===l?(a++,e.consume(k),f):a<3?n(k):(e.exit("codeFencedFenceSequence"),N(k)?j(e,c,"whitespace")(k):c(k))}function c(k){return k===null||T(k)?(e.exit("codeFencedFence"),r.interrupt?t(k):e.check(Vr,g,P)(k)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),p(k))}function p(k){return k===null||T(k)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),c(k)):N(k)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),j(e,h,"whitespace")(k)):k===96&&k===l?n(k):(e.consume(k),p)}function h(k){return k===null||T(k)?c(k):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),d(k))}function d(k){return k===null||T(k)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),c(k)):k===96&&k===l?n(k):(e.consume(k),d)}function g(k){return e.attempt(i,P,C)(k)}function C(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),y}function y(k){return o>0&&N(k)?j(e,v,"linePrefix",o+1)(k):v(k)}function v(k){return k===null||T(k)?e.check(Vr,g,P)(k):(e.enter("codeFlowValue"),S(k))}function S(k){return k===null||T(k)?(e.exit("codeFlowValue"),v(k)):(e.consume(k),S)}function P(k){return e.exit("codeFenced"),t(k)}function D(k,M,W){let U=0;return x;function x($){return k.enter("lineEnding"),k.consume($),k.exit("lineEnding"),F}function F($){return k.enter("codeFencedFence"),N($)?j(k,_,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)($):_($)}function _($){return $===l?(k.enter("codeFencedFenceSequence"),H($)):W($)}function H($){return $===l?(U++,k.consume($),H):U>=a?(k.exit("codeFencedFenceSequence"),N($)?j(k,Y,"whitespace")($):Y($)):W($)}function Y($){return $===null||T($)?(k.exit("codeFencedFence"),M($)):W($)}}}function qf(e,t,n){const r=this;return i;function i(a){return a===null?n(a):(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),o)}function o(a){return r.parser.lazy[r.now().line]?n(a):t(a)}}const an={name:"codeIndented",tokenize:Gf},Vf={partial:!0,tokenize:Yf};function Gf(e,t,n){const r=this;return i;function i(u){return e.enter("codeIndented"),j(e,o,"linePrefix",5)(u)}function o(u){const f=r.events[r.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?a(u):n(u)}function a(u){return u===null?s(u):T(u)?e.attempt(Vf,a,s)(u):(e.enter("codeFlowValue"),l(u))}function l(u){return u===null||T(u)?(e.exit("codeFlowValue"),a(u)):(e.consume(u),l)}function s(u){return e.exit("codeIndented"),t(u)}}function Yf(e,t,n){const r=this;return i;function i(a){return r.parser.lazy[r.now().line]?n(a):T(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),i):j(e,o,"linePrefix",5)(a)}function o(a){const l=r.events[r.events.length-1];return l&&l[1].type==="linePrefix"&&l[2].sliceSerialize(l[1],!0).length>=4?t(a):T(a)?i(a):n(a)}}const Xf={name:"codeText",previous:Kf,resolve:Jf,tokenize:Qf};function Jf(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(i=r):(r===t||e[r][1].type==="lineEnding")&&(e[i][1].type="codeTextData",r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function Kf(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function Qf(e,t,n){let r=0,i,o;return a;function a(c){return e.enter("codeText"),e.enter("codeTextSequence"),l(c)}function l(c){return c===96?(e.consume(c),r++,l):(e.exit("codeTextSequence"),s(c))}function s(c){return c===null?n(c):c===32?(e.enter("space"),e.consume(c),e.exit("space"),s):c===96?(o=e.enter("codeTextSequence"),i=0,f(c)):T(c)?(e.enter("lineEnding"),e.consume(c),e.exit("lineEnding"),s):(e.enter("codeTextData"),u(c))}function u(c){return c===null||c===32||c===96||T(c)?(e.exit("codeTextData"),s(c)):(e.consume(c),u)}function f(c){return c===96?(e.consume(c),i++,f):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(c)):(o.type="codeTextData",u(c))}}class Zf{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const i=n||0;this.setCursor(Math.trunc(t));const o=this.right.splice(this.right.length-i,Number.POSITIVE_INFINITY);return r&&at(this.left,r),o.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),at(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),at(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);at(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);at(this.left,n.reverse())}}}function at(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Da(e){const t={};let n=-1,r,i,o,a,l,s,u;const f=new Zf(e);for(;++n<f.length;){for(;n in t;)n=t[n];if(r=f.get(n),n&&r[1].type==="chunkFlow"&&f.get(n-1)[1].type==="listItemPrefix"&&(s=r[1]._tokenizer.events,o=0,o<s.length&&s[o][1].type==="lineEndingBlank"&&(o+=2),o<s.length&&s[o][1].type==="content"))for(;++o<s.length&&s[o][1].type!=="content";)s[o][1].type==="chunkText"&&(s[o][1]._isInFirstContentOfListItem=!0,o++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,eh(f,n)),n=t[n],u=!0);else if(r[1]._container){for(o=n,i=void 0;o--&&(a=f.get(o),a[1].type==="lineEnding"||a[1].type==="lineEndingBlank");)a[0]==="enter"&&(i&&(f.get(i)[1].type="lineEndingBlank"),a[1].type="lineEnding",i=o);i&&(r[1].end={...f.get(i)[1].start},l=f.slice(i,n),l.unshift(r),f.splice(i,n-i+1,l))}}return fe(e,0,Number.POSITIVE_INFINITY,f.slice(0)),!u}function eh(e,t){const n=e.get(t)[1],r=e.get(t)[2];let i=t-1;const o=[],a=n._tokenizer||r.parser[n.contentType](n.start),l=a.events,s=[],u={};let f,c,p=-1,h=n,d=0,g=0;const C=[g];for(;h;){for(;e.get(++i)[1]!==h;);o.push(i),h._tokenizer||(f=r.sliceStream(h),h.next||f.push(null),c&&a.defineSkip(h.start),h._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(f),h._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),c=h,h=h.next}for(h=n;++p<l.length;)l[p][0]==="exit"&&l[p-1][0]==="enter"&&l[p][1].type===l[p-1][1].type&&l[p][1].start.line!==l[p][1].end.line&&(g=p+1,C.push(g),h._tokenizer=void 0,h.previous=void 0,h=h.next);for(a.events=[],h?(h._tokenizer=void 0,h.previous=void 0):C.pop(),p=C.length;p--;){const y=l.slice(C[p],C[p+1]),v=o.pop();s.push([v,v+y.length-1]),e.splice(v,2,y)}for(s.reverse(),p=-1;++p<s.length;)u[d+s[p][0]]=d+s[p][1],d+=s[p][1]-s[p][0]-1;return u}const th={resolve:rh,tokenize:ih},nh={partial:!0,tokenize:ah};function rh(e){return Da(e),e}function ih(e,t){let n;return r;function r(l){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),i(l)}function i(l){return l===null?o(l):T(l)?e.check(nh,a,o)(l):(e.consume(l),i)}function o(l){return e.exit("chunkContent"),e.exit("content"),t(l)}function a(l){return e.consume(l),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,i}}function ah(e,t,n){const r=this;return i;function i(a){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),j(e,o,"linePrefix")}function o(a){if(a===null||T(a))return n(a);const l=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&l&&l[1].type==="linePrefix"&&l[2].sliceSerialize(l[1],!0).length>=4?t(a):e.interrupt(r.parser.constructs.flow,n,t)(a)}}function _a(e,t,n,r,i,o,a,l,s){const u=s||Number.POSITIVE_INFINITY;let f=0;return c;function c(y){return y===60?(e.enter(r),e.enter(i),e.enter(o),e.consume(y),e.exit(o),p):y===null||y===32||y===41||zt(y)?n(y):(e.enter(r),e.enter(a),e.enter(l),e.enter("chunkString",{contentType:"string"}),g(y))}function p(y){return y===62?(e.enter(o),e.consume(y),e.exit(o),e.exit(i),e.exit(r),t):(e.enter(l),e.enter("chunkString",{contentType:"string"}),h(y))}function h(y){return y===62?(e.exit("chunkString"),e.exit(l),p(y)):y===null||y===60||T(y)?n(y):(e.consume(y),y===92?d:h)}function d(y){return y===60||y===62||y===92?(e.consume(y),h):h(y)}function g(y){return!f&&(y===null||y===41||V(y))?(e.exit("chunkString"),e.exit(l),e.exit(a),e.exit(r),t(y)):f<u&&y===40?(e.consume(y),f++,g):y===41?(e.consume(y),f--,g):y===null||y===32||y===40||zt(y)?n(y):(e.consume(y),y===92?C:g)}function C(y){return y===40||y===41||y===92?(e.consume(y),g):g(y)}}function Ta(e,t,n,r,i,o){const a=this;let l=0,s;return u;function u(h){return e.enter(r),e.enter(i),e.consume(h),e.exit(i),e.enter(o),f}function f(h){return l>999||h===null||h===91||h===93&&!s||h===94&&!l&&"_hiddenFootnoteSupport"in a.parser.constructs?n(h):h===93?(e.exit(o),e.enter(i),e.consume(h),e.exit(i),e.exit(r),t):T(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),f):(e.enter("chunkString",{contentType:"string"}),c(h))}function c(h){return h===null||h===91||h===93||T(h)||l++>999?(e.exit("chunkString"),f(h)):(e.consume(h),s||(s=!N(h)),h===92?p:c)}function p(h){return h===91||h===92||h===93?(e.consume(h),l++,c):c(h)}}function Pa(e,t,n,r,i,o){let a;return l;function l(p){return p===34||p===39||p===40?(e.enter(r),e.enter(i),e.consume(p),e.exit(i),a=p===40?41:p,s):n(p)}function s(p){return p===a?(e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):(e.enter(o),u(p))}function u(p){return p===a?(e.exit(o),s(a)):p===null?n(p):T(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),j(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),f(p))}function f(p){return p===a||p===null||T(p)?(e.exit("chunkString"),u(p)):(e.consume(p),p===92?c:f)}function c(p){return p===a||p===92?(e.consume(p),f):f(p)}}function ft(e,t){let n;return r;function r(i){return T(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):N(i)?j(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const oh={name:"definition",tokenize:sh},lh={partial:!0,tokenize:uh};function sh(e,t,n){const r=this;let i;return o;function o(h){return e.enter("definition"),a(h)}function a(h){return Ta.call(r,e,l,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(h)}function l(h){return i=ye(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),s):n(h)}function s(h){return V(h)?ft(e,u)(h):u(h)}function u(h){return _a(e,f,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(h)}function f(h){return e.attempt(lh,c,c)(h)}function c(h){return N(h)?j(e,p,"whitespace")(h):p(h)}function p(h){return h===null||T(h)?(e.exit("definition"),r.parser.defined.push(i),t(h)):n(h)}}function uh(e,t,n){return r;function r(l){return V(l)?ft(e,i)(l):n(l)}function i(l){return Pa(e,o,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(l)}function o(l){return N(l)?j(e,a,"whitespace")(l):a(l)}function a(l){return l===null||T(l)?t(l):n(l)}}const ch={name:"hardBreakEscape",tokenize:fh};function fh(e,t,n){return r;function r(o){return e.enter("hardBreakEscape"),e.consume(o),i}function i(o){return T(o)?(e.exit("hardBreakEscape"),t(o)):n(o)}}const hh={name:"headingAtx",resolve:ph,tokenize:dh};function ph(e,t){let n=e.length-2,r=3,i,o;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},o={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},fe(e,r,n-r+1,[["enter",i,t],["enter",o,t],["exit",o,t],["exit",i,t]])),e}function dh(e,t,n){let r=0;return i;function i(f){return e.enter("atxHeading"),o(f)}function o(f){return e.enter("atxHeadingSequence"),a(f)}function a(f){return f===35&&r++<6?(e.consume(f),a):f===null||V(f)?(e.exit("atxHeadingSequence"),l(f)):n(f)}function l(f){return f===35?(e.enter("atxHeadingSequence"),s(f)):f===null||T(f)?(e.exit("atxHeading"),t(f)):N(f)?j(e,l,"whitespace")(f):(e.enter("atxHeadingText"),u(f))}function s(f){return f===35?(e.consume(f),s):(e.exit("atxHeadingSequence"),l(f))}function u(f){return f===null||f===35||V(f)?(e.exit("atxHeadingText"),l(f)):(e.consume(f),u)}}const mh=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],Yr=["pre","script","style","textarea"],bh={concrete:!0,name:"htmlFlow",resolveTo:xh,tokenize:kh},gh={partial:!0,tokenize:vh},yh={partial:!0,tokenize:wh};function xh(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function kh(e,t,n){const r=this;let i,o,a,l,s;return u;function u(b){return f(b)}function f(b){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(b),c}function c(b){return b===33?(e.consume(b),p):b===47?(e.consume(b),o=!0,g):b===63?(e.consume(b),i=3,r.interrupt?t:m):ae(b)?(e.consume(b),a=String.fromCharCode(b),C):n(b)}function p(b){return b===45?(e.consume(b),i=2,h):b===91?(e.consume(b),i=5,l=0,d):ae(b)?(e.consume(b),i=4,r.interrupt?t:m):n(b)}function h(b){return b===45?(e.consume(b),r.interrupt?t:m):n(b)}function d(b){const be="CDATA[";return b===be.charCodeAt(l++)?(e.consume(b),l===be.length?r.interrupt?t:_:d):n(b)}function g(b){return ae(b)?(e.consume(b),a=String.fromCharCode(b),C):n(b)}function C(b){if(b===null||b===47||b===62||V(b)){const be=b===47,Pe=a.toLowerCase();return!be&&!o&&Yr.includes(Pe)?(i=1,r.interrupt?t(b):_(b)):mh.includes(a.toLowerCase())?(i=6,be?(e.consume(b),y):r.interrupt?t(b):_(b)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(b):o?v(b):S(b))}return b===45||re(b)?(e.consume(b),a+=String.fromCharCode(b),C):n(b)}function y(b){return b===62?(e.consume(b),r.interrupt?t:_):n(b)}function v(b){return N(b)?(e.consume(b),v):x(b)}function S(b){return b===47?(e.consume(b),x):b===58||b===95||ae(b)?(e.consume(b),P):N(b)?(e.consume(b),S):x(b)}function P(b){return b===45||b===46||b===58||b===95||re(b)?(e.consume(b),P):D(b)}function D(b){return b===61?(e.consume(b),k):N(b)?(e.consume(b),D):S(b)}function k(b){return b===null||b===60||b===61||b===62||b===96?n(b):b===34||b===39?(e.consume(b),s=b,M):N(b)?(e.consume(b),k):W(b)}function M(b){return b===s?(e.consume(b),s=null,U):b===null||T(b)?n(b):(e.consume(b),M)}function W(b){return b===null||b===34||b===39||b===47||b===60||b===61||b===62||b===96||V(b)?D(b):(e.consume(b),W)}function U(b){return b===47||b===62||N(b)?S(b):n(b)}function x(b){return b===62?(e.consume(b),F):n(b)}function F(b){return b===null||T(b)?_(b):N(b)?(e.consume(b),F):n(b)}function _(b){return b===45&&i===2?(e.consume(b),ne):b===60&&i===1?(e.consume(b),Z):b===62&&i===4?(e.consume(b),me):b===63&&i===3?(e.consume(b),m):b===93&&i===5?(e.consume(b),we):T(b)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(gh,ve,H)(b)):b===null||T(b)?(e.exit("htmlFlowData"),H(b)):(e.consume(b),_)}function H(b){return e.check(yh,Y,ve)(b)}function Y(b){return e.enter("lineEnding"),e.consume(b),e.exit("lineEnding"),$}function $(b){return b===null||T(b)?H(b):(e.enter("htmlFlowData"),_(b))}function ne(b){return b===45?(e.consume(b),m):_(b)}function Z(b){return b===47?(e.consume(b),a="",de):_(b)}function de(b){if(b===62){const be=a.toLowerCase();return Yr.includes(be)?(e.consume(b),me):_(b)}return ae(b)&&a.length<8?(e.consume(b),a+=String.fromCharCode(b),de):_(b)}function we(b){return b===93?(e.consume(b),m):_(b)}function m(b){return b===62?(e.consume(b),me):b===45&&i===2?(e.consume(b),m):_(b)}function me(b){return b===null||T(b)?(e.exit("htmlFlowData"),ve(b)):(e.consume(b),me)}function ve(b){return e.exit("htmlFlow"),t(b)}}function wh(e,t,n){const r=this;return i;function i(a){return T(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),o):n(a)}function o(a){return r.parser.lazy[r.now().line]?n(a):t(a)}}function vh(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(yt,t,n)}}const Ch={name:"htmlText",tokenize:Sh};function Sh(e,t,n){const r=this;let i,o,a;return l;function l(m){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(m),s}function s(m){return m===33?(e.consume(m),u):m===47?(e.consume(m),D):m===63?(e.consume(m),S):ae(m)?(e.consume(m),W):n(m)}function u(m){return m===45?(e.consume(m),f):m===91?(e.consume(m),o=0,d):ae(m)?(e.consume(m),v):n(m)}function f(m){return m===45?(e.consume(m),h):n(m)}function c(m){return m===null?n(m):m===45?(e.consume(m),p):T(m)?(a=c,Z(m)):(e.consume(m),c)}function p(m){return m===45?(e.consume(m),h):c(m)}function h(m){return m===62?ne(m):m===45?p(m):c(m)}function d(m){const me="CDATA[";return m===me.charCodeAt(o++)?(e.consume(m),o===me.length?g:d):n(m)}function g(m){return m===null?n(m):m===93?(e.consume(m),C):T(m)?(a=g,Z(m)):(e.consume(m),g)}function C(m){return m===93?(e.consume(m),y):g(m)}function y(m){return m===62?ne(m):m===93?(e.consume(m),y):g(m)}function v(m){return m===null||m===62?ne(m):T(m)?(a=v,Z(m)):(e.consume(m),v)}function S(m){return m===null?n(m):m===63?(e.consume(m),P):T(m)?(a=S,Z(m)):(e.consume(m),S)}function P(m){return m===62?ne(m):S(m)}function D(m){return ae(m)?(e.consume(m),k):n(m)}function k(m){return m===45||re(m)?(e.consume(m),k):M(m)}function M(m){return T(m)?(a=M,Z(m)):N(m)?(e.consume(m),M):ne(m)}function W(m){return m===45||re(m)?(e.consume(m),W):m===47||m===62||V(m)?U(m):n(m)}function U(m){return m===47?(e.consume(m),ne):m===58||m===95||ae(m)?(e.consume(m),x):T(m)?(a=U,Z(m)):N(m)?(e.consume(m),U):ne(m)}function x(m){return m===45||m===46||m===58||m===95||re(m)?(e.consume(m),x):F(m)}function F(m){return m===61?(e.consume(m),_):T(m)?(a=F,Z(m)):N(m)?(e.consume(m),F):U(m)}function _(m){return m===null||m===60||m===61||m===62||m===96?n(m):m===34||m===39?(e.consume(m),i=m,H):T(m)?(a=_,Z(m)):N(m)?(e.consume(m),_):(e.consume(m),Y)}function H(m){return m===i?(e.consume(m),i=void 0,$):m===null?n(m):T(m)?(a=H,Z(m)):(e.consume(m),H)}function Y(m){return m===null||m===34||m===39||m===60||m===61||m===96?n(m):m===47||m===62||V(m)?U(m):(e.consume(m),Y)}function $(m){return m===47||m===62||V(m)?U(m):n(m)}function ne(m){return m===62?(e.consume(m),e.exit("htmlTextData"),e.exit("htmlText"),t):n(m)}function Z(m){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(m),e.exit("lineEnding"),de}function de(m){return N(m)?j(e,we,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(m):we(m)}function we(m){return e.enter("htmlTextData"),a(m)}}const qn={name:"labelEnd",resolveAll:Fh,resolveTo:Dh,tokenize:_h},Eh={tokenize:Th},Ah={tokenize:Ph},Ih={tokenize:Lh};function Fh(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const i=r.type==="labelImage"?4:2;r.type="data",t+=i}}return e.length!==n.length&&fe(e,0,e.length,n),e}function Dh(e,t){let n=e.length,r=0,i,o,a,l;for(;n--;)if(i=e[n][1],o){if(i.type==="link"||i.type==="labelLink"&&i._inactive)break;e[n][0]==="enter"&&i.type==="labelLink"&&(i._inactive=!0)}else if(a){if(e[n][0]==="enter"&&(i.type==="labelImage"||i.type==="labelLink")&&!i._balanced&&(o=n,i.type!=="labelLink")){r=2;break}}else i.type==="labelEnd"&&(a=n);const s={type:e[o][1].type==="labelLink"?"link":"image",start:{...e[o][1].start},end:{...e[e.length-1][1].end}},u={type:"label",start:{...e[o][1].start},end:{...e[a][1].end}},f={type:"labelText",start:{...e[o+r+2][1].end},end:{...e[a-2][1].start}};return l=[["enter",s,t],["enter",u,t]],l=he(l,e.slice(o+1,o+r+3)),l=he(l,[["enter",f,t]]),l=he(l,Ht(t.parser.constructs.insideSpan.null,e.slice(o+r+4,a-3),t)),l=he(l,[["exit",f,t],e[a-2],e[a-1],["exit",u,t]]),l=he(l,e.slice(a+1)),l=he(l,[["exit",s,t]]),fe(e,o,e.length,l),e}function _h(e,t,n){const r=this;let i=r.events.length,o,a;for(;i--;)if((r.events[i][1].type==="labelImage"||r.events[i][1].type==="labelLink")&&!r.events[i][1]._balanced){o=r.events[i][1];break}return l;function l(p){return o?o._inactive?c(p):(a=r.parser.defined.includes(ye(r.sliceSerialize({start:o.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(p),e.exit("labelMarker"),e.exit("labelEnd"),s):n(p)}function s(p){return p===40?e.attempt(Eh,f,a?f:c)(p):p===91?e.attempt(Ah,f,a?u:c)(p):a?f(p):c(p)}function u(p){return e.attempt(Ih,f,c)(p)}function f(p){return t(p)}function c(p){return o._balanced=!0,n(p)}}function Th(e,t,n){return r;function r(c){return e.enter("resource"),e.enter("resourceMarker"),e.consume(c),e.exit("resourceMarker"),i}function i(c){return V(c)?ft(e,o)(c):o(c)}function o(c){return c===41?f(c):_a(e,a,l,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(c)}function a(c){return V(c)?ft(e,s)(c):f(c)}function l(c){return n(c)}function s(c){return c===34||c===39||c===40?Pa(e,u,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(c):f(c)}function u(c){return V(c)?ft(e,f)(c):f(c)}function f(c){return c===41?(e.enter("resourceMarker"),e.consume(c),e.exit("resourceMarker"),e.exit("resource"),t):n(c)}}function Ph(e,t,n){const r=this;return i;function i(l){return Ta.call(r,e,o,a,"reference","referenceMarker","referenceString")(l)}function o(l){return r.parser.defined.includes(ye(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(l):n(l)}function a(l){return n(l)}}function Lh(e,t,n){return r;function r(o){return e.enter("reference"),e.enter("referenceMarker"),e.consume(o),e.exit("referenceMarker"),i}function i(o){return o===93?(e.enter("referenceMarker"),e.consume(o),e.exit("referenceMarker"),e.exit("reference"),t):n(o)}}const Oh={name:"labelStartImage",resolveAll:qn.resolveAll,tokenize:Mh};function Mh(e,t,n){const r=this;return i;function i(l){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(l),e.exit("labelImageMarker"),o}function o(l){return l===91?(e.enter("labelMarker"),e.consume(l),e.exit("labelMarker"),e.exit("labelImage"),a):n(l)}function a(l){return l===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(l):t(l)}}const Rh={name:"labelStartLink",resolveAll:qn.resolveAll,tokenize:zh};function zh(e,t,n){const r=this;return i;function i(a){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(a),e.exit("labelMarker"),e.exit("labelLink"),o}function o(a){return a===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(a):t(a)}}const on={name:"lineEnding",tokenize:Nh};function Nh(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),j(e,t,"linePrefix")}}const It={name:"thematicBreak",tokenize:Bh};function Bh(e,t,n){let r=0,i;return o;function o(u){return e.enter("thematicBreak"),a(u)}function a(u){return i=u,l(u)}function l(u){return u===i?(e.enter("thematicBreakSequence"),s(u)):r>=3&&(u===null||T(u))?(e.exit("thematicBreak"),t(u)):n(u)}function s(u){return u===i?(e.consume(u),r++,s):(e.exit("thematicBreakSequence"),N(u)?j(e,l,"whitespace")(u):l(u))}}const oe={continuation:{tokenize:Uh},exit:qh,name:"list",tokenize:Wh},jh={partial:!0,tokenize:Vh},$h={partial:!0,tokenize:Hh};function Wh(e,t,n){const r=this,i=r.events[r.events.length-1];let o=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,a=0;return l;function l(h){const d=r.containerState.type||(h===42||h===43||h===45?"listUnordered":"listOrdered");if(d==="listUnordered"?!r.containerState.marker||h===r.containerState.marker:An(h)){if(r.containerState.type||(r.containerState.type=d,e.enter(d,{_container:!0})),d==="listUnordered")return e.enter("listItemPrefix"),h===42||h===45?e.check(It,n,u)(h):u(h);if(!r.interrupt||h===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),s(h)}return n(h)}function s(h){return An(h)&&++a<10?(e.consume(h),s):(!r.interrupt||a<2)&&(r.containerState.marker?h===r.containerState.marker:h===41||h===46)?(e.exit("listItemValue"),u(h)):n(h)}function u(h){return e.enter("listItemMarker"),e.consume(h),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||h,e.check(yt,r.interrupt?n:f,e.attempt(jh,p,c))}function f(h){return r.containerState.initialBlankLine=!0,o++,p(h)}function c(h){return N(h)?(e.enter("listItemPrefixWhitespace"),e.consume(h),e.exit("listItemPrefixWhitespace"),p):n(h)}function p(h){return r.containerState.size=o+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(h)}}function Uh(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(yt,i,o);function i(l){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,j(e,t,"listItemIndent",r.containerState.size+1)(l)}function o(l){return r.containerState.furtherBlankLines||!N(l)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,a(l)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt($h,t,a)(l))}function a(l){return r.containerState._closeFlow=!0,r.interrupt=void 0,j(e,e.attempt(oe,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(l)}}function Hh(e,t,n){const r=this;return j(e,i,"listItemIndent",r.containerState.size+1);function i(o){const a=r.events[r.events.length-1];return a&&a[1].type==="listItemIndent"&&a[2].sliceSerialize(a[1],!0).length===r.containerState.size?t(o):n(o)}}function qh(e){e.exit(this.containerState.type)}function Vh(e,t,n){const r=this;return j(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function i(o){const a=r.events[r.events.length-1];return!N(o)&&a&&a[1].type==="listItemPrefixWhitespace"?t(o):n(o)}}const Xr={name:"setextUnderline",resolveTo:Gh,tokenize:Yh};function Gh(e,t){let n=e.length,r,i,o;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!o&&e[n][1].type==="definition"&&(o=n);const a={type:"setextHeading",start:{...e[i][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type="setextHeadingText",o?(e.splice(i,0,["enter",a,t]),e.splice(o+1,0,["exit",e[r][1],t]),e[r][1].end={...e[o][1].end}):e[r][1]=a,e.push(["exit",a,t]),e}function Yh(e,t,n){const r=this;let i;return o;function o(u){let f=r.events.length,c;for(;f--;)if(r.events[f][1].type!=="lineEnding"&&r.events[f][1].type!=="linePrefix"&&r.events[f][1].type!=="content"){c=r.events[f][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||c)?(e.enter("setextHeadingLine"),i=u,a(u)):n(u)}function a(u){return e.enter("setextHeadingLineSequence"),l(u)}function l(u){return u===i?(e.consume(u),l):(e.exit("setextHeadingLineSequence"),N(u)?j(e,s,"lineSuffix")(u):s(u))}function s(u){return u===null||T(u)?(e.exit("setextHeadingLine"),t(u)):n(u)}}const Xh={tokenize:Jh};function Jh(e){const t=this,n=e.attempt(yt,r,e.attempt(this.parser.constructs.flowInitial,i,j(e,e.attempt(this.parser.constructs.flow,i,e.attempt(th,i)),"linePrefix")));return n;function r(o){if(o===null){e.consume(o);return}return e.enter("lineEndingBlank"),e.consume(o),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(o){if(o===null){e.consume(o);return}return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const Kh={resolveAll:Oa()},Qh=La("string"),Zh=La("text");function La(e){return{resolveAll:Oa(e==="text"?ep:void 0),tokenize:t};function t(n){const r=this,i=this.parser.constructs[e],o=n.attempt(i,a,l);return a;function a(f){return u(f)?o(f):l(f)}function l(f){if(f===null){n.consume(f);return}return n.enter("data"),n.consume(f),s}function s(f){return u(f)?(n.exit("data"),o(f)):(n.consume(f),s)}function u(f){if(f===null)return!0;const c=i[f];let p=-1;if(c)for(;++p<c.length;){const h=c[p];if(!h.previous||h.previous.call(r,r.previous))return!0}return!1}}}function Oa(e){return t;function t(n,r){let i=-1,o;for(;++i<=n.length;)o===void 0?n[i]&&n[i][1].type==="data"&&(o=i,i++):(!n[i]||n[i][1].type!=="data")&&(i!==o+2&&(n[o][1].end=n[i-1][1].end,n.splice(o+2,i-o-2),i=o+2),o=void 0);return e?e(n,r):n}}function ep(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],i=t.sliceStream(r);let o=i.length,a=-1,l=0,s;for(;o--;){const u=i[o];if(typeof u=="string"){for(a=u.length;u.charCodeAt(a-1)===32;)l++,a--;if(a)break;a=-1}else if(u===-2)s=!0,l++;else if(u!==-1){o++;break}}if(l){const u={type:n===e.length||s||l<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:o?a:r.start._bufferIndex+a,_index:r.start._index+o,line:r.end.line,column:r.end.column-l,offset:r.end.offset-l},end:{...r.end}};r.end={...u.start},r.start.offset===r.end.offset?Object.assign(r,u):(e.splice(n,0,["enter",u,t],["exit",u,t]),n+=2)}n++}return e}const tp={42:oe,43:oe,45:oe,48:oe,49:oe,50:oe,51:oe,52:oe,53:oe,54:oe,55:oe,56:oe,57:oe,62:Aa},np={91:oh},rp={[-2]:an,[-1]:an,32:an},ip={35:hh,42:It,45:[Xr,It],60:bh,61:Xr,95:It,96:Gr,126:Gr},ap={38:Fa,92:Ia},op={[-5]:on,[-4]:on,[-3]:on,33:Oh,38:Fa,42:In,60:[Rf,Ch],91:Rh,92:[ch,Ia],93:qn,95:In,96:Xf},lp={null:[In,Kh]},sp={null:[42,95]},up={null:[]},cp=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:sp,contentInitial:np,disable:up,document:tp,flow:ip,flowInitial:rp,insideSpan:lp,string:ap,text:op},Symbol.toStringTag,{value:"Module"}));function fp(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const i={},o=[];let a=[],l=[];const s={attempt:M(D),check:M(k),consume:v,enter:S,exit:P,interrupt:M(k,{interrupt:!0})},u={code:null,containerState:{},defineSkip:g,events:[],now:d,parser:e,previous:null,sliceSerialize:p,sliceStream:h,write:c};let f=t.tokenize.call(u,s);return t.resolveAll&&o.push(t),u;function c(F){return a=he(a,F),C(),a[a.length-1]!==null?[]:(W(t,0),u.events=Ht(o,u.events,u),u.events)}function p(F,_){return pp(h(F),_)}function h(F){return hp(a,F)}function d(){const{_bufferIndex:F,_index:_,line:H,column:Y,offset:$}=r;return{_bufferIndex:F,_index:_,line:H,column:Y,offset:$}}function g(F){i[F.line]=F.column,x()}function C(){let F;for(;r._index<a.length;){const _=a[r._index];if(typeof _=="string")for(F=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===F&&r._bufferIndex<_.length;)y(_.charCodeAt(r._bufferIndex));else y(_)}}function y(F){f=f(F)}function v(F){T(F)?(r.line++,r.column=1,r.offset+=F===-3?2:1,x()):F!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++)),u.previous=F}function S(F,_){const H=_||{};return H.type=F,H.start=d(),u.events.push(["enter",H,u]),l.push(H),H}function P(F){const _=l.pop();return _.end=d(),u.events.push(["exit",_,u]),_}function D(F,_){W(F,_.from)}function k(F,_){_.restore()}function M(F,_){return H;function H(Y,$,ne){let Z,de,we,m;return Array.isArray(Y)?ve(Y):"tokenize"in Y?ve([Y]):me(Y);function me(ee){return et;function et(Ie){const Be=Ie!==null&&ee[Ie],je=Ie!==null&&ee.null,kt=[...Array.isArray(Be)?Be:Be?[Be]:[],...Array.isArray(je)?je:je?[je]:[]];return ve(kt)(Ie)}}function ve(ee){return Z=ee,de=0,ee.length===0?ne:b(ee[de])}function b(ee){return et;function et(Ie){return m=U(),we=ee,ee.partial||(u.currentConstruct=ee),ee.name&&u.parser.constructs.disable.null.includes(ee.name)?Pe():ee.tokenize.call(_?Object.assign(Object.create(u),_):u,s,be,Pe)(Ie)}}function be(ee){return F(we,m),$}function Pe(ee){return m.restore(),++de<Z.length?b(Z[de]):ne}}}function W(F,_){F.resolveAll&&!o.includes(F)&&o.push(F),F.resolve&&fe(u.events,_,u.events.length-_,F.resolve(u.events.slice(_),u)),F.resolveTo&&(u.events=F.resolveTo(u.events,u))}function U(){const F=d(),_=u.previous,H=u.currentConstruct,Y=u.events.length,$=Array.from(l);return{from:Y,restore:ne};function ne(){r=F,u.previous=_,u.currentConstruct=H,u.events.length=Y,l=$,x()}}function x(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function hp(e,t){const n=t.start._index,r=t.start._bufferIndex,i=t.end._index,o=t.end._bufferIndex;let a;if(n===i)a=[e[n].slice(r,o)];else{if(a=e.slice(n,i),r>-1){const l=a[0];typeof l=="string"?a[0]=l.slice(r):a.shift()}o>0&&a.push(e[i].slice(0,o))}return a}function pp(e,t){let n=-1;const r=[];let i;for(;++n<e.length;){const o=e[n];let a;if(typeof o=="string")a=o;else switch(o){case-5:{a="\r";break}case-4:{a=`
`;break}case-3:{a=`\r
`;break}case-2:{a=t?" ":"	";break}case-1:{if(!t&&i)continue;a=" ";break}default:a=String.fromCharCode(o)}i=o===-2,r.push(a)}return r.join("")}function dp(e){const r={constructs:Sa([cp,...(e||{}).extensions||[]]),content:i(Df),defined:[],document:i(Tf),flow:i(Xh),lazy:{},string:i(Qh),text:i(Zh)};return r;function i(o){return a;function a(l){return fp(r,o,l)}}}function mp(e){for(;!Da(e););return e}const Jr=/[\0\t\n\r]/g;function bp(){let e=1,t="",n=!0,r;return i;function i(o,a,l){const s=[];let u,f,c,p,h;for(o=t+(typeof o=="string"?o.toString():new TextDecoder(a||void 0).decode(o)),c=0,t="",n&&(o.charCodeAt(0)===65279&&c++,n=void 0);c<o.length;){if(Jr.lastIndex=c,u=Jr.exec(o),p=u&&u.index!==void 0?u.index:o.length,h=o.charCodeAt(p),!u){t=o.slice(c);break}if(h===10&&c===p&&r)s.push(-3),r=void 0;else switch(r&&(s.push(-5),r=void 0),c<p&&(s.push(o.slice(c,p)),e+=p-c),h){case 0:{s.push(65533),e++;break}case 9:{for(f=Math.ceil(e/4)*4,s.push(-2);e++<f;)s.push(-1);break}case 10:{s.push(-4),e=1;break}default:r=!0,e=1}c=p+1}return l&&(r&&s.push(-5),t&&s.push(t),s.push(null)),s}}const gp=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function yp(e){return e.replace(gp,xp)}function xp(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),o=i===120||i===88;return Ea(n.slice(o?2:1),o?16:10)}return Hn(n)||e}const Ma={}.hasOwnProperty;function kp(e,t,n){return typeof t!="string"&&(n=t,t=void 0),wp(n)(mp(dp(n).document().write(bp()(e,t,!0))))}function wp(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:o(ar),autolinkProtocol:U,autolinkEmail:U,atxHeading:o(nr),blockQuote:o(je),characterEscape:U,characterReference:U,codeFenced:o(kt),codeFencedFenceInfo:a,codeFencedFenceMeta:a,codeIndented:o(kt,a),codeText:o(go,a),codeTextData:U,data:U,codeFlowValue:U,definition:o(yo),definitionDestinationString:a,definitionLabelString:a,definitionTitleString:a,emphasis:o(xo),hardBreakEscape:o(rr),hardBreakTrailing:o(rr),htmlFlow:o(ir,a),htmlFlowData:U,htmlText:o(ir,a),htmlTextData:U,image:o(ko),label:a,link:o(ar),listItem:o(wo),listItemValue:p,listOrdered:o(or,c),listUnordered:o(or),paragraph:o(vo),reference:b,referenceString:a,resourceDestinationString:a,resourceTitleString:a,setextHeading:o(nr),strong:o(Co),thematicBreak:o(Eo)},exit:{atxHeading:s(),atxHeadingSequence:D,autolink:s(),autolinkEmail:Be,autolinkProtocol:Ie,blockQuote:s(),characterEscapeValue:x,characterReferenceMarkerHexadecimal:Pe,characterReferenceMarkerNumeric:Pe,characterReferenceValue:ee,characterReference:et,codeFenced:s(C),codeFencedFence:g,codeFencedFenceInfo:h,codeFencedFenceMeta:d,codeFlowValue:x,codeIndented:s(y),codeText:s($),codeTextData:x,data:x,definition:s(),definitionDestinationString:P,definitionLabelString:v,definitionTitleString:S,emphasis:s(),hardBreakEscape:s(_),hardBreakTrailing:s(_),htmlFlow:s(H),htmlFlowData:x,htmlText:s(Y),htmlTextData:x,image:s(Z),label:we,labelText:de,lineEnding:F,link:s(ne),listItem:s(),listOrdered:s(),listUnordered:s(),paragraph:s(),referenceString:be,resourceDestinationString:m,resourceTitleString:me,resource:ve,setextHeading:s(W),setextHeadingLineSequence:M,setextHeadingText:k,strong:s(),thematicBreak:s()}};Ra(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(w){let A={type:"root",children:[]};const L={stack:[A],tokenStack:[],config:t,enter:l,exit:u,buffer:a,resume:f,data:n},B=[];let q=-1;for(;++q<w.length;)if(w[q][1].type==="listOrdered"||w[q][1].type==="listUnordered")if(w[q][0]==="enter")B.push(q);else{const ge=B.pop();q=i(w,ge,q)}for(q=-1;++q<w.length;){const ge=t[w[q][0]];Ma.call(ge,w[q][1].type)&&ge[w[q][1].type].call(Object.assign({sliceSerialize:w[q][2].sliceSerialize},L),w[q][1])}if(L.tokenStack.length>0){const ge=L.tokenStack[L.tokenStack.length-1];(ge[1]||Kr).call(L,void 0,ge[0])}for(A.position={start:Fe(w.length>0?w[0][1].start:{line:1,column:1,offset:0}),end:Fe(w.length>0?w[w.length-2][1].end:{line:1,column:1,offset:0})},q=-1;++q<t.transforms.length;)A=t.transforms[q](A)||A;return A}function i(w,A,L){let B=A-1,q=-1,ge=!1,Le,Ce,tt,nt;for(;++B<=L;){const le=w[B];switch(le[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{le[0]==="enter"?q++:q--,nt=void 0;break}case"lineEndingBlank":{le[0]==="enter"&&(Le&&!nt&&!q&&!tt&&(tt=B),nt=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:nt=void 0}if(!q&&le[0]==="enter"&&le[1].type==="listItemPrefix"||q===-1&&le[0]==="exit"&&(le[1].type==="listUnordered"||le[1].type==="listOrdered")){if(Le){let $e=B;for(Ce=void 0;$e--;){const Se=w[$e];if(Se[1].type==="lineEnding"||Se[1].type==="lineEndingBlank"){if(Se[0]==="exit")continue;Ce&&(w[Ce][1].type="lineEndingBlank",ge=!0),Se[1].type="lineEnding",Ce=$e}else if(!(Se[1].type==="linePrefix"||Se[1].type==="blockQuotePrefix"||Se[1].type==="blockQuotePrefixWhitespace"||Se[1].type==="blockQuoteMarker"||Se[1].type==="listItemIndent"))break}tt&&(!Ce||tt<Ce)&&(Le._spread=!0),Le.end=Object.assign({},Ce?w[Ce][1].start:le[1].end),w.splice(Ce||B,0,["exit",Le,le[2]]),B++,L++}if(le[1].type==="listItemPrefix"){const $e={type:"listItem",_spread:!1,start:Object.assign({},le[1].start),end:void 0};Le=$e,w.splice(B,0,["enter",$e,le[2]]),B++,L++,tt=void 0,nt=!0}}}return w[A][1]._spread=ge,L}function o(w,A){return L;function L(B){l.call(this,w(B),B),A&&A.call(this,B)}}function a(){this.stack.push({type:"fragment",children:[]})}function l(w,A,L){this.stack[this.stack.length-1].children.push(w),this.stack.push(w),this.tokenStack.push([A,L||void 0]),w.position={start:Fe(A.start),end:void 0}}function s(w){return A;function A(L){w&&w.call(this,L),u.call(this,L)}}function u(w,A){const L=this.stack.pop(),B=this.tokenStack.pop();if(B)B[0].type!==w.type&&(A?A.call(this,w,B[0]):(B[1]||Kr).call(this,w,B[0]));else throw new Error("Cannot close `"+w.type+"` ("+ct({start:w.start,end:w.end})+"): it’s not open");L.position.end=Fe(w.end)}function f(){return Un(this.stack.pop())}function c(){this.data.expectingFirstListItemValue=!0}function p(w){if(this.data.expectingFirstListItemValue){const A=this.stack[this.stack.length-2];A.start=Number.parseInt(this.sliceSerialize(w),10),this.data.expectingFirstListItemValue=void 0}}function h(){const w=this.resume(),A=this.stack[this.stack.length-1];A.lang=w}function d(){const w=this.resume(),A=this.stack[this.stack.length-1];A.meta=w}function g(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function C(){const w=this.resume(),A=this.stack[this.stack.length-1];A.value=w.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function y(){const w=this.resume(),A=this.stack[this.stack.length-1];A.value=w.replace(/(\r?\n|\r)$/g,"")}function v(w){const A=this.resume(),L=this.stack[this.stack.length-1];L.label=A,L.identifier=ye(this.sliceSerialize(w)).toLowerCase()}function S(){const w=this.resume(),A=this.stack[this.stack.length-1];A.title=w}function P(){const w=this.resume(),A=this.stack[this.stack.length-1];A.url=w}function D(w){const A=this.stack[this.stack.length-1];if(!A.depth){const L=this.sliceSerialize(w).length;A.depth=L}}function k(){this.data.setextHeadingSlurpLineEnding=!0}function M(w){const A=this.stack[this.stack.length-1];A.depth=this.sliceSerialize(w).codePointAt(0)===61?1:2}function W(){this.data.setextHeadingSlurpLineEnding=void 0}function U(w){const L=this.stack[this.stack.length-1].children;let B=L[L.length-1];(!B||B.type!=="text")&&(B=So(),B.position={start:Fe(w.start),end:void 0},L.push(B)),this.stack.push(B)}function x(w){const A=this.stack.pop();A.value+=this.sliceSerialize(w),A.position.end=Fe(w.end)}function F(w){const A=this.stack[this.stack.length-1];if(this.data.atHardBreak){const L=A.children[A.children.length-1];L.position.end=Fe(w.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(A.type)&&(U.call(this,w),x.call(this,w))}function _(){this.data.atHardBreak=!0}function H(){const w=this.resume(),A=this.stack[this.stack.length-1];A.value=w}function Y(){const w=this.resume(),A=this.stack[this.stack.length-1];A.value=w}function $(){const w=this.resume(),A=this.stack[this.stack.length-1];A.value=w}function ne(){const w=this.stack[this.stack.length-1];if(this.data.inReference){const A=this.data.referenceType||"shortcut";w.type+="Reference",w.referenceType=A,delete w.url,delete w.title}else delete w.identifier,delete w.label;this.data.referenceType=void 0}function Z(){const w=this.stack[this.stack.length-1];if(this.data.inReference){const A=this.data.referenceType||"shortcut";w.type+="Reference",w.referenceType=A,delete w.url,delete w.title}else delete w.identifier,delete w.label;this.data.referenceType=void 0}function de(w){const A=this.sliceSerialize(w),L=this.stack[this.stack.length-2];L.label=yp(A),L.identifier=ye(A).toLowerCase()}function we(){const w=this.stack[this.stack.length-1],A=this.resume(),L=this.stack[this.stack.length-1];if(this.data.inReference=!0,L.type==="link"){const B=w.children;L.children=B}else L.alt=A}function m(){const w=this.resume(),A=this.stack[this.stack.length-1];A.url=w}function me(){const w=this.resume(),A=this.stack[this.stack.length-1];A.title=w}function ve(){this.data.inReference=void 0}function b(){this.data.referenceType="collapsed"}function be(w){const A=this.resume(),L=this.stack[this.stack.length-1];L.label=A,L.identifier=ye(this.sliceSerialize(w)).toLowerCase(),this.data.referenceType="full"}function Pe(w){this.data.characterReferenceType=w.type}function ee(w){const A=this.sliceSerialize(w),L=this.data.characterReferenceType;let B;L?(B=Ea(A,L==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):B=Hn(A);const q=this.stack[this.stack.length-1];q.value+=B}function et(w){const A=this.stack.pop();A.position.end=Fe(w.end)}function Ie(w){x.call(this,w);const A=this.stack[this.stack.length-1];A.url=this.sliceSerialize(w)}function Be(w){x.call(this,w);const A=this.stack[this.stack.length-1];A.url="mailto:"+this.sliceSerialize(w)}function je(){return{type:"blockquote",children:[]}}function kt(){return{type:"code",lang:null,meta:null,value:""}}function go(){return{type:"inlineCode",value:""}}function yo(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function xo(){return{type:"emphasis",children:[]}}function nr(){return{type:"heading",depth:0,children:[]}}function rr(){return{type:"break"}}function ir(){return{type:"html",value:""}}function ko(){return{type:"image",title:null,url:"",alt:null}}function ar(){return{type:"link",title:null,url:"",children:[]}}function or(w){return{type:"list",ordered:w.type==="listOrdered",start:null,spread:w._spread,children:[]}}function wo(w){return{type:"listItem",spread:w._spread,checked:null,children:[]}}function vo(){return{type:"paragraph",children:[]}}function Co(){return{type:"strong",children:[]}}function So(){return{type:"text",value:""}}function Eo(){return{type:"thematicBreak"}}}function Fe(e){return{line:e.line,column:e.column,offset:e.offset}}function Ra(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Ra(e,r):vp(e,r)}}function vp(e,t){let n;for(n in t)if(Ma.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function Kr(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+ct({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+ct({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+ct({start:t.start,end:t.end})+") is still open")}function Cp(e){const t=this;t.parser=n;function n(r){return kp(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function Sp(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function Ep(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
`}]}function Ap(e,t){const n=t.value?t.value+`
`:"",r={};t.lang&&(r.className=["language-"+t.lang]);let i={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(i.data={meta:t.meta}),e.patch(t,i),i=e.applyData(t,i),i={type:"element",tagName:"pre",properties:{},children:[i]},e.patch(t,i),i}function Ip(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Fp(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Dp(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),i=Ze(r.toLowerCase()),o=e.footnoteOrder.indexOf(r);let a,l=e.footnoteCounts.get(r);l===void 0?(l=0,e.footnoteOrder.push(r),a=e.footnoteOrder.length):a=o+1,l+=1,e.footnoteCounts.set(r,l);const s={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+i,id:n+"fnref-"+i+(l>1?"-"+l:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(a)}]};e.patch(t,s);const u={type:"element",tagName:"sup",properties:{},children:[s]};return e.patch(t,u),e.applyData(t,u)}function _p(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Tp(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function za(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+r}];const i=e.all(t),o=i[0];o&&o.type==="text"?o.value="["+o.value:i.unshift({type:"text",value:"["});const a=i[i.length-1];return a&&a.type==="text"?a.value+=r:i.push({type:"text",value:r}),i}function Pp(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return za(e,t);const i={src:Ze(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);const o={type:"element",tagName:"img",properties:i,children:[]};return e.patch(t,o),e.applyData(t,o)}function Lp(e,t){const n={src:Ze(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function Op(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function Mp(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return za(e,t);const i={href:Ze(r.url||"")};r.title!==null&&r.title!==void 0&&(i.title=r.title);const o={type:"element",tagName:"a",properties:i,children:e.all(t)};return e.patch(t,o),e.applyData(t,o)}function Rp(e,t){const n={href:Ze(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function zp(e,t,n){const r=e.all(t),i=n?Np(n):Na(t),o={},a=[];if(typeof t.checked=="boolean"){const f=r[0];let c;f&&f.type==="element"&&f.tagName==="p"?c=f:(c={type:"element",tagName:"p",properties:{},children:[]},r.unshift(c)),c.children.length>0&&c.children.unshift({type:"text",value:" "}),c.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),o.className=["task-list-item"]}let l=-1;for(;++l<r.length;){const f=r[l];(i||l!==0||f.type!=="element"||f.tagName!=="p")&&a.push({type:"text",value:`
`}),f.type==="element"&&f.tagName==="p"&&!i?a.push(...f.children):a.push(f)}const s=r[r.length-1];s&&(i||s.type!=="element"||s.tagName!=="p")&&a.push({type:"text",value:`
`});const u={type:"element",tagName:"li",properties:o,children:a};return e.patch(t,u),e.applyData(t,u)}function Np(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=Na(n[r])}return t}function Na(e){const t=e.spread;return t??e.children.length>1}function Bp(e,t){const n={},r=e.all(t);let i=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++i<r.length;){const a=r[i];if(a.type==="element"&&a.tagName==="li"&&a.properties&&Array.isArray(a.properties.className)&&a.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const o={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,o),e.applyData(t,o)}function jp(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function $p(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function Wp(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Up(e,t){const n=e.all(t),r=n.shift(),i=[];if(r){const a={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],a),i.push(a)}if(n.length>0){const a={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},l=Bn(t.children[1]),s=ga(t.children[t.children.length-1]);l&&s&&(a.position={start:l,end:s}),i.push(a)}const o={type:"element",tagName:"table",properties:{},children:e.wrap(i,!0)};return e.patch(t,o),e.applyData(t,o)}function Hp(e,t,n){const r=n?n.children:void 0,o=(r?r.indexOf(t):1)===0?"th":"td",a=n&&n.type==="table"?n.align:void 0,l=a?a.length:t.children.length;let s=-1;const u=[];for(;++s<l;){const c=t.children[s],p={},h=a?a[s]:void 0;h&&(p.align=h);let d={type:"element",tagName:o,properties:p,children:[]};c&&(d.children=e.all(c),e.patch(c,d),d=e.applyData(c,d)),u.push(d)}const f={type:"element",tagName:"tr",properties:{},children:e.wrap(u,!0)};return e.patch(t,f),e.applyData(t,f)}function qp(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const Qr=9,Zr=32;function Vp(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),i=0;const o=[];for(;r;)o.push(ei(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return o.push(ei(t.slice(i),i>0,!1)),o.join("")}function ei(e,t,n){let r=0,i=e.length;if(t){let o=e.codePointAt(r);for(;o===Qr||o===Zr;)r++,o=e.codePointAt(r)}if(n){let o=e.codePointAt(i-1);for(;o===Qr||o===Zr;)i--,o=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}function Gp(e,t){const n={type:"text",value:Vp(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function Yp(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const Xp={blockquote:Sp,break:Ep,code:Ap,delete:Ip,emphasis:Fp,footnoteReference:Dp,heading:_p,html:Tp,imageReference:Pp,image:Lp,inlineCode:Op,linkReference:Mp,link:Rp,listItem:zp,list:Bp,paragraph:jp,root:$p,strong:Wp,table:Up,tableCell:qp,tableRow:Hp,text:Gp,thematicBreak:Yp,toml:vt,yaml:vt,definition:vt,footnoteDefinition:vt};function vt(){}const Ba=-1,qt=0,Nt=1,Bt=2,Vn=3,Gn=4,Yn=5,Xn=6,ja=7,$a=8,ti=typeof self=="object"?self:globalThis,Jp=(e,t)=>{const n=(i,o)=>(e.set(o,i),i),r=i=>{if(e.has(i))return e.get(i);const[o,a]=t[i];switch(o){case qt:case Ba:return n(a,i);case Nt:{const l=n([],i);for(const s of a)l.push(r(s));return l}case Bt:{const l=n({},i);for(const[s,u]of a)l[r(s)]=r(u);return l}case Vn:return n(new Date(a),i);case Gn:{const{source:l,flags:s}=a;return n(new RegExp(l,s),i)}case Yn:{const l=n(new Map,i);for(const[s,u]of a)l.set(r(s),r(u));return l}case Xn:{const l=n(new Set,i);for(const s of a)l.add(r(s));return l}case ja:{const{name:l,message:s}=a;return n(new ti[l](s),i)}case $a:return n(BigInt(a),i);case"BigInt":return n(Object(BigInt(a)),i)}return n(new ti[o](a),i)};return r},ni=e=>Jp(new Map,e)(0),Ue="",{toString:Kp}={},{keys:Qp}=Object,ot=e=>{const t=typeof e;if(t!=="object"||!e)return[qt,t];const n=Kp.call(e).slice(8,-1);switch(n){case"Array":return[Nt,Ue];case"Object":return[Bt,Ue];case"Date":return[Vn,Ue];case"RegExp":return[Gn,Ue];case"Map":return[Yn,Ue];case"Set":return[Xn,Ue]}return n.includes("Array")?[Nt,n]:n.includes("Error")?[ja,n]:[Bt,n]},Ct=([e,t])=>e===qt&&(t==="function"||t==="symbol"),Zp=(e,t,n,r)=>{const i=(a,l)=>{const s=r.push(a)-1;return n.set(l,s),s},o=a=>{if(n.has(a))return n.get(a);let[l,s]=ot(a);switch(l){case qt:{let f=a;switch(s){case"bigint":l=$a,f=a.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+s);f=null;break;case"undefined":return i([Ba],a)}return i([l,f],a)}case Nt:{if(s)return i([s,[...a]],a);const f=[],c=i([l,f],a);for(const p of a)f.push(o(p));return c}case Bt:{if(s)switch(s){case"BigInt":return i([s,a.toString()],a);case"Boolean":case"Number":case"String":return i([s,a.valueOf()],a)}if(t&&"toJSON"in a)return o(a.toJSON());const f=[],c=i([l,f],a);for(const p of Qp(a))(e||!Ct(ot(a[p])))&&f.push([o(p),o(a[p])]);return c}case Vn:return i([l,a.toISOString()],a);case Gn:{const{source:f,flags:c}=a;return i([l,{source:f,flags:c}],a)}case Yn:{const f=[],c=i([l,f],a);for(const[p,h]of a)(e||!(Ct(ot(p))||Ct(ot(h))))&&f.push([o(p),o(h)]);return c}case Xn:{const f=[],c=i([l,f],a);for(const p of a)(e||!Ct(ot(p)))&&f.push(o(p));return c}}const{message:u}=a;return i([l,{name:s,message:u}],a)};return o},ri=(e,{json:t,lossy:n}={})=>{const r=[];return Zp(!(t||n),!!t,new Map,r)(e),r},jt=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?ni(ri(e,t)):structuredClone(e):(e,t)=>ni(ri(e,t));function ed(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function td(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function nd(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||ed,r=e.options.footnoteBackLabel||td,i=e.options.footnoteLabel||"Footnotes",o=e.options.footnoteLabelTagName||"h2",a=e.options.footnoteLabelProperties||{className:["sr-only"]},l=[];let s=-1;for(;++s<e.footnoteOrder.length;){const u=e.footnoteById.get(e.footnoteOrder[s]);if(!u)continue;const f=e.all(u),c=String(u.identifier).toUpperCase(),p=Ze(c.toLowerCase());let h=0;const d=[],g=e.footnoteCounts.get(c);for(;g!==void 0&&++h<=g;){d.length>0&&d.push({type:"text",value:" "});let v=typeof n=="string"?n:n(s,h);typeof v=="string"&&(v={type:"text",value:v}),d.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+p+(h>1?"-"+h:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(s,h),className:["data-footnote-backref"]},children:Array.isArray(v)?v:[v]})}const C=f[f.length-1];if(C&&C.type==="element"&&C.tagName==="p"){const v=C.children[C.children.length-1];v&&v.type==="text"?v.value+=" ":C.children.push({type:"text",value:" "}),C.children.push(...d)}else f.push(...d);const y={type:"element",tagName:"li",properties:{id:t+"fn-"+p},children:e.wrap(f,!0)};e.patch(u,y),l.push(y)}if(l.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:o,properties:{...jt(a),id:"footnote-label"},children:[{type:"text",value:i}]},{type:"text",value:`
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(l,!0)},{type:"text",value:`
`}]}}const Vt=function(e){if(e==null)return od;if(typeof e=="function")return Gt(e);if(typeof e=="object")return Array.isArray(e)?rd(e):id(e);if(typeof e=="string")return ad(e);throw new Error("Expected function, string, or object as test")};function rd(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Vt(e[n]);return Gt(r);function r(...i){let o=-1;for(;++o<t.length;)if(t[o].apply(this,i))return!0;return!1}}function id(e){const t=e;return Gt(n);function n(r){const i=r;let o;for(o in e)if(i[o]!==t[o])return!1;return!0}}function ad(e){return Gt(t);function t(n){return n&&n.type===e}}function Gt(e){return t;function t(n,r,i){return!!(ld(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function od(){return!0}function ld(e){return e!==null&&typeof e=="object"&&"type"in e}const Wa=[],sd=!0,Fn=!1,ud="skip";function Ua(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const o=Vt(i),a=r?-1:1;l(e,void 0,[])();function l(s,u,f){const c=s&&typeof s=="object"?s:{};if(typeof c.type=="string"){const h=typeof c.tagName=="string"?c.tagName:typeof c.name=="string"?c.name:void 0;Object.defineProperty(p,"name",{value:"node ("+(s.type+(h?"<"+h+">":""))+")"})}return p;function p(){let h=Wa,d,g,C;if((!t||o(s,u,f[f.length-1]||void 0))&&(h=cd(n(s,f)),h[0]===Fn))return h;if("children"in s&&s.children){const y=s;if(y.children&&h[0]!==ud)for(g=(r?y.children.length:-1)+a,C=f.concat(y);g>-1&&g<y.children.length;){const v=y.children[g];if(d=l(v,g,C)(),d[0]===Fn)return d;g=typeof d[1]=="number"?d[1]:g+a}}return h}}}function cd(e){return Array.isArray(e)?e:typeof e=="number"?[sd,e]:e==null?Wa:[e]}function Jn(e,t,n,r){let i,o,a;typeof t=="function"&&typeof n!="function"?(o=void 0,a=t,i=n):(o=t,a=n,i=r),Ua(e,o,l,i);function l(s,u){const f=u[u.length-1],c=f?f.children.indexOf(s):void 0;return a(s,c,f)}}const Dn={}.hasOwnProperty,fd={};function hd(e,t){const n=t||fd,r=new Map,i=new Map,o=new Map,a={...Xp,...n.handlers},l={all:u,applyData:dd,definitionById:r,footnoteById:i,footnoteCounts:o,footnoteOrder:[],handlers:a,one:s,options:n,patch:pd,wrap:bd};return Jn(e,function(f){if(f.type==="definition"||f.type==="footnoteDefinition"){const c=f.type==="definition"?r:i,p=String(f.identifier).toUpperCase();c.has(p)||c.set(p,f)}}),l;function s(f,c){const p=f.type,h=l.handlers[p];if(Dn.call(l.handlers,p)&&h)return h(l,f,c);if(l.options.passThrough&&l.options.passThrough.includes(p)){if("children"in f){const{children:g,...C}=f,y=jt(C);return y.children=l.all(f),y}return jt(f)}return(l.options.unknownHandler||md)(l,f,c)}function u(f){const c=[];if("children"in f){const p=f.children;let h=-1;for(;++h<p.length;){const d=l.one(p[h],f);if(d){if(h&&p[h-1].type==="break"&&(!Array.isArray(d)&&d.type==="text"&&(d.value=ii(d.value)),!Array.isArray(d)&&d.type==="element")){const g=d.children[0];g&&g.type==="text"&&(g.value=ii(g.value))}Array.isArray(d)?c.push(...d):c.push(d)}}}return c}}function pd(e,t){e.position&&(t.position=Qc(e))}function dd(e,t){let n=t;if(e&&e.data){const r=e.data.hName,i=e.data.hChildren,o=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const a="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:a}}n.type==="element"&&o&&Object.assign(n.properties,jt(o)),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function md(e,t){const n=t.data||{},r="value"in t&&!(Dn.call(n,"hProperties")||Dn.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function bd(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
`});++r<e.length;)r&&n.push({type:"text",value:`
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
`}),n}function ii(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function ai(e,t){const n=hd(e,t),r=n.one(e,void 0),i=nd(n),o=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return i&&o.children.push({type:"text",value:`
`},i),o}function gd(e,t){return e&&"run"in e?async function(n,r){const i=ai(n,{file:r,...t});await e.run(i,r)}:function(n,r){return ai(n,{file:r,...e||t})}}function oi(e){if(e)throw e}var Ft=Object.prototype.hasOwnProperty,Ha=Object.prototype.toString,li=Object.defineProperty,si=Object.getOwnPropertyDescriptor,ui=function(t){return typeof Array.isArray=="function"?Array.isArray(t):Ha.call(t)==="[object Array]"},ci=function(t){if(!t||Ha.call(t)!=="[object Object]")return!1;var n=Ft.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&Ft.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||Ft.call(t,i)},fi=function(t,n){li&&n.name==="__proto__"?li(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},hi=function(t,n){if(n==="__proto__")if(Ft.call(t,n)){if(si)return si(t,n).value}else return;return t[n]},yd=function e(){var t,n,r,i,o,a,l=arguments[0],s=1,u=arguments.length,f=!1;for(typeof l=="boolean"&&(f=l,l=arguments[1]||{},s=2),(l==null||typeof l!="object"&&typeof l!="function")&&(l={});s<u;++s)if(t=arguments[s],t!=null)for(n in t)r=hi(l,n),i=hi(t,n),l!==i&&(f&&i&&(ci(i)||(o=ui(i)))?(o?(o=!1,a=r&&ui(r)?r:[]):a=r&&ci(r)?r:{},fi(l,{name:n,newValue:e(f,a,i)})):typeof i<"u"&&fi(l,{name:n,newValue:i}));return l};const ln=_i(yd);function _n(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function xd(){const e=[],t={run:n,use:r};return t;function n(...i){let o=-1;const a=i.pop();if(typeof a!="function")throw new TypeError("Expected function as last argument, not "+a);l(null,...i);function l(s,...u){const f=e[++o];let c=-1;if(s){a(s);return}for(;++c<i.length;)(u[c]===null||u[c]===void 0)&&(u[c]=i[c]);i=u,f?kd(f,l)(...u):a(null,...u)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function kd(e,t){let n;return r;function r(...a){const l=e.length>a.length;let s;l&&a.push(i);try{s=e.apply(this,a)}catch(u){const f=u;if(l&&n)throw f;return i(f)}l||(s&&s.then&&typeof s.then=="function"?s.then(o,i):s instanceof Error?i(s):o(s))}function i(a,...l){n||(n=!0,t(a,...l))}function o(a){i(null,a)}}const xe={basename:wd,dirname:vd,extname:Cd,join:Sd,sep:"/"};function wd(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');xt(e);let n=0,r=-1,i=e.length,o;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(o){n=i+1;break}}else r<0&&(o=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let a=-1,l=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(o){n=i+1;break}}else a<0&&(o=!0,a=i+1),l>-1&&(e.codePointAt(i)===t.codePointAt(l--)?l<0&&(r=i):(l=-1,r=a));return n===r?r=a:r<0&&(r=e.length),e.slice(n,r)}function vd(e){if(xt(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function Cd(e){xt(e);let t=e.length,n=-1,r=0,i=-1,o=0,a;for(;t--;){const l=e.codePointAt(t);if(l===47){if(a){r=t+1;break}continue}n<0&&(a=!0,n=t+1),l===46?i<0?i=t:o!==1&&(o=1):i>-1&&(o=-1)}return i<0||n<0||o===0||o===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function Sd(...e){let t=-1,n;for(;++t<e.length;)xt(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Ed(n)}function Ed(e){xt(e);const t=e.codePointAt(0)===47;let n=Ad(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Ad(e,t){let n="",r=0,i=-1,o=0,a=-1,l,s;for(;++a<=e.length;){if(a<e.length)l=e.codePointAt(a);else{if(l===47)break;l=47}if(l===47){if(!(i===a-1||o===1))if(i!==a-1&&o===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(s=n.lastIndexOf("/"),s!==n.length-1){s<0?(n="",r=0):(n=n.slice(0,s),r=n.length-1-n.lastIndexOf("/")),i=a,o=0;continue}}else if(n.length>0){n="",r=0,i=a,o=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,a):n=e.slice(i+1,a),r=a-i-1;i=a,o=0}else l===46&&o>-1?o++:o=-1}return n}function xt(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Id={cwd:Fd};function Fd(){return"/"}function Tn(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function Dd(e){if(typeof e=="string")e=new URL(e);else if(!Tn(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return _d(e)}function _d(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const sn=["history","path","basename","stem","extname","dirname"];class qa{constructor(t){let n;t?Tn(t)?n={path:t}:typeof t=="string"||Td(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":Id.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<sn.length;){const o=sn[r];o in n&&n[o]!==void 0&&n[o]!==null&&(this[o]=o==="history"?[...n[o]]:n[o])}let i;for(i in n)sn.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?xe.basename(this.path):void 0}set basename(t){cn(t,"basename"),un(t,"basename"),this.path=xe.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?xe.dirname(this.path):void 0}set dirname(t){pi(this.basename,"dirname"),this.path=xe.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?xe.extname(this.path):void 0}set extname(t){if(un(t,"extname"),pi(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=xe.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Tn(t)&&(t=Dd(t)),cn(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?xe.basename(this.path,this.extname):void 0}set stem(t){cn(t,"stem"),un(t,"stem"),this.path=xe.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const i=this.message(t,n,r);throw i.fatal=!0,i}info(t,n,r){const i=this.message(t,n,r);return i.fatal=void 0,i}message(t,n,r){const i=new ie(t,n,r);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function un(e,t){if(e&&e.includes(xe.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+xe.sep+"`")}function cn(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function pi(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function Td(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Pd=function(e){const r=this.constructor.prototype,i=r[e],o=function(){return i.apply(o,arguments)};return Object.setPrototypeOf(o,r),o},Ld={}.hasOwnProperty;class Kn extends Pd{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=xd()}copy(){const t=new Kn;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(ln(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(pn("data",this.frozen),this.namespace[t]=n,this):Ld.call(this.namespace,t)&&this.namespace[t]||void 0:t?(pn("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const i=n.call(t,...r);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=St(t),r=this.parser||this.Parser;return fn("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),fn("process",this.parser||this.Parser),hn("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(o,a){const l=St(t),s=r.parse(l);r.run(s,l,function(f,c,p){if(f||!c||!p)return u(f);const h=c,d=r.stringify(h,p);Rd(d)?p.value=d:p.result=d,u(f,p)});function u(f,c){f||!c?a(f):o?o(c):n(void 0,c)}}}processSync(t){let n=!1,r;return this.freeze(),fn("processSync",this.parser||this.Parser),hn("processSync",this.compiler||this.Compiler),this.process(t,i),mi("processSync","process",n),r;function i(o,a){n=!0,oi(o),r=a}}run(t,n,r){di(t),this.freeze();const i=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?o(void 0,r):new Promise(o);function o(a,l){const s=St(n);i.run(t,s,u);function u(f,c,p){const h=c||t;f?l(f):a?a(h):r(void 0,h,p)}}}runSync(t,n){let r=!1,i;return this.run(t,n,o),mi("runSync","run",r),i;function o(a,l){oi(a),i=l,r=!0}}stringify(t,n){this.freeze();const r=St(n),i=this.compiler||this.Compiler;return hn("stringify",i),di(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(pn("use",this.frozen),t!=null)if(typeof t=="function")s(t,n);else if(typeof t=="object")Array.isArray(t)?l(t):a(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function o(u){if(typeof u=="function")s(u,[]);else if(typeof u=="object")if(Array.isArray(u)){const[f,...c]=u;s(f,c)}else a(u);else throw new TypeError("Expected usable value, not `"+u+"`")}function a(u){if(!("plugins"in u)&&!("settings"in u))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");l(u.plugins),u.settings&&(i.settings=ln(!0,i.settings,u.settings))}function l(u){let f=-1;if(u!=null)if(Array.isArray(u))for(;++f<u.length;){const c=u[f];o(c)}else throw new TypeError("Expected a list of plugins, not `"+u+"`")}function s(u,f){let c=-1,p=-1;for(;++c<r.length;)if(r[c][0]===u){p=c;break}if(p===-1)r.push([u,...f]);else if(f.length>0){let[h,...d]=f;const g=r[p][1];_n(g)&&_n(h)&&(h=ln(!0,g,h)),r[p]=[u,h,...d]}}}}const Od=new Kn().freeze();function fn(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function hn(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function pn(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function di(e){if(!_n(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function mi(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function St(e){return Md(e)?e:new qa(e)}function Md(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Rd(e){return typeof e=="string"||zd(e)}function zd(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const Nd="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",bi=[],gi={allowDangerousHtml:!0},Bd=/^(https?|ircs?|mailto|xmpp)$/i,jd=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function $d(e){const t=e.allowedElements,n=e.allowElement,r=e.children||"",i=e.className,o=e.components,a=e.disallowedElements,l=e.rehypePlugins||bi,s=e.remarkPlugins||bi,u=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...gi}:gi,f=e.skipHtml,c=e.unwrapDisallowed,p=e.urlTransform||Wd,h=Od().use(Cp).use(s).use(gd,u).use(l),d=new qa;typeof r=="string"&&(d.value=r);for(const v of jd)Object.hasOwn(e,v.from)&&(""+v.from+(v.to?"use `"+v.to+"` instead":"remove it")+Nd+v.id,void 0);const g=h.parse(d);let C=h.runSync(g,d);return i&&(C={type:"element",tagName:"div",properties:{className:i},children:C.type==="root"?C.children:[C]}),Jn(C,y),af(C,{Fragment:z.Fragment,components:o,ignoreInvalidStyle:!0,jsx:z.jsx,jsxs:z.jsxs,passKeys:!0,passNode:!0});function y(v,S,P){if(v.type==="raw"&&P&&typeof S=="number")return f?P.children.splice(S,1):P.children[S]={type:"text",value:v.value},S;if(v.type==="element"){let D;for(D in rn)if(Object.hasOwn(rn,D)&&Object.hasOwn(v.properties,D)){const k=v.properties[D],M=rn[D];(M===null||M.includes(v.tagName))&&(v.properties[D]=p(String(k||""),D,v))}}if(v.type==="element"){let D=t?!t.includes(v.tagName):a?a.includes(v.tagName):!1;if(!D&&n&&typeof S=="number"&&(D=!n(v,S,P)),D&&P&&typeof S=="number")return c&&v.children?P.children.splice(S,1,...v.children):P.children.splice(S,1),S}}}function Wd(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),i=e.indexOf("/");return t<0||i>-1&&t>i||n>-1&&t>n||r>-1&&t>r||Bd.test(e.slice(0,t))?e:""}function yi(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}function Ud(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function Hd(e,t,n){const i=Vt((n||{}).ignore||[]),o=qd(t);let a=-1;for(;++a<o.length;)Ua(e,"text",l);function l(u,f){let c=-1,p;for(;++c<f.length;){const h=f[c],d=p?p.children:void 0;if(i(h,d?d.indexOf(h):void 0,p))return;p=h}if(p)return s(u,f)}function s(u,f){const c=f[f.length-1],p=o[a][0],h=o[a][1];let d=0;const C=c.children.indexOf(u);let y=!1,v=[];p.lastIndex=0;let S=p.exec(u.value);for(;S;){const P=S.index,D={index:S.index,input:S.input,stack:[...f,u]};let k=h(...S,D);if(typeof k=="string"&&(k=k.length>0?{type:"text",value:k}:void 0),k===!1?p.lastIndex=P+1:(d!==P&&v.push({type:"text",value:u.value.slice(d,P)}),Array.isArray(k)?v.push(...k):k&&v.push(k),d=P+S[0].length,y=!0),!p.global)break;S=p.exec(u.value)}return y?(d<u.value.length&&v.push({type:"text",value:u.value.slice(d)}),c.children.splice(C,1,...v)):v=[u],C+v.length}}function qd(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const i=n[r];t.push([Vd(i[0]),Gd(i[1])])}return t}function Vd(e){return typeof e=="string"?new RegExp(Ud(e),"g"):e}function Gd(e){return typeof e=="function"?e:function(){return e}}const dn="phrasing",mn=["autolink","link","image","label"];function Yd(){return{transforms:[t0],enter:{literalAutolink:Jd,literalAutolinkEmail:bn,literalAutolinkHttp:bn,literalAutolinkWww:bn},exit:{literalAutolink:e0,literalAutolinkEmail:Zd,literalAutolinkHttp:Kd,literalAutolinkWww:Qd}}}function Xd(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:dn,notInConstruct:mn},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:dn,notInConstruct:mn},{character:":",before:"[ps]",after:"\\/",inConstruct:dn,notInConstruct:mn}]}}function Jd(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function bn(e){this.config.enter.autolinkProtocol.call(this,e)}function Kd(e){this.config.exit.autolinkProtocol.call(this,e)}function Qd(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.type,t.url="http://"+this.sliceSerialize(e)}function Zd(e){this.config.exit.autolinkEmail.call(this,e)}function e0(e){this.exit(e)}function t0(e){Hd(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,n0],[new RegExp("(?<=^|\\s|\\p{P}|\\p{S})([-.\\w+]+)@([-\\w]+(?:\\.[-\\w]+)+)","gu"),r0]],{ignore:["link","linkReference"]})}function n0(e,t,n,r,i){let o="";if(!Va(i)||(/^w/i.test(t)&&(n=t+n,t="",o="http://"),!i0(n)))return!1;const a=a0(n+r);if(!a[0])return!1;const l={type:"link",title:null,url:o+t+a[0],children:[{type:"text",value:t+a[0]}]};return a[1]?[l,{type:"text",value:a[1]}]:l}function r0(e,t,n,r){return!Va(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function i0(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function a0(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const i=yi(e,"(");let o=yi(e,")");for(;r!==-1&&i>o;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),o++;return[e,n]}function Va(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Re(n)||Ut(n))&&(!t||n!==47)}Ga.peek=b0;function o0(){return{enter:{gfmFootnoteDefinition:s0,gfmFootnoteDefinitionLabelString:u0,gfmFootnoteCall:h0,gfmFootnoteCallString:p0},exit:{gfmFootnoteDefinition:f0,gfmFootnoteDefinitionLabelString:c0,gfmFootnoteCall:m0,gfmFootnoteCallString:d0}}}function l0(){return{unsafe:[{character:"[",inConstruct:["phrasing","label","reference"]}],handlers:{footnoteDefinition:g0,footnoteReference:Ga}}}function s0(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function u0(){this.buffer()}function c0(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=ye(this.sliceSerialize(e)).toLowerCase()}function f0(e){this.exit(e)}function h0(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function p0(){this.buffer()}function d0(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.label=t,n.identifier=ye(this.sliceSerialize(e)).toLowerCase()}function m0(e){this.exit(e)}function Ga(e,t,n,r){const i=n.createTracker(r);let o=i.move("[^");const a=n.enter("footnoteReference"),l=n.enter("reference");return o+=i.move(n.safe(n.associationId(e),{...i.current(),before:o,after:"]"})),l(),a(),o+=i.move("]"),o}function b0(){return"["}function g0(e,t,n,r){const i=n.createTracker(r);let o=i.move("[^");const a=n.enter("footnoteDefinition"),l=n.enter("label");return o+=i.move(n.safe(n.associationId(e),{...i.current(),before:o,after:"]"})),l(),o+=i.move("]:"+(e.children&&e.children.length>0?" ":"")),i.shift(4),o+=i.move(n.indentLines(n.containerFlow(e,i.current()),y0)),a(),o}function y0(e,t,n){return t===0?e:(n?"":"    ")+e}const x0=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];Ya.peek=S0;function k0(){return{canContainEols:["delete"],enter:{strikethrough:v0},exit:{strikethrough:C0}}}function w0(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:x0}],handlers:{delete:Ya}}}function v0(e){this.enter({type:"delete",children:[]},e)}function C0(e){this.exit(e)}function Ya(e,t,n,r){const i=n.createTracker(r),o=n.enter("strikethrough");let a=i.move("~~");return a+=n.containerPhrasing(e,{...i.current(),before:a,after:"~"}),a+=i.move("~~"),o(),a}function S0(){return"~"}function E0(e){return e.length}function A0(e,t){const n=t||{},r=(n.align||[]).concat(),i=n.stringLength||E0,o=[],a=[],l=[],s=[];let u=0,f=-1;for(;++f<e.length;){const g=[],C=[];let y=-1;for(e[f].length>u&&(u=e[f].length);++y<e[f].length;){const v=I0(e[f][y]);if(n.alignDelimiters!==!1){const S=i(v);C[y]=S,(s[y]===void 0||S>s[y])&&(s[y]=S)}g.push(v)}a[f]=g,l[f]=C}let c=-1;if(typeof r=="object"&&"length"in r)for(;++c<u;)o[c]=xi(r[c]);else{const g=xi(r);for(;++c<u;)o[c]=g}c=-1;const p=[],h=[];for(;++c<u;){const g=o[c];let C="",y="";g===99?(C=":",y=":"):g===108?C=":":g===114&&(y=":");let v=n.alignDelimiters===!1?1:Math.max(1,s[c]-C.length-y.length);const S=C+"-".repeat(v)+y;n.alignDelimiters!==!1&&(v=C.length+v+y.length,v>s[c]&&(s[c]=v),h[c]=v),p[c]=S}a.splice(1,0,p),l.splice(1,0,h),f=-1;const d=[];for(;++f<a.length;){const g=a[f],C=l[f];c=-1;const y=[];for(;++c<u;){const v=g[c]||"";let S="",P="";if(n.alignDelimiters!==!1){const D=s[c]-(C[c]||0),k=o[c];k===114?S=" ".repeat(D):k===99?D%2?(S=" ".repeat(D/2+.5),P=" ".repeat(D/2-.5)):(S=" ".repeat(D/2),P=S):P=" ".repeat(D)}n.delimiterStart!==!1&&!c&&y.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&v==="")&&(n.delimiterStart!==!1||c)&&y.push(" "),n.alignDelimiters!==!1&&y.push(S),y.push(v),n.alignDelimiters!==!1&&y.push(P),n.padding!==!1&&y.push(" "),(n.delimiterEnd!==!1||c!==u-1)&&y.push("|")}d.push(n.delimiterEnd===!1?y.join("").replace(/ +$/,""):y.join(""))}return d.join(`
`)}function I0(e){return e==null?"":String(e)}function xi(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function F0(e,t,n,r){const i=n.enter("blockquote"),o=n.createTracker(r);o.move("> "),o.shift(2);const a=n.indentLines(n.containerFlow(e,o.current()),D0);return i(),a}function D0(e,t,n){return">"+(n?"":" ")+e}function _0(e,t){return ki(e,t.inConstruct,!0)&&!ki(e,t.notInConstruct,!1)}function ki(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function wi(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
`&&_0(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?"":" ";return`\\
`}function T0(e,t){const n=String(e);let r=n.indexOf(t),i=r,o=0,a=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===i?++o>a&&(a=o):o=1,i=r+t.length,r=n.indexOf(t,i);return a}function P0(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function L0(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function O0(e,t,n,r){const i=L0(n),o=e.value||"",a=i==="`"?"GraveAccent":"Tilde";if(P0(e,n)){const c=n.enter("codeIndented"),p=n.indentLines(o,M0);return c(),p}const l=n.createTracker(r),s=i.repeat(Math.max(T0(o,i)+1,3)),u=n.enter("codeFenced");let f=l.move(s);if(e.lang){const c=n.enter(`codeFencedLang${a}`);f+=l.move(n.safe(e.lang,{before:f,after:" ",encode:["`"],...l.current()})),c()}if(e.lang&&e.meta){const c=n.enter(`codeFencedMeta${a}`);f+=l.move(" "),f+=l.move(n.safe(e.meta,{before:f,after:`
`,encode:["`"],...l.current()})),c()}return f+=l.move(`
`),o&&(f+=l.move(o+`
`)),f+=l.move(s),u(),f}function M0(e,t,n){return(n?"":"    ")+e}function Qn(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function R0(e,t,n,r){const i=Qn(n),o=i==='"'?"Quote":"Apostrophe",a=n.enter("definition");let l=n.enter("label");const s=n.createTracker(r);let u=s.move("[");return u+=s.move(n.safe(n.associationId(e),{before:u,after:"]",...s.current()})),u+=s.move("]: "),l(),!e.url||/[\0- \u007F]/.test(e.url)?(l=n.enter("destinationLiteral"),u+=s.move("<"),u+=s.move(n.safe(e.url,{before:u,after:">",...s.current()})),u+=s.move(">")):(l=n.enter("destinationRaw"),u+=s.move(n.safe(e.url,{before:u,after:e.title?" ":`
`,...s.current()}))),l(),e.title&&(l=n.enter(`title${o}`),u+=s.move(" "+i),u+=s.move(n.safe(e.title,{before:u,after:i,...s.current()})),u+=s.move(i),l()),a(),u}function z0(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function mt(e){return"&#x"+e.toString(16).toUpperCase()+";"}function $t(e,t,n){const r=Ke(e),i=Ke(t);return r===void 0?i===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}Xa.peek=N0;function Xa(e,t,n,r){const i=z0(n),o=n.enter("emphasis"),a=n.createTracker(r),l=a.move(i);let s=a.move(n.containerPhrasing(e,{after:i,before:l,...a.current()}));const u=s.charCodeAt(0),f=$t(r.before.charCodeAt(r.before.length-1),u,i);f.inside&&(s=mt(u)+s.slice(1));const c=s.charCodeAt(s.length-1),p=$t(r.after.charCodeAt(0),c,i);p.inside&&(s=s.slice(0,-1)+mt(c));const h=a.move(i);return o(),n.attentionEncodeSurroundingInfo={after:p.outside,before:f.outside},l+s+h}function N0(e,t,n){return n.options.emphasis||"*"}function B0(e,t){let n=!1;return Jn(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Fn}),!!((!e.depth||e.depth<3)&&Un(e)&&(t.options.setext||n))}function j0(e,t,n,r){const i=Math.max(Math.min(6,e.depth||1),1),o=n.createTracker(r);if(B0(e,n)){const f=n.enter("headingSetext"),c=n.enter("phrasing"),p=n.containerPhrasing(e,{...o.current(),before:`
`,after:`
`});return c(),f(),p+`
`+(i===1?"=":"-").repeat(p.length-(Math.max(p.lastIndexOf("\r"),p.lastIndexOf(`
`))+1))}const a="#".repeat(i),l=n.enter("headingAtx"),s=n.enter("phrasing");o.move(a+" ");let u=n.containerPhrasing(e,{before:"# ",after:`
`,...o.current()});return/^[\t ]/.test(u)&&(u=mt(u.charCodeAt(0))+u.slice(1)),u=u?a+" "+u:a,n.options.closeAtx&&(u+=" "+a),s(),l(),u}Ja.peek=$0;function Ja(e){return e.value||""}function $0(){return"<"}Ka.peek=W0;function Ka(e,t,n,r){const i=Qn(n),o=i==='"'?"Quote":"Apostrophe",a=n.enter("image");let l=n.enter("label");const s=n.createTracker(r);let u=s.move("![");return u+=s.move(n.safe(e.alt,{before:u,after:"]",...s.current()})),u+=s.move("]("),l(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(l=n.enter("destinationLiteral"),u+=s.move("<"),u+=s.move(n.safe(e.url,{before:u,after:">",...s.current()})),u+=s.move(">")):(l=n.enter("destinationRaw"),u+=s.move(n.safe(e.url,{before:u,after:e.title?" ":")",...s.current()}))),l(),e.title&&(l=n.enter(`title${o}`),u+=s.move(" "+i),u+=s.move(n.safe(e.title,{before:u,after:i,...s.current()})),u+=s.move(i),l()),u+=s.move(")"),a(),u}function W0(){return"!"}Qa.peek=U0;function Qa(e,t,n,r){const i=e.referenceType,o=n.enter("imageReference");let a=n.enter("label");const l=n.createTracker(r);let s=l.move("![");const u=n.safe(e.alt,{before:s,after:"]",...l.current()});s+=l.move(u+"]["),a();const f=n.stack;n.stack=[],a=n.enter("reference");const c=n.safe(n.associationId(e),{before:s,after:"]",...l.current()});return a(),n.stack=f,o(),i==="full"||!u||u!==c?s+=l.move(c+"]"):i==="shortcut"?s=s.slice(0,-1):s+=l.move("]"),s}function U0(){return"!"}Za.peek=H0;function Za(e,t,n){let r=e.value||"",i="`",o=-1;for(;new RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++o<n.unsafe.length;){const a=n.unsafe[o],l=n.compilePattern(a);let s;if(a.atBreak)for(;s=l.exec(r);){let u=s.index;r.charCodeAt(u)===10&&r.charCodeAt(u-1)===13&&u--,r=r.slice(0,u)+" "+r.slice(s.index+1)}}return i+r+i}function H0(){return"`"}function eo(e,t){const n=Un(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}to.peek=q0;function to(e,t,n,r){const i=Qn(n),o=i==='"'?"Quote":"Apostrophe",a=n.createTracker(r);let l,s;if(eo(e,n)){const f=n.stack;n.stack=[],l=n.enter("autolink");let c=a.move("<");return c+=a.move(n.containerPhrasing(e,{before:c,after:">",...a.current()})),c+=a.move(">"),l(),n.stack=f,c}l=n.enter("link"),s=n.enter("label");let u=a.move("[");return u+=a.move(n.containerPhrasing(e,{before:u,after:"](",...a.current()})),u+=a.move("]("),s(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(s=n.enter("destinationLiteral"),u+=a.move("<"),u+=a.move(n.safe(e.url,{before:u,after:">",...a.current()})),u+=a.move(">")):(s=n.enter("destinationRaw"),u+=a.move(n.safe(e.url,{before:u,after:e.title?" ":")",...a.current()}))),s(),e.title&&(s=n.enter(`title${o}`),u+=a.move(" "+i),u+=a.move(n.safe(e.title,{before:u,after:i,...a.current()})),u+=a.move(i),s()),u+=a.move(")"),l(),u}function q0(e,t,n){return eo(e,n)?"<":"["}no.peek=V0;function no(e,t,n,r){const i=e.referenceType,o=n.enter("linkReference");let a=n.enter("label");const l=n.createTracker(r);let s=l.move("[");const u=n.containerPhrasing(e,{before:s,after:"]",...l.current()});s+=l.move(u+"]["),a();const f=n.stack;n.stack=[],a=n.enter("reference");const c=n.safe(n.associationId(e),{before:s,after:"]",...l.current()});return a(),n.stack=f,o(),i==="full"||!u||u!==c?s+=l.move(c+"]"):i==="shortcut"?s=s.slice(0,-1):s+=l.move("]"),s}function V0(){return"["}function Zn(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function G0(e){const t=Zn(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function Y0(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function ro(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function X0(e,t,n,r){const i=n.enter("list"),o=n.bulletCurrent;let a=e.ordered?Y0(n):Zn(n);const l=e.ordered?a==="."?")":".":G0(n);let s=t&&n.bulletLastUsed?a===n.bulletLastUsed:!1;if(!e.ordered){const f=e.children?e.children[0]:void 0;if((a==="*"||a==="-")&&f&&(!f.children||!f.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(s=!0),ro(n)===a&&f){let c=-1;for(;++c<e.children.length;){const p=e.children[c];if(p&&p.type==="listItem"&&p.children&&p.children[0]&&p.children[0].type==="thematicBreak"){s=!0;break}}}}s&&(a=l),n.bulletCurrent=a;const u=n.containerFlow(e,r);return n.bulletLastUsed=a,n.bulletCurrent=o,i(),u}function J0(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function K0(e,t,n,r){const i=J0(n);let o=n.bulletCurrent||Zn(n);t&&t.type==="list"&&t.ordered&&(o=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+o);let a=o.length+1;(i==="tab"||i==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(a=Math.ceil(a/4)*4);const l=n.createTracker(r);l.move(o+" ".repeat(a-o.length)),l.shift(a);const s=n.enter("listItem"),u=n.indentLines(n.containerFlow(e,l.current()),f);return s(),u;function f(c,p,h){return p?(h?"":" ".repeat(a))+c:(h?o:o+" ".repeat(a-o.length))+c}}function Q0(e,t,n,r){const i=n.enter("paragraph"),o=n.enter("phrasing"),a=n.containerPhrasing(e,r);return o(),i(),a}const Z0=Vt(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function em(e,t,n,r){return(e.children.some(function(a){return Z0(a)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function tm(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}io.peek=nm;function io(e,t,n,r){const i=tm(n),o=n.enter("strong"),a=n.createTracker(r),l=a.move(i+i);let s=a.move(n.containerPhrasing(e,{after:i,before:l,...a.current()}));const u=s.charCodeAt(0),f=$t(r.before.charCodeAt(r.before.length-1),u,i);f.inside&&(s=mt(u)+s.slice(1));const c=s.charCodeAt(s.length-1),p=$t(r.after.charCodeAt(0),c,i);p.inside&&(s=s.slice(0,-1)+mt(c));const h=a.move(i+i);return o(),n.attentionEncodeSurroundingInfo={after:p.outside,before:f.outside},l+s+h}function nm(e,t,n){return n.options.strong||"*"}function rm(e,t,n,r){return n.safe(e.value,r)}function im(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function am(e,t,n){const r=(ro(n)+(n.options.ruleSpaces?" ":"")).repeat(im(n));return n.options.ruleSpaces?r.slice(0,-1):r}const ao={blockquote:F0,break:wi,code:O0,definition:R0,emphasis:Xa,hardBreak:wi,heading:j0,html:Ja,image:Ka,imageReference:Qa,inlineCode:Za,link:to,linkReference:no,list:X0,listItem:K0,paragraph:Q0,root:em,strong:io,text:rm,thematicBreak:am};function om(){return{enter:{table:lm,tableData:vi,tableHeader:vi,tableRow:um},exit:{codeText:cm,table:sm,tableData:gn,tableHeader:gn,tableRow:gn}}}function lm(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function sm(e){this.exit(e),this.data.inTable=void 0}function um(e){this.enter({type:"tableRow",children:[]},e)}function gn(e){this.exit(e)}function vi(e){this.enter({type:"tableCell",children:[]},e)}function cm(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,fm));const n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function fm(e,t){return t==="|"?t:e}function hm(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,o=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[	 :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:p,table:a,tableCell:s,tableRow:l}};function a(h,d,g,C){return u(f(h,g,C),h.align)}function l(h,d,g,C){const y=c(h,g,C),v=u([y]);return v.slice(0,v.indexOf(`
`))}function s(h,d,g,C){const y=g.enter("tableCell"),v=g.enter("phrasing"),S=g.containerPhrasing(h,{...C,before:o,after:o});return v(),y(),S}function u(h,d){return A0(h,{align:d,alignDelimiters:r,padding:n,stringLength:i})}function f(h,d,g){const C=h.children;let y=-1;const v=[],S=d.enter("table");for(;++y<C.length;)v[y]=c(C[y],d,g);return S(),v}function c(h,d,g){const C=h.children;let y=-1;const v=[],S=d.enter("tableRow");for(;++y<C.length;)v[y]=s(C[y],h,d,g);return S(),v}function p(h,d,g){let C=ao.inlineCode(h,d,g);return g.stack.includes("tableCell")&&(C=C.replace(/\|/g,"\\$&")),C}}function pm(){return{exit:{taskListCheckValueChecked:Ci,taskListCheckValueUnchecked:Ci,paragraph:mm}}}function dm(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:bm}}}function Ci(e){const t=this.stack[this.stack.length-2];t.type,t.checked=e.type==="taskListCheckValueChecked"}function mm(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1];n.type;const r=n.children[0];if(r&&r.type==="text"){const i=t.children;let o=-1,a;for(;++o<i.length;){const l=i[o];if(l.type==="paragraph"){a=l;break}}a===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(e)}function bm(e,t,n,r){const i=e.children[0],o=typeof e.checked=="boolean"&&i&&i.type==="paragraph",a="["+(e.checked?"x":" ")+"] ",l=n.createTracker(r);o&&l.move(a);let s=ao.listItem(e,t,n,{...r,...l.current()});return o&&(s=s.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,u)),s;function u(f){return f+a}}function gm(){return[Yd(),o0(),k0(),om(),pm()]}function ym(e){return{extensions:[Xd(),l0(),w0(),hm(e),dm()]}}const xm={tokenize:Em,partial:!0},oo={tokenize:Am,partial:!0},lo={tokenize:Im,partial:!0},so={tokenize:Fm,partial:!0},km={tokenize:Dm,partial:!0},uo={name:"wwwAutolink",tokenize:Cm,previous:fo},co={name:"protocolAutolink",tokenize:Sm,previous:ho},Ae={name:"emailAutolink",tokenize:vm,previous:po},ke={};function wm(){return{text:ke}}let Oe=48;for(;Oe<123;)ke[Oe]=Ae,Oe++,Oe===58?Oe=65:Oe===91&&(Oe=97);ke[43]=Ae;ke[45]=Ae;ke[46]=Ae;ke[95]=Ae;ke[72]=[Ae,co];ke[104]=[Ae,co];ke[87]=[Ae,uo];ke[119]=[Ae,uo];function vm(e,t,n){const r=this;let i,o;return a;function a(c){return!Pn(c)||!po.call(r,r.previous)||er(r.events)?n(c):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),l(c))}function l(c){return Pn(c)?(e.consume(c),l):c===64?(e.consume(c),s):n(c)}function s(c){return c===46?e.check(km,f,u)(c):c===45||c===95||re(c)?(o=!0,e.consume(c),s):f(c)}function u(c){return e.consume(c),i=!0,s}function f(c){return o&&i&&ae(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(c)):n(c)}}function Cm(e,t,n){const r=this;return i;function i(a){return a!==87&&a!==119||!fo.call(r,r.previous)||er(r.events)?n(a):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(xm,e.attempt(oo,e.attempt(lo,o),n),n)(a))}function o(a){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(a)}}function Sm(e,t,n){const r=this;let i="",o=!1;return a;function a(c){return(c===72||c===104)&&ho.call(r,r.previous)&&!er(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),i+=String.fromCodePoint(c),e.consume(c),l):n(c)}function l(c){if(ae(c)&&i.length<5)return i+=String.fromCodePoint(c),e.consume(c),l;if(c===58){const p=i.toLowerCase();if(p==="http"||p==="https")return e.consume(c),s}return n(c)}function s(c){return c===47?(e.consume(c),o?u:(o=!0,s)):n(c)}function u(c){return c===null||zt(c)||V(c)||Re(c)||Ut(c)?n(c):e.attempt(oo,e.attempt(lo,f),n)(c)}function f(c){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(c)}}function Em(e,t,n){let r=0;return i;function i(a){return(a===87||a===119)&&r<3?(r++,e.consume(a),i):a===46&&r===3?(e.consume(a),o):n(a)}function o(a){return a===null?n(a):t(a)}}function Am(e,t,n){let r,i,o;return a;function a(u){return u===46||u===95?e.check(so,s,l)(u):u===null||V(u)||Re(u)||u!==45&&Ut(u)?s(u):(o=!0,e.consume(u),a)}function l(u){return u===95?r=!0:(i=r,r=void 0),e.consume(u),a}function s(u){return i||r||!o?n(u):t(u)}}function Im(e,t){let n=0,r=0;return i;function i(a){return a===40?(n++,e.consume(a),i):a===41&&r<n?o(a):a===33||a===34||a===38||a===39||a===41||a===42||a===44||a===46||a===58||a===59||a===60||a===63||a===93||a===95||a===126?e.check(so,t,o)(a):a===null||V(a)||Re(a)?t(a):(e.consume(a),i)}function o(a){return a===41&&r++,e.consume(a),i}}function Fm(e,t,n){return r;function r(l){return l===33||l===34||l===39||l===41||l===42||l===44||l===46||l===58||l===59||l===63||l===95||l===126?(e.consume(l),r):l===38?(e.consume(l),o):l===93?(e.consume(l),i):l===60||l===null||V(l)||Re(l)?t(l):n(l)}function i(l){return l===null||l===40||l===91||V(l)||Re(l)?t(l):r(l)}function o(l){return ae(l)?a(l):n(l)}function a(l){return l===59?(e.consume(l),r):ae(l)?(e.consume(l),a):n(l)}}function Dm(e,t,n){return r;function r(o){return e.consume(o),i}function i(o){return re(o)?n(o):t(o)}}function fo(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||V(e)}function ho(e){return!ae(e)}function po(e){return!(e===47||Pn(e))}function Pn(e){return e===43||e===45||e===46||e===95||re(e)}function er(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}const _m={tokenize:Nm,partial:!0};function Tm(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:Mm,continuation:{tokenize:Rm},exit:zm}},text:{91:{name:"gfmFootnoteCall",tokenize:Om},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:Pm,resolveTo:Lm}}}}function Pm(e,t,n){const r=this;let i=r.events.length;const o=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a;for(;i--;){const s=r.events[i][1];if(s.type==="labelImage"){a=s;break}if(s.type==="gfmFootnoteCall"||s.type==="labelLink"||s.type==="label"||s.type==="image"||s.type==="link")break}return l;function l(s){if(!a||!a._balanced)return n(s);const u=ye(r.sliceSerialize({start:a.end,end:r.now()}));return u.codePointAt(0)!==94||!o.includes(u.slice(1))?n(s):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(s),e.exit("gfmFootnoteCallLabelMarker"),t(s))}}function Lm(e,t){let n=e.length;for(;n--;)if(e[n][1].type==="labelImage"&&e[n][0]==="enter"){e[n][1];break}e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;const o={type:"gfmFootnoteCallString",start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},a={type:"chunkString",contentType:"string",start:Object.assign({},o.start),end:Object.assign({},o.end)},l=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",i,t],["exit",i,t],["enter",o,t],["enter",a,t],["exit",a,t],["exit",o,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...l),e}function Om(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let o=0,a;return l;function l(c){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(c),e.exit("gfmFootnoteCallLabelMarker"),s}function s(c){return c!==94?n(c):(e.enter("gfmFootnoteCallMarker"),e.consume(c),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",u)}function u(c){if(o>999||c===93&&!a||c===null||c===91||V(c))return n(c);if(c===93){e.exit("chunkString");const p=e.exit("gfmFootnoteCallString");return i.includes(ye(r.sliceSerialize(p)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(c),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(c)}return V(c)||(a=!0),o++,e.consume(c),c===92?f:u}function f(c){return c===91||c===92||c===93?(e.consume(c),o++,u):u(c)}}function Mm(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let o,a=0,l;return s;function s(d){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(d),e.exit("gfmFootnoteDefinitionLabelMarker"),u}function u(d){return d===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(d),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",f):n(d)}function f(d){if(a>999||d===93&&!l||d===null||d===91||V(d))return n(d);if(d===93){e.exit("chunkString");const g=e.exit("gfmFootnoteDefinitionLabelString");return o=ye(r.sliceSerialize(g)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(d),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),p}return V(d)||(l=!0),a++,e.consume(d),d===92?c:f}function c(d){return d===91||d===92||d===93?(e.consume(d),a++,f):f(d)}function p(d){return d===58?(e.enter("definitionMarker"),e.consume(d),e.exit("definitionMarker"),i.includes(o)||i.push(o),j(e,h,"gfmFootnoteDefinitionWhitespace")):n(d)}function h(d){return t(d)}}function Rm(e,t,n){return e.check(yt,t,e.attempt(_m,t,n))}function zm(e){e.exit("gfmFootnoteDefinition")}function Nm(e,t,n){const r=this;return j(e,i,"gfmFootnoteDefinitionIndent",5);function i(o){const a=r.events[r.events.length-1];return a&&a[1].type==="gfmFootnoteDefinitionIndent"&&a[2].sliceSerialize(a[1],!0).length===4?t(o):n(o)}}function Bm(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:o,resolveAll:i};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function i(a,l){let s=-1;for(;++s<a.length;)if(a[s][0]==="enter"&&a[s][1].type==="strikethroughSequenceTemporary"&&a[s][1]._close){let u=s;for(;u--;)if(a[u][0]==="exit"&&a[u][1].type==="strikethroughSequenceTemporary"&&a[u][1]._open&&a[s][1].end.offset-a[s][1].start.offset===a[u][1].end.offset-a[u][1].start.offset){a[s][1].type="strikethroughSequence",a[u][1].type="strikethroughSequence";const f={type:"strikethrough",start:Object.assign({},a[u][1].start),end:Object.assign({},a[s][1].end)},c={type:"strikethroughText",start:Object.assign({},a[u][1].end),end:Object.assign({},a[s][1].start)},p=[["enter",f,l],["enter",a[u][1],l],["exit",a[u][1],l],["enter",c,l]],h=l.parser.constructs.insideSpan.null;h&&fe(p,p.length,0,Ht(h,a.slice(u+1,s),l)),fe(p,p.length,0,[["exit",c,l],["enter",a[s][1],l],["exit",a[s][1],l],["exit",f,l]]),fe(a,u-1,s-u+3,p),s=u+p.length-2;break}}for(s=-1;++s<a.length;)a[s][1].type==="strikethroughSequenceTemporary"&&(a[s][1].type="data");return a}function o(a,l,s){const u=this.previous,f=this.events;let c=0;return p;function p(d){return u===126&&f[f.length-1][1].type!=="characterEscape"?s(d):(a.enter("strikethroughSequenceTemporary"),h(d))}function h(d){const g=Ke(u);if(d===126)return c>1?s(d):(a.consume(d),c++,h);if(c<2&&!n)return s(d);const C=a.exit("strikethroughSequenceTemporary"),y=Ke(d);return C._open=!y||y===2&&!!g,C._close=!g||g===2&&!!y,l(d)}}}class jm{constructor(){this.map=[]}add(t,n,r){$m(this,t,n,r)}consume(t){if(this.map.sort(function(o,a){return o[0]-a[0]}),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];r.push([...t]),t.length=0;let i=r.pop();for(;i;)t.push(...i),i=r.pop();this.map.length=0}}function $m(e,t,n,r){let i=0;if(!(n===0&&r.length===0)){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function Wm(e,t){let n=!1;const r=[];for(;t<e.length;){const i=e[t];if(n){if(i[0]==="enter")i[1].type==="tableContent"&&r.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(i[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const o=r.length-1;r[o]=r[o]==="left"?"center":"right"}}else if(i[1].type==="tableDelimiterRow")break}else i[0]==="enter"&&i[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return r}function Um(){return{flow:{null:{name:"table",tokenize:Hm,resolveAll:qm}}}}function Hm(e,t,n){const r=this;let i=0,o=0,a;return l;function l(x){let F=r.events.length-1;for(;F>-1;){const Y=r.events[F][1].type;if(Y==="lineEnding"||Y==="linePrefix")F--;else break}const _=F>-1?r.events[F][1].type:null,H=_==="tableHead"||_==="tableRow"?k:s;return H===k&&r.parser.lazy[r.now().line]?n(x):H(x)}function s(x){return e.enter("tableHead"),e.enter("tableRow"),u(x)}function u(x){return x===124||(a=!0,o+=1),f(x)}function f(x){return x===null?n(x):T(x)?o>1?(o=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),h):n(x):N(x)?j(e,f,"whitespace")(x):(o+=1,a&&(a=!1,i+=1),x===124?(e.enter("tableCellDivider"),e.consume(x),e.exit("tableCellDivider"),a=!0,f):(e.enter("data"),c(x)))}function c(x){return x===null||x===124||V(x)?(e.exit("data"),f(x)):(e.consume(x),x===92?p:c)}function p(x){return x===92||x===124?(e.consume(x),c):c(x)}function h(x){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(x):(e.enter("tableDelimiterRow"),a=!1,N(x)?j(e,d,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(x):d(x))}function d(x){return x===45||x===58?C(x):x===124?(a=!0,e.enter("tableCellDivider"),e.consume(x),e.exit("tableCellDivider"),g):D(x)}function g(x){return N(x)?j(e,C,"whitespace")(x):C(x)}function C(x){return x===58?(o+=1,a=!0,e.enter("tableDelimiterMarker"),e.consume(x),e.exit("tableDelimiterMarker"),y):x===45?(o+=1,y(x)):x===null||T(x)?P(x):D(x)}function y(x){return x===45?(e.enter("tableDelimiterFiller"),v(x)):D(x)}function v(x){return x===45?(e.consume(x),v):x===58?(a=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(x),e.exit("tableDelimiterMarker"),S):(e.exit("tableDelimiterFiller"),S(x))}function S(x){return N(x)?j(e,P,"whitespace")(x):P(x)}function P(x){return x===124?d(x):x===null||T(x)?!a||i!==o?D(x):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(x)):D(x)}function D(x){return n(x)}function k(x){return e.enter("tableRow"),M(x)}function M(x){return x===124?(e.enter("tableCellDivider"),e.consume(x),e.exit("tableCellDivider"),M):x===null||T(x)?(e.exit("tableRow"),t(x)):N(x)?j(e,M,"whitespace")(x):(e.enter("data"),W(x))}function W(x){return x===null||x===124||V(x)?(e.exit("data"),M(x)):(e.consume(x),x===92?U:W)}function U(x){return x===92||x===124?(e.consume(x),W):W(x)}}function qm(e,t){let n=-1,r=!0,i=0,o=[0,0,0,0],a=[0,0,0,0],l=!1,s=0,u,f,c;const p=new jm;for(;++n<e.length;){const h=e[n],d=h[1];h[0]==="enter"?d.type==="tableHead"?(l=!1,s!==0&&(Si(p,t,s,u,f),f=void 0,s=0),u={type:"table",start:Object.assign({},d.start),end:Object.assign({},d.end)},p.add(n,0,[["enter",u,t]])):d.type==="tableRow"||d.type==="tableDelimiterRow"?(r=!0,c=void 0,o=[0,0,0,0],a=[0,n+1,0,0],l&&(l=!1,f={type:"tableBody",start:Object.assign({},d.start),end:Object.assign({},d.end)},p.add(n,0,[["enter",f,t]])),i=d.type==="tableDelimiterRow"?2:f?3:1):i&&(d.type==="data"||d.type==="tableDelimiterMarker"||d.type==="tableDelimiterFiller")?(r=!1,a[2]===0&&(o[1]!==0&&(a[0]=a[1],c=Et(p,t,o,i,void 0,c),o=[0,0,0,0]),a[2]=n)):d.type==="tableCellDivider"&&(r?r=!1:(o[1]!==0&&(a[0]=a[1],c=Et(p,t,o,i,void 0,c)),o=a,a=[o[1],n,0,0])):d.type==="tableHead"?(l=!0,s=n):d.type==="tableRow"||d.type==="tableDelimiterRow"?(s=n,o[1]!==0?(a[0]=a[1],c=Et(p,t,o,i,n,c)):a[1]!==0&&(c=Et(p,t,a,i,n,c)),i=0):i&&(d.type==="data"||d.type==="tableDelimiterMarker"||d.type==="tableDelimiterFiller")&&(a[3]=n)}for(s!==0&&Si(p,t,s,u,f),p.consume(t.events),n=-1;++n<t.events.length;){const h=t.events[n];h[0]==="enter"&&h[1].type==="table"&&(h[1]._align=Wm(t.events,n))}return e}function Et(e,t,n,r,i,o){const a=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",l="tableContent";n[0]!==0&&(o.end=Object.assign({},Ve(t.events,n[0])),e.add(n[0],0,[["exit",o,t]]));const s=Ve(t.events,n[1]);if(o={type:a,start:Object.assign({},s),end:Object.assign({},s)},e.add(n[1],0,[["enter",o,t]]),n[2]!==0){const u=Ve(t.events,n[2]),f=Ve(t.events,n[3]),c={type:l,start:Object.assign({},u),end:Object.assign({},f)};if(e.add(n[2],0,[["enter",c,t]]),r!==2){const p=t.events[n[2]],h=t.events[n[3]];if(p[1].end=Object.assign({},h[1].end),p[1].type="chunkText",p[1].contentType="text",n[3]>n[2]+1){const d=n[2]+1,g=n[3]-n[2]-1;e.add(d,g,[])}}e.add(n[3]+1,0,[["exit",c,t]])}return i!==void 0&&(o.end=Object.assign({},Ve(t.events,i)),e.add(i,0,[["exit",o,t]]),o=void 0),o}function Si(e,t,n,r,i){const o=[],a=Ve(t.events,n);i&&(i.end=Object.assign({},a),o.push(["exit",i,t])),r.end=Object.assign({},a),o.push(["exit",r,t]),e.add(n+1,0,o)}function Ve(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const Vm={name:"tasklistCheck",tokenize:Ym};function Gm(){return{text:{91:Vm}}}function Ym(e,t,n){const r=this;return i;function i(s){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(s):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),o)}function o(s){return V(s)?(e.enter("taskListCheckValueUnchecked"),e.consume(s),e.exit("taskListCheckValueUnchecked"),a):s===88||s===120?(e.enter("taskListCheckValueChecked"),e.consume(s),e.exit("taskListCheckValueChecked"),a):n(s)}function a(s){return s===93?(e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),l):n(s)}function l(s){return T(s)?t(s):N(s)?e.check({tokenize:Xm},t,n)(s):n(s)}}function Xm(e,t,n){return j(e,r,"whitespace");function r(i){return i===null?n(i):t(i)}}function Jm(e){return Sa([wm(),Tm(),Bm(e),Um(),Gm()])}const Km={};function Qm(e){const t=this,n=e||Km,r=t.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),o=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),a=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(Jm(n)),o.push(gm()),a.push(ym(n))}const Zm=e=>{const t=[],n=(r,i=[])=>{if(typeof r=="string"){t.push({path:[...i],value:r});return}typeof r!="object"||r===null||Object.entries(r).forEach(([o,a])=>{n(a,[...i,o])})};return n(e),t.length===1?t[0]:null},Ei=240,mo=({input:e,shouldTruncateText:t,Wrapper:n,className:r})=>{const[i,o]=te.useState("no-show-more-button-required"),a=te.useRef(null);return te.useLayoutEffect(()=>{a.current&&t&&a.current.scrollHeight>Ei&&o("showing-show-more-button")},[e,t]),z.jsxs("div",{className:r,children:[z.jsx(n,{children:z.jsx("div",{ref:a,style:{maxHeight:i==="showing-show-more-button"&&t?`${Ei}px`:"none",overflow:"hidden"},children:z.jsx($d,{className:"prose prose-sm",remarkPlugins:[Qm],children:e})})}),i==="showing-show-more-button"&&t&&z.jsxs(Ti,{onClick:()=>{o("showing-more")},variant:"secondary",size:"sm",className:"mt-3 mb-5",children:[z.jsx(Fo,{}),"Show more"]})]})},eb=({input:e,name:t})=>{const n=Zm(e);return n?z.jsxs("div",{children:[n.path.length>0&&z.jsxs("div",{className:"flex items-center text-sm text-muted-foreground mb-2",children:[z.jsx("span",{className:"font-mono",children:t??"object"}),n.path.map((r,i)=>z.jsx(R.Fragment,{children:z.jsxs("span",{className:"font-mono",children:[".",r]})},i))]}),z.jsx(mo,{input:n.value,shouldTruncateText:!0,Wrapper:te.Fragment})]}):z.jsx(yc,{data:e,shouldExpandNodeInitially:(r,i,o)=>o<4,theme:{scheme:"grayscale",base00:"transparent",base01:"#252525",base02:"#464646",base03:"#525252",base04:"#ababab",base05:"#b9b9b9",base06:"#e3e3e3",base07:"#f7f7f7",base08:"#7c7c7c",base09:"#999999",base0A:"#a0a0a0",base0B:"#8e8e8e",base0C:"#868686",base0D:"#686868",base0E:"#747474",base0F:"#5e5e5e"}})},tb=({file:e})=>{const t=e.path.split(".").pop();return["png","jpg","jpeg","gif","svg","webp"].includes(t)?z.jsx("img",{src:Yt(e.path),alt:"Evalite file",className:"max-h-32"}):["mp4","webm","ogg"].includes(t)?z.jsx("video",{controls:!0,children:z.jsx("source",{src:Yt(e.path),type:`video/${t}`})}):["mp3","wav","ogg"].includes(t)?z.jsx("audio",{controls:!0,children:z.jsx("source",{src:Yt(e.path),type:`audio/${t}`})}):z.jsx(Ti,{asChild:!0,className:"uppercase",variant:"secondary",size:"sm",children:z.jsxs("a",{href:Ao(e.path),children:[z.jsx(Do,{className:"size-4"}),z.jsxs("span",{children:[".",t]})]})})},eg=e=>{const t=e.Wrapper||te.Fragment;return typeof e.input=="string"||typeof e.input=="number"?z.jsx(mo,{Wrapper:t,input:e.input.toString(),className:e.className,shouldTruncateText:e.shouldTruncateText}):Po.isEvaliteFile(e.input)?z.jsx(t,{className:e.className,children:z.jsx(tb,{file:e.input})}):typeof e.input=="object"&&e.input!==null?z.jsx(t,{className:e.className,children:z.jsx(eb,{input:e.input,name:e.name})}):z.jsx(t,{className:e.className,children:z.jsx("pre",{children:JSON.stringify(e.input,null,2)})})},nb=te.forwardRef(({...e},t)=>z.jsx("nav",{ref:t,"aria-label":"breadcrumb",...e}));nb.displayName="Breadcrumb";const rb=te.forwardRef(({className:e,...t},n)=>z.jsx("ol",{ref:n,className:Wt("flex flex-wrap items-center gap-1.5 break-words text-sm text-muted-foreground sm:gap-2.5",e),...t}));rb.displayName="BreadcrumbList";const ib=te.forwardRef(({className:e,...t},n)=>z.jsx("li",{ref:n,className:Wt("inline-flex items-center gap-1.5",e),...t}));ib.displayName="BreadcrumbItem";const ab=te.forwardRef(({asChild:e,className:t,...n},r)=>{const i=e?Io:"a";return z.jsx(i,{ref:r,className:Wt("transition-colors hover:text-foreground",t),...n})});ab.displayName="BreadcrumbLink";const ob=te.forwardRef(({className:e,...t},n)=>z.jsx("span",{ref:n,role:"link","aria-disabled":"true","aria-current":"page",className:Wt("font-normal text-foreground",e),...t}));ob.displayName="BreadcrumbPage";const At=43200,Ai=1440,Ii=Symbol.for("constructDateFrom");function bo(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&Ii in e?e[Ii](t):e instanceof Date?new e.constructor(t):new Date(t)}function _e(e,t){return bo(e,e)}let lb={};function sb(){return lb}function Fi(e){const t=_e(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function tr(e,...t){const n=bo.bind(null,e||t.find(r=>typeof r=="object"));return t.map(n)}function Dt(e,t){const n=+_e(e)-+_e(t);return n<0?-1:n>0?1:n}function ub(e,t,n){const[r,i]=tr(n==null?void 0:n.in,e,t),o=r.getFullYear()-i.getFullYear(),a=r.getMonth()-i.getMonth();return o*12+a}function cb(e){return t=>{const r=(e?Math[e]:Math.trunc)(t);return r===0?0:r}}function fb(e,t){return+_e(e)-+_e(t)}function hb(e,t){const n=_e(e);return n.setHours(23,59,59,999),n}function pb(e,t){const n=_e(e),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function db(e,t){const n=_e(e);return+hb(n)==+pb(n)}function mb(e,t,n){const[r,i,o]=tr(n==null?void 0:n.in,e,e,t),a=Dt(i,o),l=Math.abs(ub(i,o));if(l<1)return 0;i.getMonth()===1&&i.getDate()>27&&i.setDate(30),i.setMonth(i.getMonth()-a*l);let s=Dt(i,o)===-a;db(r)&&l===1&&Dt(r,o)===1&&(s=!1);const u=a*(l-+s);return u===0?0:u}function bb(e,t,n){const r=fb(e,t)/1e3;return cb(n==null?void 0:n.roundingMethod)(r)}const gb={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},yb=(e,t,n)=>{let r;const i=gb[e];return typeof i=="string"?r=i:t===1?r=i.one:r=i.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function yn(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const xb={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},kb={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},wb={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},vb={date:yn({formats:xb,defaultWidth:"full"}),time:yn({formats:kb,defaultWidth:"full"}),dateTime:yn({formats:wb,defaultWidth:"full"})},Cb={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},Sb=(e,t,n,r)=>Cb[e];function lt(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,l=n!=null&&n.width?String(n.width):a;i=e.formattingValues[l]||e.formattingValues[a]}else{const a=e.defaultWidth,l=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[l]||e.values[a]}const o=e.argumentCallback?e.argumentCallback(t):t;return i[o]}}const Eb={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},Ab={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},Ib={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Fb={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},Db={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},_b={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},Tb=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},Pb={ordinalNumber:Tb,era:lt({values:Eb,defaultWidth:"wide"}),quarter:lt({values:Ab,defaultWidth:"wide",argumentCallback:e=>e-1}),month:lt({values:Ib,defaultWidth:"wide"}),day:lt({values:Fb,defaultWidth:"wide"}),dayPeriod:lt({values:Db,defaultWidth:"wide",formattingValues:_b,defaultFormattingWidth:"wide"})};function st(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;const a=o[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],s=Array.isArray(l)?Ob(l,c=>c.test(a)):Lb(l,c=>c.test(a));let u;u=e.valueCallback?e.valueCallback(s):s,u=n.valueCallback?n.valueCallback(u):u;const f=t.slice(a.length);return{value:u,rest:f}}}function Lb(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function Ob(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function Mb(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],o=t.match(e.parsePattern);if(!o)return null;let a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;const l=t.slice(i.length);return{value:a,rest:l}}}const Rb=/^(\d+)(th|st|nd|rd)?/i,zb=/\d+/i,Nb={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},Bb={any:[/^b/i,/^(a|c)/i]},jb={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},$b={any:[/1/i,/2/i,/3/i,/4/i]},Wb={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Ub={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Hb={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},qb={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Vb={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Gb={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Yb={ordinalNumber:Mb({matchPattern:Rb,parsePattern:zb,valueCallback:e=>parseInt(e,10)}),era:st({matchPatterns:Nb,defaultMatchWidth:"wide",parsePatterns:Bb,defaultParseWidth:"any"}),quarter:st({matchPatterns:jb,defaultMatchWidth:"wide",parsePatterns:$b,defaultParseWidth:"any",valueCallback:e=>e+1}),month:st({matchPatterns:Wb,defaultMatchWidth:"wide",parsePatterns:Ub,defaultParseWidth:"any"}),day:st({matchPatterns:Hb,defaultMatchWidth:"wide",parsePatterns:qb,defaultParseWidth:"any"}),dayPeriod:st({matchPatterns:Vb,defaultMatchWidth:"any",parsePatterns:Gb,defaultParseWidth:"any"})},Xb={code:"en-US",formatDistance:yb,formatLong:vb,formatRelative:Sb,localize:Pb,match:Yb,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Jb(e,t,n){const r=sb(),i=(n==null?void 0:n.locale)??r.locale??Xb,o=2520,a=Dt(e,t);if(isNaN(a))throw new RangeError("Invalid time value");const l=Object.assign({},n,{addSuffix:n==null?void 0:n.addSuffix,comparison:a}),[s,u]=tr(n==null?void 0:n.in,...a>0?[t,e]:[e,t]),f=bb(u,s),c=(Fi(u)-Fi(s))/1e3,p=Math.round((f-c)/60);let h;if(p<2)return n!=null&&n.includeSeconds?f<5?i.formatDistance("lessThanXSeconds",5,l):f<10?i.formatDistance("lessThanXSeconds",10,l):f<20?i.formatDistance("lessThanXSeconds",20,l):f<40?i.formatDistance("halfAMinute",0,l):f<60?i.formatDistance("lessThanXMinutes",1,l):i.formatDistance("xMinutes",1,l):p===0?i.formatDistance("lessThanXMinutes",1,l):i.formatDistance("xMinutes",p,l);if(p<45)return i.formatDistance("xMinutes",p,l);if(p<90)return i.formatDistance("aboutXHours",1,l);if(p<Ai){const d=Math.round(p/60);return i.formatDistance("aboutXHours",d,l)}else{if(p<o)return i.formatDistance("xDays",1,l);if(p<At){const d=Math.round(p/Ai);return i.formatDistance("xDays",d,l)}else if(p<At*2)return h=Math.round(p/At),i.formatDistance("aboutXMonths",h,l)}if(h=mb(u,s),h<12){const d=Math.round(p/At);return i.formatDistance("xMonths",d,l)}else{const d=h%12,g=Math.trunc(h/12);return d<3?i.formatDistance("aboutXYears",g,l):d<9?i.formatDistance("overXYears",g,l):i.formatDistance("almostXYears",g+1,l)}}const Kb=6e4,tg=e=>{const[,t]=te.useState(new Date);te.useEffect(()=>{const r=setInterval(()=>{t(new Date)},Kb);return()=>clearInterval(r)},[]);const n=new Date(e.date+"Z");return z.jsx("span",{className:e.className,children:Jb(n,new Date,{addSuffix:!0})})},ng=e=>e<1e3?`${e}ms`:`${(e/1e3).toFixed(1)}s`,rg=e=>!Array.isArray(e)||e.length===0?!1:e.every(t=>typeof t=="object"&&t!==null&&typeof t.label=="string"&&t.value!==void 0);export{nb as B,eg as D,tg as L,rb as a,ib as b,ab as c,Zb as d,ng as f,rg as i,_o as s};