@kubitnodes/stellaris 0.3.22 → 0.3.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/README.md +4 -4
  2. package/dist/cli/index.js +556 -413
  3. package/dist/server/index.js +666 -473
  4. package/package.json +1 -1
  5. package/web/dist/assets/BackLink-DGYs80bb.js +1 -0
  6. package/web/dist/assets/{Button-Yoe21NQ2.js → Button-f4jgBZY1.js} +1 -1
  7. package/web/dist/assets/{ChannelForms-55otlg-m.js → ChannelForms-q9zdj4p2.js} +1 -1
  8. package/web/dist/assets/{ChannelView-DJvLzg0N.js → ChannelView-CGs_aWL3.js} +2 -2
  9. package/web/dist/assets/{CitizenView-m1K2aTvK.js → CitizenView-gcIo_sKt.js} +2 -2
  10. package/web/dist/assets/CitizensView-DZ7S8vnJ.js +1 -0
  11. package/web/dist/assets/{CliIcon-DbMYJdlU.js → CliIcon-CLHaA65A.js} +1 -1
  12. package/web/dist/assets/{CronsView-B4kXk5Ld.js → CronsView-1wns6Uwv.js} +1 -1
  13. package/web/dist/assets/{KnowledgeView-aSGxDDKy.js → KnowledgeView-Cxfi2-Pt.js} +1 -1
  14. package/web/dist/assets/Markdown-BhtIFcWc.js +30 -0
  15. package/web/dist/assets/MessageItem-Bk9eBp1U.js +1 -0
  16. package/web/dist/assets/MetricsView-CTEH6rJn.js +1 -0
  17. package/web/dist/assets/NeedsYouView-2VNqH2Sb.js +1 -0
  18. package/web/dist/assets/{Overview-BveU1yJj.js → Overview-CS9HCSmm.js} +1 -1
  19. package/web/dist/assets/{Pane-CLjdfBMM.js → Pane-CJYRVkwh.js} +1 -1
  20. package/web/dist/assets/{Picker-CXOe5Xdu.js → Picker-DoxCN6C7.js} +1 -1
  21. package/web/dist/assets/{ProjectView-oa4Z46ED.js → ProjectView-CJ3r4UdN.js} +1 -1
  22. package/web/dist/assets/ProposalView-DLn9dNPp.js +2 -0
  23. package/web/dist/assets/{ProposalsView-BZHivSEm.js → ProposalsView-B-cOxTsQ.js} +1 -1
  24. package/web/dist/assets/{Quota-BC7dpnwd.js → Quota-Bo7UdWTV.js} +1 -1
  25. package/web/dist/assets/{RunnersView-BrJF-aLU.js → RunnersView-DlQruhwp.js} +1 -1
  26. package/web/dist/assets/{SocietyView-C1yosPuf.js → SocietyView-Bl4ErnV8.js} +1 -1
  27. package/web/dist/assets/{StickyList-7tAlUDCN.js → StickyList-MVP34ytV.js} +1 -1
  28. package/web/dist/assets/{SubjectThread-CCq6ZAnR.js → SubjectThread-BFFnHxIF.js} +1 -1
  29. package/web/dist/assets/{TaskFileView-BEXQJQQ6.js → TaskFileView-GZ0eQFUb.js} +2 -2
  30. package/web/dist/assets/{TaskView-Cfhb7NuO.js → TaskView-DppFelLW.js} +2 -2
  31. package/web/dist/assets/{TasksView-3XljXcoi.js → TasksView-DDNXzeG4.js} +1 -1
  32. package/web/dist/assets/{ThreadForms-D2y5dXSC.js → ThreadForms-C846TvtS.js} +1 -1
  33. package/web/dist/assets/{ThreadItem-DeIhhmyu.js → ThreadItem-C8cou6wD.js} +1 -1
  34. package/web/dist/assets/{ThreadView-CbUnt9WL.js → ThreadView-DvSGDYoD.js} +1 -1
  35. package/web/dist/assets/{citizen--bqux6i_.js → citizen-B2Dlbcpe.js} +1 -1
  36. package/web/dist/assets/{compose-DNc3_c5x.js → compose-BmqQmcZH.js} +1 -1
  37. package/web/dist/assets/{format-B6fjC0_a.js → format-DT52SbbR.js} +1 -1
  38. package/web/dist/assets/{governance-RBQ4Lam0.js → governance-Cr5OlQnw.js} +1 -1
  39. package/web/dist/assets/index-BTVy_xFF.js +23 -0
  40. package/web/dist/assets/index-DzV6CCnG.css +2 -0
  41. package/web/dist/assets/{mentions-B2Qchd_6.js → mentions-D5hNgtg6.js} +1 -1
  42. package/web/dist/assets/{tasks-DCUj5w_d.js → tasks-R3YgpYTe.js} +1 -1
  43. package/web/dist/assets/useMatch-pEF6RJ6Q.js +1 -0
  44. package/web/dist/index.html +9 -9
  45. package/web/dist/assets/BackLink-CD-iuy-h.js +0 -1
  46. package/web/dist/assets/CitizensView-BeTgmrKE.js +0 -1
  47. package/web/dist/assets/Markdown-c9bCCLHg.js +0 -30
  48. package/web/dist/assets/MessageItem-DKJKMqs-.js +0 -1
  49. package/web/dist/assets/MetricsView-D2TTry5O.js +0 -1
  50. package/web/dist/assets/NeedsYouView-C3celRei.js +0 -1
  51. package/web/dist/assets/ProposalView-B4T-EoX9.js +0 -2
  52. package/web/dist/assets/index-CyCty7a2.js +0 -23
  53. package/web/dist/assets/index-GRqxKN35.css +0 -2
  54. package/web/dist/assets/useMatch-CfbBQirn.js +0 -1
@@ -1,30 +0,0 @@
1
- import{Bn as e,Hn as t,L as n,Un as r,Vn as i,Wt as a,zn as o}from"./format-B6fjC0_a.js";import{b as s,g as c,x as l,y as u}from"./index-CyCty7a2.js";import{a as d,c as f,d as p,i as m,l as h,o as g,r as _,s as v,t as y,u as b}from"./mentions-B2Qchd_6.js";function ee(e,t){let 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 x(e){let t=[],n=-1,r=0,i=0;for(;++n<e.length;){let a=e.charCodeAt(n),o=``;if(a===37&&v(e.charCodeAt(n+1))&&v(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(o=String.fromCharCode(a));else if(a>55295&&a<57344){let t=e.charCodeAt(n+1);a<56320&&t>56319&&t<57344?(o=String.fromCharCode(a,t),i=1):o=`�`}else o=String.fromCharCode(a);o&&=(t.push(e.slice(r,n),encodeURIComponent(o)),r=n+i+1,``),i&&=(n+=i,0)}return t.join(``)+e.slice(r)}function te(e,t){let n=t||{};return(e[e.length-1]===``?[...e,``]:e).join((n.padRight?` `:``)+`,`+(n.padLeft===!1?``:` `)).trim()}var ne=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,re=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,ie={};function ae(e,t){return((t||ie).jsx?re:ne).test(e)}var S=/[ \t\n\f\r]/g;function C(e){return typeof e==`object`?e.type===`text`&&oe(e.value):oe(e)}function oe(e){return e.replace(S,``)===``}var w=class{constructor(e,t,n){this.normal=t,this.property=e,n&&(this.space=n)}};w.prototype.normal={},w.prototype.property={},w.prototype.space=void 0;function se(e,t){let n={},r={};for(let t of e)Object.assign(n,t.property),Object.assign(r,t.normal);return new w(n,r,t)}function T(e){return e.toLowerCase()}var E=class{constructor(e,t){this.attribute=t,this.property=e}};E.prototype.attribute=``,E.prototype.booleanish=!1,E.prototype.boolean=!1,E.prototype.commaOrSpaceSeparated=!1,E.prototype.commaSeparated=!1,E.prototype.defined=!1,E.prototype.mustUseProperty=!1,E.prototype.number=!1,E.prototype.overloadedBoolean=!1,E.prototype.property=``,E.prototype.spaceSeparated=!1,E.prototype.space=void 0;var ce=t({boolean:()=>D,booleanish:()=>O,commaOrSpaceSeparated:()=>N,commaSeparated:()=>M,number:()=>A,overloadedBoolean:()=>k,spaceSeparated:()=>j}),le=0,D=P(),O=P(),k=P(),A=P(),j=P(),M=P(),N=P();function P(){return 2**++le}var F=Object.keys(ce),I=class extends E{constructor(e,t,n,r){let i=-1;if(super(e,t),ue(this,`space`,r),typeof n==`number`)for(;++i<F.length;){let e=F[i];ue(this,F[i],(n&ce[e])===ce[e])}}};I.prototype.defined=!0;function ue(e,t,n){n&&(e[t]=n)}function L(e){let t={},n={};for(let[r,i]of Object.entries(e.properties)){let a=new I(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[T(r)]=r,n[T(a.attribute)]=r}return new w(t,n,e.space)}var de=L({properties:{ariaActiveDescendant:null,ariaAtomic:O,ariaAutoComplete:null,ariaBusy:O,ariaChecked:O,ariaColCount:A,ariaColIndex:A,ariaColSpan:A,ariaControls:j,ariaCurrent:null,ariaDescribedBy:j,ariaDetails:null,ariaDisabled:O,ariaDropEffect:j,ariaErrorMessage:null,ariaExpanded:O,ariaFlowTo:j,ariaGrabbed:O,ariaHasPopup:null,ariaHidden:O,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:j,ariaLevel:A,ariaLive:null,ariaModal:O,ariaMultiLine:O,ariaMultiSelectable:O,ariaOrientation:null,ariaOwns:j,ariaPlaceholder:null,ariaPosInSet:A,ariaPressed:O,ariaReadOnly:O,ariaRelevant:null,ariaRequired:O,ariaRoleDescription:j,ariaRowCount:A,ariaRowIndex:A,ariaRowSpan:A,ariaSelected:O,ariaSetSize:A,ariaSort:null,ariaValueMax:A,ariaValueMin:A,ariaValueNow:A,ariaValueText:null,role:null},transform(e,t){return t===`role`?t:`aria-`+t.slice(4).toLowerCase()}});function fe(e,t){return t in e?e[t]:t}function pe(e,t){return fe(e,t.toLowerCase())}var me=L({attributes:{acceptcharset:`accept-charset`,classname:`class`,htmlfor:`for`,httpequiv:`http-equiv`},mustUseProperty:[`checked`,`multiple`,`muted`,`selected`],properties:{abbr:null,accept:M,acceptCharset:j,accessKey:j,action:null,allow:null,allowFullScreen:D,allowPaymentRequest:D,allowUserMedia:D,alpha:D,alt:null,as:null,async:D,autoCapitalize:null,autoComplete:j,autoFocus:D,autoPlay:D,blocking:j,capture:null,charSet:null,checked:D,cite:null,className:j,closedBy:null,colorSpace:null,cols:A,colSpan:A,command:null,commandFor:null,content:null,contentEditable:O,controls:D,controlsList:j,coords:A|M,crossOrigin:null,data:null,dateTime:null,decoding:null,default:D,defer:D,dir:null,dirName:null,disabled:D,download:k,draggable:O,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:D,formTarget:null,headers:j,height:A,hidden:k,high:A,href:null,hrefLang:null,htmlFor:j,httpEquiv:j,id:null,imageSizes:null,imageSrcSet:null,inert:D,inputMode:null,integrity:null,is:null,isMap:D,itemId:null,itemProp:j,itemRef:j,itemScope:D,itemType:j,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:D,low:A,manifest:null,max:null,maxLength:A,media:null,method:null,min:null,minLength:A,multiple:D,muted:D,name:null,nonce:null,noModule:D,noValidate:D,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:D,optimum:A,pattern:null,ping:j,placeholder:null,playsInline:D,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:D,referrerPolicy:null,rel:j,required:D,reversed:D,rows:A,rowSpan:A,sandbox:j,scope:null,scoped:D,seamless:D,selected:D,shadowRootClonable:D,shadowRootCustomElementRegistry:D,shadowRootDelegatesFocus:D,shadowRootMode:null,shadowRootSerializable:D,shape:null,size:A,sizes:null,slot:null,span:A,spellCheck:O,src:null,srcDoc:null,srcLang:null,srcSet:null,start:A,step:null,style:null,tabIndex:A,target:null,title:null,translate:null,type:null,typeMustMatch:D,useMap:null,value:O,width:A,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:j,axis:null,background:null,bgColor:null,border:A,borderColor:null,bottomMargin:A,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:D,declare:D,event:null,face:null,frame:null,frameBorder:null,hSpace:A,leftMargin:A,link:null,longDesc:null,lowSrc:null,marginHeight:A,marginWidth:A,noResize:D,noHref:D,noShade:D,noWrap:D,object:null,profile:null,prompt:null,rev:null,rightMargin:A,rules:null,scheme:null,scrolling:O,standby:null,summary:null,text:null,topMargin:A,valueType:null,version:null,vAlign:null,vLink:null,vSpace:A,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:D,disablePictureInPicture:D,disableRemotePlayback:D,exportParts:M,part:j,prefix:null,property:null,results:A,security:null,unselectable:null},space:`html`,transform:pe}),he=L({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`,maskType:`mask-type`,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`},properties:{about:N,accentHeight:A,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:A,amplitude:A,arabicForm:null,ascent:A,attributeName:null,attributeType:null,azimuth:A,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:A,by:null,calcMode:null,capHeight:A,className:j,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:A,diffuseConstant:A,direction:null,display:null,dur:null,divisor:A,dominantBaseline:null,download:D,dx:null,dy:null,edgeMode:null,editable:null,elevation:A,enableBackground:null,end:null,event:null,exponent:A,externalResourcesRequired:null,fill:null,fillOpacity:A,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:M,g2:M,glyphName:M,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:A,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:A,horizOriginX:A,horizOriginY:A,id:null,ideographic:A,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:A,k:A,k1:A,k2:A,k3:A,k4:A,kernelMatrix:N,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:A,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:A,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:A,overlineThickness:A,paintOrder:null,panose1:null,path:null,pathLength:A,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:j,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:A,pointsAtY:A,pointsAtZ:A,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:N,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:N,rev:N,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:N,requiredFeatures:N,requiredFonts:N,requiredFormats:N,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:A,specularExponent:A,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:A,strikethroughThickness:A,string:null,stroke:null,strokeDashArray:N,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:A,strokeOpacity:A,strokeWidth:null,style:null,surfaceScale:A,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:N,tabIndex:A,tableValues:null,target:null,targetX:A,targetY:A,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:N,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:A,underlineThickness:A,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:A,values:null,vAlphabetic:A,vMathematical:A,vectorEffect:null,vHanging:A,vIdeographic:A,version:null,vertAdvY:A,vertOriginX:A,vertOriginY:A,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:A,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:`svg`,transform:fe}),ge=L({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:`xlink`,transform(e,t){return`xlink:`+t.slice(5).toLowerCase()}}),_e=L({attributes:{xmlnsxlink:`xmlns:xlink`},properties:{xmlnsXLink:null,xmlns:null},space:`xmlns`,transform:pe}),ve=L({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:`xml`,transform(e,t){return`xml:`+t.slice(3).toLowerCase()}}),ye={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`},be=/[A-Z]/g,R=/-[a-z]/g,xe=/^data[-\w.:]+$/i;function Se(e,t){let n=T(t),r=t,i=E;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)===`data`&&xe.test(t)){if(t.charAt(4)===`-`){let e=t.slice(5).replace(R,we);r=`data`+e.charAt(0).toUpperCase()+e.slice(1)}else{let e=t.slice(4);if(!R.test(e)){let n=e.replace(be,Ce);n.charAt(0)!==`-`&&(n=`-`+n),t=`data`+n}}i=I}return new i(r,t)}function Ce(e){return`-`+e.toLowerCase()}function we(e){return e.charAt(1).toUpperCase()}var Te=se([de,me,ge,_e,ve],`html`),Ee=se([de,he,ge,_e,ve],`svg`);function De(e){return e.join(` `).trim()}var Oe=i(((e,t)=>{var n=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,r=/\n/g,i=/^\s*/,a=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,o=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,c=/^[;\s]*/,l=/^\s+|\s+$/g;function u(e,t){if(typeof e!=`string`)throw TypeError(`First argument must be a string`);if(!e)return[];t||={};var l=1,u=1;function f(e){var t=e.match(r);t&&(l+=t.length);var n=e.lastIndexOf(`
2
- `);u=~n?e.length-n:u+e.length}function p(){var e={line:l,column:u};return function(t){return t.position=new m(e),_(),t}}function m(e){this.start=e,this.end={line:l,column:u},this.source=t.source}m.prototype.content=e;function h(n){var r=Error(t.source+`:`+l+`:`+u+`: `+n);if(r.reason=n,r.filename=t.source,r.line=l,r.column=u,r.source=e,!t.silent)throw r}function g(t){var n=t.exec(e);if(n){var r=n[0];return f(r),e=e.slice(r.length),n}}function _(){g(i)}function v(e){var t;for(e||=[];t=y();)t!==!1&&e.push(t);return e}function y(){var t=p();if(e.charAt(0)==`/`&&e.charAt(1)==`*`){for(var n=2;e.charAt(n)!=``&&(e.charAt(n)!=`*`||e.charAt(n+1)!=`/`);)++n;if(n+=2,e.charAt(n-1)===``)return h(`End of comment missing`);var r=e.slice(2,n-2);return u+=2,f(r),e=e.slice(n),u+=2,t({type:`comment`,comment:r})}}function b(){var e=p(),t=g(a);if(t){if(y(),!g(o))return h(`property missing ':'`);var r=g(s),i=e({type:`declaration`,property:d(t[0].replace(n,``)),value:r?d(r[0].replace(n,``)):``});return g(c),i}}function ee(){var e=[];v(e);for(var t;t=b();)t!==!1&&(e.push(t),v(e));return e}return _(),ee()}function d(e){return e?e.replace(l,``):``}t.exports=u})),ke=i((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;var n=t(Oe());function r(e,t){let r=null;if(!e||typeof e!=`string`)return r;let i=(0,n.default)(e),a=typeof t==`function`;return i.forEach(e=>{if(e.type!==`declaration`)return;let{property:n,value:i}=e;a?t(n,i,e):i&&(r||={},r[n]=i)}),r}})),Ae=i((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.camelCase=void 0;var t=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,r=/^[^-]+$/,i=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,o=function(e){return!e||r.test(e)||t.test(e)},s=function(e,t){return t.toUpperCase()},c=function(e,t){return`${t}-`};e.camelCase=function(e,t){return t===void 0&&(t={}),o(e)?e:(e=e.toLowerCase(),e=t.reactCompat?e.replace(a,c):e.replace(i,c),e.replace(n,s))}})),je=i(((e,t)=>{var n=(e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(ke()),r=Ae();function i(e,t){var i={};return!e||typeof e!=`string`||(0,n.default)(e,function(e,n){e&&n&&(i[(0,r.camelCase)(e,t)]=n)}),i}i.default=i,t.exports=i})),Me=Pe(`end`),Ne=Pe(`start`);function Pe(e){return t;function t(t){let n=t&&t.position&&t.position[e]||{};if(typeof n.line==`number`&&n.line>0&&typeof n.column==`number`&&n.column>0)return{line:n.line,column:n.column,offset:typeof n.offset==`number`&&n.offset>-1?n.offset:void 0}}}function Fe(e){let t=Ne(e),n=Me(e);if(t&&n)return{start:t,end:n}}function z(e){return!e||typeof e!=`object`?``:`position`in e||`type`in e?Le(e.position):`start`in e||`end`in e?Le(e):`line`in e||`column`in e?Ie(e):``}function Ie(e){return Re(e&&e.line)+`:`+Re(e&&e.column)}function Le(e){return Ie(e&&e.start)+`-`+Ie(e&&e.end)}function Re(e){return e&&typeof e==`number`?e:1}var B=class extends Error{constructor(e,t,n){super(),typeof t==`string`&&(n=t,t=void 0);let r=``,i={},a=!1;if(t&&(i=`line`in t&&`column`in t||`start`in t&&`end`in t?{place:t}:`type`in t?{ancestors:[t],place:t.position}:{...t}),typeof e==`string`?r=e:!i.cause&&e&&(a=!0,r=e.message,i.cause=e),!i.ruleId&&!i.source&&typeof n==`string`){let e=n.indexOf(`:`);e===-1?i.ruleId=n:(i.source=n.slice(0,e),i.ruleId=n.slice(e+1))}if(!i.place&&i.ancestors&&i.ancestors){let e=i.ancestors[i.ancestors.length-1];e&&(i.place=e.position)}let o=i.place&&`start`in i.place?i.place.start:i.place;this.ancestors=i.ancestors||void 0,this.cause=i.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file=``,this.message=r,this.line=o?o.line:void 0,this.name=z(i.place)||`1:1`,this.place=i.place||void 0,this.reason=this.message,this.ruleId=i.ruleId||void 0,this.source=i.source||void 0,this.stack=a&&i.cause&&typeof i.cause.stack==`string`?i.cause.stack:``,this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}};B.prototype.file=``,B.prototype.name=``,B.prototype.reason=``,B.prototype.message=``,B.prototype.stack=``,B.prototype.column=void 0,B.prototype.line=void 0,B.prototype.ancestors=void 0,B.prototype.cause=void 0,B.prototype.fatal=void 0,B.prototype.place=void 0,B.prototype.ruleId=void 0,B.prototype.source=void 0;var ze=r(je(),1),Be={}.hasOwnProperty,Ve=new Map,He=/[A-Z]/g,Ue=new Set([`table`,`tbody`,`thead`,`tfoot`,`tr`]),We=new Set([`td`,`th`]),Ge=`https://github.com/syntax-tree/hast-util-to-jsx-runtime`;function Ke(e,t){if(!t||t.Fragment===void 0)throw TypeError("Expected `Fragment` in options");let n=t.filePath||void 0,r;if(t.development){if(typeof t.jsxDEV!=`function`)throw TypeError("Expected `jsxDEV` in options when `development: true`");r=rt(n,t.jsxDEV)}else{if(typeof t.jsx!=`function`)throw TypeError("Expected `jsx` in production options");if(typeof t.jsxs!=`function`)throw TypeError("Expected `jsxs` in production options");r=nt(n,t.jsx,t.jsxs)}let 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`?Ee:Te,stylePropertyNameCase:t.stylePropertyNameCase||`dom`,tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=qe(i,e,void 0);return a&&typeof a!=`string`?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function qe(e,t,n){if(t.type===`element`)return Je(e,t,n);if(t.type===`mdxFlowExpression`||t.type===`mdxTextExpression`)return Ye(e,t);if(t.type===`mdxJsxFlowElement`||t.type===`mdxJsxTextElement`)return Ze(e,t,n);if(t.type===`mdxjsEsm`)return Xe(e,t);if(t.type===`root`)return Qe(e,t,n);if(t.type===`text`)return $e(e,t)}function Je(e,t,n){let r=e.schema,i=r;t.tagName.toLowerCase()===`svg`&&r.space===`html`&&(i=Ee,e.schema=i),e.ancestors.push(t);let a=lt(e,t.tagName,!1),o=it(e,t),s=ot(e,t);return Ue.has(t.tagName)&&(s=s.filter(function(e){return typeof e!=`string`||!C(e)})),et(e,o,a,t),tt(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function Ye(e,t){if(t.data&&t.data.estree&&e.evaluater){let n=t.data.estree.body[0];return n.type,e.evaluater.evaluateExpression(n.expression)}V(e,t.position)}function Xe(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);V(e,t.position)}function Ze(e,t,n){let r=e.schema,i=r;t.name===`svg`&&r.space===`html`&&(i=Ee,e.schema=i),e.ancestors.push(t);let a=t.name===null?e.Fragment:lt(e,t.name,!0),o=at(e,t),s=ot(e,t);return et(e,o,a,t),tt(o,s),e.ancestors.pop(),e.schema=r,e.create(t,a,o,n)}function Qe(e,t,n){let r={};return tt(r,ot(e,t)),e.create(t,e.Fragment,r,n)}function $e(e,t){return t.value}function et(e,t,n,r){typeof n!=`string`&&n!==e.Fragment&&e.passNode&&(t.node=r)}function tt(e,t){if(t.length>0){let n=t.length>1?t:t[0];n&&(e.children=n)}}function nt(e,t,n){return r;function r(e,r,i,a){let o=Array.isArray(i.children)?n:t;return a?o(r,i,a):o(r,i)}}function rt(e,t){return n;function n(n,r,i,a){let o=Array.isArray(i.children),s=Ne(n);return t(r,i,a,o,{columnNumber:s?s.column-1:void 0,fileName:e,lineNumber:s?s.line:void 0},void 0)}}function it(e,t){let n={},r,i;for(i in t.properties)if(i!==`children`&&Be.call(t.properties,i)){let a=st(e,i,t.properties[i]);if(a){let[i,o]=a;e.tableCellAlignToStyle&&i===`align`&&typeof o==`string`&&We.has(t.tagName)?r=o:n[i]=o}}if(r){let t=n.style||={};t[e.stylePropertyNameCase===`css`?`text-align`:`textAlign`]=r}return n}function at(e,t){let n={};for(let r of t.attributes)if(r.type===`mdxJsxExpressionAttribute`){if(r.data&&r.data.estree&&e.evaluater){let t=r.data.estree.body[0];t.type;let i=t.expression;i.type;let a=i.properties[0];a.type,Object.assign(n,e.evaluater.evaluateExpression(a.argument))}else V(e,t.position)}else{let i=r.name,a;if(r.value&&typeof r.value==`object`){if(r.value.data&&r.value.data.estree&&e.evaluater){let t=r.value.data.estree.body[0];t.type,a=e.evaluater.evaluateExpression(t.expression)}else V(e,t.position)}else a=r.value===null||r.value;n[i]=a}return n}function ot(e,t){let n=[],r=-1,i=e.passKeys?new Map:Ve;for(;++r<t.children.length;){let a=t.children[r],o;if(e.passKeys){let e=a.type===`element`?a.tagName:a.type===`mdxJsxFlowElement`||a.type===`mdxJsxTextElement`?a.name:void 0;if(e){let t=i.get(e)||0;o=e+`-`+t,i.set(e,t+1)}}let s=qe(e,a,o);s!==void 0&&n.push(s)}return n}function st(e,t,n){let r=Se(e.schema,t);if(!(n==null||typeof n==`number`&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?te(n):De(n)),r.property===`style`){let t=typeof n==`object`?n:ct(e,String(n));return e.stylePropertyNameCase===`css`&&(t=ut(t)),[`style`,t]}return[e.elementAttributeNameCase===`react`&&r.space?ye[r.property]||r.property:r.attribute,n]}}function ct(e,t){try{return(0,ze.default)(t,{reactCompat:!0})}catch(t){if(e.ignoreInvalidStyle)return{};let n=t,r=new B("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:n,ruleId:`style`,source:`hast-util-to-jsx-runtime`});throw r.file=e.filePath||void 0,r.url=Ge+`#cannot-parse-style-attribute`,r}}function lt(e,t,n){let r;if(!n)r={type:`Literal`,value:t};else if(t.includes(`.`)){let e=t.split(`.`),n=-1,i;for(;++n<e.length;){let t=ae(e[n])?{type:`Identifier`,name:e[n]}:{type:`Literal`,value:e[n]};i=i?{type:`MemberExpression`,object:i,property:t,computed:!!(n&&t.type===`Literal`),optional:!1}:t}r=i}else r=ae(t)&&!/^[a-z]/.test(t)?{type:`Identifier`,name:t}:{type:`Literal`,value:t};if(r.type===`Literal`){let t=r.value;return Be.call(e.components,t)?e.components[t]:t}if(e.evaluater)return e.evaluater.evaluateExpression(r);V(e)}function V(e,t){let n=new B("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=Ge+`#cannot-handle-mdx-estrees-without-createevaluater`,n}function ut(e){let t={},n;for(n in e)Be.call(e,n)&&(t[dt(n)]=e[n]);return t}function dt(e){let t=e.replace(He,ft);return t.slice(0,3)===`ms-`&&(t=`-`+t),t}function ft(e){return`-`+e.toLowerCase()}var pt={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`]},mt={};function ht(e,t){let n=t||mt;return gt(e,typeof n.includeImageAlt!=`boolean`||n.includeImageAlt,typeof n.includeHtml!=`boolean`||n.includeHtml)}function gt(e,t,n){if(vt(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 _t(e.children,t,n)}return Array.isArray(e)?_t(e,t,n):``}function _t(e,t,n){let r=[],i=-1;for(;++i<e.length;)r[i]=gt(e[i],t,n);return r.join(``)}function vt(e){return!!(e&&typeof e==`object`)}var yt=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function bt(e){return e.replace(yt,xt)}function xt(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){let e=n.charCodeAt(1),t=e===120||e===88;return ee(n.slice(t?2:1),t?16:10)}return p(n)||e}var St={}.hasOwnProperty;function Ct(e,t,n){return t&&typeof t==`object`&&(n=t,t=void 0),wt(n)(d(g(n).document().write(m()(e,t,!0))))}function wt(e){let t={transforms:[],canContainEols:[`emphasis`,`fragment`,`heading`,`paragraph`,`strong`],enter:{autolink:a(be),autolinkProtocol:S,autolinkEmail:S,atxHeading:a(ge),blockQuote:a(de),characterEscape:S,characterReference:S,codeFenced:a(fe),codeFencedFenceInfo:o,codeFencedFenceMeta:o,codeIndented:a(fe,o),codeText:a(pe,o),codeTextData:S,data:S,codeFlowValue:S,definition:a(me),definitionDestinationString:o,definitionLabelString:o,definitionTitleString:o,emphasis:a(he),hardBreakEscape:a(_e),hardBreakTrailing:a(_e),htmlFlow:a(ve,o),htmlFlowData:S,htmlText:a(ve,o),htmlTextData:S,image:a(ye),label:o,link:a(be),listItem:a(xe),listItemValue:f,listOrdered:a(R,d),listUnordered:a(R),paragraph:a(Se),reference:M,referenceString:o,resourceDestinationString:o,resourceTitleString:o,setextHeading:a(ge),strong:a(Ce),thematicBreak:a(Te)},exit:{atxHeading:c(),atxHeadingSequence:ne,autolink:c(),autolinkEmail:L,autolinkProtocol:ue,blockQuote:c(),characterEscapeValue:C,characterReferenceMarkerHexadecimal:P,characterReferenceMarkerNumeric:P,characterReferenceValue:F,characterReference:I,codeFenced:c(_),codeFencedFence:g,codeFencedFenceInfo:m,codeFencedFenceMeta:h,codeFlowValue:C,codeIndented:c(v),codeText:c(E),codeTextData:C,data:C,definition:c(),definitionDestinationString:te,definitionLabelString:y,definitionTitleString:x,emphasis:c(),hardBreakEscape:c(w),hardBreakTrailing:c(w),htmlFlow:c(se),htmlFlowData:C,htmlText:c(T),htmlTextData:C,image:c(le),label:O,labelText:D,lineEnding:oe,link:c(ce),listItem:c(),listOrdered:c(),listUnordered:c(),paragraph:c(),referenceString:N,resourceDestinationString:k,resourceTitleString:A,resource:j,setextHeading:c(ae),setextHeadingLineSequence:ie,setextHeadingText:re,strong:c(),thematicBreak:c()}};Tt(t,(e||{}).mdastExtensions||[]);let n={};return r;function r(e){let r={type:`root`,children:[]},a={stack:[r],tokenStack:[],config:t,enter:s,exit:l,buffer:o,resume:u,data:n},c=[],d=-1;for(;++d<e.length;)(e[d][1].type===`listOrdered`||e[d][1].type===`listUnordered`)&&(e[d][0]===`enter`?c.push(d):d=i(e,c.pop(),d));for(d=-1;++d<e.length;){let n=t[e[d][0]];St.call(n,e[d][1].type)&&n[e[d][1].type].call(Object.assign({sliceSerialize:e[d][2].sliceSerialize},a),e[d][1])}if(a.tokenStack.length>0){let e=a.tokenStack[a.tokenStack.length-1];(e[1]||Dt).call(a,void 0,e[0])}for(r.position={start:H(e.length>0?e[0][1].start:{line:1,column:1,offset:0}),end:H(e.length>0?e[e.length-2][1].end:{line:1,column:1,offset:0})},d=-1;++d<t.transforms.length;)r=t.transforms[d](r)||r;return r}function i(e,t,n){let r=t-1,i=-1,a=!1,o,s,c,l;for(;++r<=n;){let t=e[r];switch(t[1].type){case`listUnordered`:case`listOrdered`:case`blockQuote`:t[0]===`enter`?i++:i--,l=void 0;break;case`lineEndingBlank`:t[0]===`enter`&&(o&&!l&&!i&&!c&&(c=r),l=void 0);break;case`linePrefix`:case`listItemValue`:case`listItemMarker`:case`listItemPrefix`:case`listItemPrefixWhitespace`:break;default:l=void 0}if(!i&&t[0]===`enter`&&t[1].type===`listItemPrefix`||i===-1&&t[0]===`exit`&&(t[1].type===`listUnordered`||t[1].type===`listOrdered`)){if(o){let i=r;for(s=void 0;i--;){let t=e[i];if(t[1].type===`lineEnding`||t[1].type===`lineEndingBlank`){if(t[0]===`exit`)continue;s&&(e[s][1].type=`lineEndingBlank`,a=!0),t[1].type=`lineEnding`,s=i}else if(t[1].type!==`linePrefix`&&t[1].type!==`blockQuotePrefix`&&t[1].type!==`blockQuotePrefixWhitespace`&&t[1].type!==`blockQuoteMarker`&&t[1].type!==`listItemIndent`)break}c&&(!s||c<s)&&(o._spread=!0),o.end=Object.assign({},s?e[s][1].start:t[1].end),e.splice(s||r,0,[`exit`,o,t[2]]),r++,n++}if(t[1].type===`listItemPrefix`){let i={type:`listItem`,_spread:!1,start:Object.assign({},t[1].start),end:void 0};o=i,e.splice(r,0,[`enter`,i,t[2]]),r++,n++,c=void 0,l=!0}}}return e[t][1]._spread=a,n}function a(e,t){return n;function n(n){s.call(this,e(n),n),t&&t.call(this,n)}}function o(){this.stack.push({type:`fragment`,children:[]})}function s(e,t,n){this.stack[this.stack.length-1].children.push(e),this.stack.push(e),this.tokenStack.push([t,n||void 0]),e.position={start:H(t.start),end:void 0}}function c(e){return t;function t(t){e&&e.call(this,t),l.call(this,t)}}function l(e,t){let n=this.stack.pop(),r=this.tokenStack.pop();if(r)r[0].type!==e.type&&(t?t.call(this,e,r[0]):(r[1]||Dt).call(this,e,r[0]));else throw Error("Cannot close `"+e.type+"` ("+z({start:e.start,end:e.end})+`): it’s not open`);n.position.end=H(e.end)}function u(){return ht(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(e){if(this.data.expectingFirstListItemValue){let t=this.stack[this.stack.length-2];t.start=Number.parseInt(this.sliceSerialize(e),10),this.data.expectingFirstListItemValue=void 0}}function m(){let e=this.resume(),t=this.stack[this.stack.length-1];t.lang=e}function h(){let e=this.resume(),t=this.stack[this.stack.length-1];t.meta=e}function g(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function _(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,``),this.data.flowCodeInside=void 0}function v(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e.replace(/(\r?\n|\r)$/g,``)}function y(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=b(this.sliceSerialize(e)).toLowerCase()}function x(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function te(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function ne(e){let t=this.stack[this.stack.length-1];t.depth||=this.sliceSerialize(e).length}function re(){this.data.setextHeadingSlurpLineEnding=!0}function ie(e){let t=this.stack[this.stack.length-1];t.depth=this.sliceSerialize(e).codePointAt(0)===61?1:2}function ae(){this.data.setextHeadingSlurpLineEnding=void 0}function S(e){let t=this.stack[this.stack.length-1].children,n=t[t.length-1];(!n||n.type!==`text`)&&(n=we(),n.position={start:H(e.start),end:void 0},t.push(n)),this.stack.push(n)}function C(e){let t=this.stack.pop();t.value+=this.sliceSerialize(e),t.position.end=H(e.end)}function oe(e){let n=this.stack[this.stack.length-1];if(this.data.atHardBreak){let t=n.children[n.children.length-1];t.position.end=H(e.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(n.type)&&(S.call(this,e),C.call(this,e))}function w(){this.data.atHardBreak=!0}function se(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function T(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function E(){let e=this.resume(),t=this.stack[this.stack.length-1];t.value=e}function ce(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function le(){let e=this.stack[this.stack.length-1];if(this.data.inReference){let t=this.data.referenceType||`shortcut`;e.type+=`Reference`,e.referenceType=t,delete e.url,delete e.title}else delete e.identifier,delete e.label;this.data.referenceType=void 0}function D(e){let t=this.sliceSerialize(e),n=this.stack[this.stack.length-2];n.label=bt(t),n.identifier=b(t).toLowerCase()}function O(){let e=this.stack[this.stack.length-1],t=this.resume(),n=this.stack[this.stack.length-1];this.data.inReference=!0,n.type===`link`?n.children=e.children:n.alt=t}function k(){let e=this.resume(),t=this.stack[this.stack.length-1];t.url=e}function A(){let e=this.resume(),t=this.stack[this.stack.length-1];t.title=e}function j(){this.data.inReference=void 0}function M(){this.data.referenceType=`collapsed`}function N(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.label=t,n.identifier=b(this.sliceSerialize(e)).toLowerCase(),this.data.referenceType=`full`}function P(e){this.data.characterReferenceType=e.type}function F(e){let t=this.sliceSerialize(e),n=this.data.characterReferenceType,r;n?(r=ee(t,n===`characterReferenceMarkerNumeric`?10:16),this.data.characterReferenceType=void 0):r=p(t);let i=this.stack[this.stack.length-1];i.value+=r}function I(e){let t=this.stack.pop();t.position.end=H(e.end)}function ue(e){C.call(this,e);let t=this.stack[this.stack.length-1];t.url=this.sliceSerialize(e)}function L(e){C.call(this,e);let t=this.stack[this.stack.length-1];t.url=`mailto:`+this.sliceSerialize(e)}function de(){return{type:`blockquote`,children:[]}}function fe(){return{type:`code`,lang:null,meta:null,value:``}}function pe(){return{type:`inlineCode`,value:``}}function me(){return{type:`definition`,identifier:``,label:null,title:null,url:``}}function he(){return{type:`emphasis`,children:[]}}function ge(){return{type:`heading`,depth:0,children:[]}}function _e(){return{type:`break`}}function ve(){return{type:`html`,value:``}}function ye(){return{type:`image`,title:null,url:``,alt:null}}function be(){return{type:`link`,title:null,url:``,children:[]}}function R(e){return{type:`list`,ordered:e.type===`listOrdered`,start:null,spread:e._spread,children:[]}}function xe(e){return{type:`listItem`,spread:e._spread,checked:null,children:[]}}function Se(){return{type:`paragraph`,children:[]}}function Ce(){return{type:`strong`,children:[]}}function we(){return{type:`text`,value:``}}function Te(){return{type:`thematicBreak`}}}function H(e){return{line:e.line,column:e.column,offset:e.offset}}function Tt(e,t){let n=-1;for(;++n<t.length;){let r=t[n];Array.isArray(r)?Tt(e,r):Et(e,r)}}function Et(e,t){let n;for(n in t)if(St.call(t,n))switch(n){case`canContainEols`:{let r=t[n];r&&e[n].push(...r);break}case`transforms`:{let r=t[n];r&&e[n].push(...r);break}case`enter`:case`exit`:{let r=t[n];r&&Object.assign(e[n],r);break}}}function Dt(e,t){throw Error(e?"Cannot close `"+e.type+"` ("+z({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+z({start:t.start,end:t.end})+`) is open`:"Cannot close document, a token (`"+t.type+"`, "+z({start:t.start,end:t.end})+`) is still open`)}function Ot(e){let t=this;t.parser=n;function n(n){return Ct(n,{...t.data(`settings`),...e,extensions:t.data(`micromarkExtensions`)||[],mdastExtensions:t.data(`fromMarkdownExtensions`)||[]})}}function kt(e,t){let n={type:`element`,tagName:`blockquote`,properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function At(e,t){let n={type:`element`,tagName:`br`,properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:`text`,value:`
3
- `}]}function jt(e,t){let n=t.value?t.value+`
4
- `:``,r={},i=t.lang?t.lang.split(/\s+/):[];i.length>0&&(r.className=[`language-`+i[0]]);let a={type:`element`,tagName:`code`,properties:r,children:[{type:`text`,value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:`element`,tagName:`pre`,properties:{},children:[a]},e.patch(t,a),a}function Mt(e,t){let n={type:`element`,tagName:`del`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Nt(e,t){let n={type:`element`,tagName:`em`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Pt(e,t){let n=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,r=String(t.identifier).toUpperCase(),i=x(r.toLowerCase()),a=e.footnoteOrder.indexOf(r),o,s=e.footnoteCounts.get(r);s===void 0?(s=0,e.footnoteOrder.push(r),o=e.footnoteOrder.length):o=a+1,s+=1,e.footnoteCounts.set(r,s);let c={type:`element`,tagName:`a`,properties:{href:`#`+n+`fn-`+i,id:n+`fnref-`+i+(s>1?`-`+s:``),dataFootnoteRef:!0,ariaDescribedBy:[`footnote-label`]},children:[{type:`text`,value:String(o)}]};e.patch(t,c);let l={type:`element`,tagName:`sup`,properties:{},children:[c]};return e.patch(t,l),e.applyData(t,l)}function Ft(e,t){let n={type:`element`,tagName:`h`+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function It(e,t){if(e.options.allowDangerousHtml){let n={type:`raw`,value:t.value};return e.patch(t,n),e.applyData(t,n)}}function Lt(e,t){let n=t.referenceType,r=`]`;if(n===`collapsed`?r+=`[]`:n===`full`&&(r+=`[`+(t.label||t.identifier)+`]`),t.type===`imageReference`)return[{type:`text`,value:`![`+t.alt+r}];let i=e.all(t),a=i[0];a&&a.type===`text`?a.value=`[`+a.value:i.unshift({type:`text`,value:`[`});let o=i[i.length-1];return o&&o.type===`text`?o.value+=r:i.push({type:`text`,value:r}),i}function Rt(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Lt(e,t);let i={src:x(r.url||``),alt:t.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);let a={type:`element`,tagName:`img`,properties:i,children:[]};return e.patch(t,a),e.applyData(t,a)}function zt(e,t){let n={src:x(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);let r={type:`element`,tagName:`img`,properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function Bt(e,t){let n={type:`text`,value:t.value.replace(/\r?\n|\r/g,` `)};e.patch(t,n);let r={type:`element`,tagName:`code`,properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function Vt(e,t){let n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Lt(e,t);let i={href:x(r.url||``)};r.title!==null&&r.title!==void 0&&(i.title=r.title);let a={type:`element`,tagName:`a`,properties:i,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function Ht(e,t){let n={href:x(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);let r={type:`element`,tagName:`a`,properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function Ut(e,t,n){let r=e.all(t),i=n?Wt(n):Gt(t),a={},o=[];if(typeof t.checked==`boolean`){let e=r[0],n;e&&e.type===`element`&&e.tagName===`p`?n=e:(n={type:`element`,tagName:`p`,properties:{},children:[]},r.unshift(n)),n.children.length>0&&n.children.unshift({type:`text`,value:` `}),n.children.unshift({type:`element`,tagName:`input`,properties:{type:`checkbox`,checked:t.checked,disabled:!0},children:[]}),a.className=[`task-list-item`]}let s=-1;for(;++s<r.length;){let e=r[s];(i||s!==0||e.type!==`element`||e.tagName!==`p`)&&o.push({type:`text`,value:`
5
- `}),e.type===`element`&&e.tagName===`p`&&!i?o.push(...e.children):o.push(e)}let c=r[r.length-1];c&&(i||c.type!==`element`||c.tagName!==`p`)&&o.push({type:`text`,value:`
6
- `});let l={type:`element`,tagName:`li`,properties:a,children:o};return e.patch(t,l),e.applyData(t,l)}function Wt(e){let t=!1;if(e.type===`list`){t=e.spread||!1;let n=e.children,r=-1;for(;!t&&++r<n.length;)t=Gt(n[r])}return t}function Gt(e){return e.spread??e.children.length>1}function Kt(e,t){let n={},r=e.all(t),i=-1;for(typeof t.start==`number`&&t.start!==1&&(n.start=t.start);++i<r.length;){let e=r[i];if(e.type===`element`&&e.tagName===`li`&&e.properties&&Array.isArray(e.properties.className)&&e.properties.className.includes(`task-list-item`)){n.className=[`contains-task-list`];break}}let a={type:`element`,tagName:t.ordered?`ol`:`ul`,properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function qt(e,t){let n={type:`element`,tagName:`p`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Jt(e,t){let n={type:`root`,children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function Yt(e,t){let n={type:`element`,tagName:`strong`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function Xt(e,t){let n=e.all(t),r=n.shift(),i=[];if(r){let n={type:`element`,tagName:`thead`,properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],n),i.push(n)}if(n.length>0){let r={type:`element`,tagName:`tbody`,properties:{},children:e.wrap(n,!0)},a=Ne(t.children[1]),o=Me(t.children[t.children.length-1]);a&&o&&(r.position={start:a,end:o}),i.push(r)}let a={type:`element`,tagName:`table`,properties:{},children:e.wrap(i,!0)};return e.patch(t,a),e.applyData(t,a)}function Zt(e,t,n){let r=n?n.children:void 0,i=(r?r.indexOf(t):1)===0?`th`:`td`,a=n&&n.type===`table`?n.align:void 0,o=a?a.length:t.children.length,s=-1,c=[];for(;++s<o;){let n=t.children[s],r={},o=a?a[s]:void 0;o&&(r.align=o);let l={type:`element`,tagName:i,properties:r,children:[]};n&&(l.children=e.all(n),e.patch(n,l),l=e.applyData(n,l)),c.push(l)}let l={type:`element`,tagName:`tr`,properties:{},children:e.wrap(c,!0)};return e.patch(t,l),e.applyData(t,l)}function Qt(e,t){let n={type:`element`,tagName:`td`,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}var $t=9,en=32;function tn(e){let t=String(e),n=/\r?\n|\r/g,r=n.exec(t),i=0,a=[];for(;r;)a.push(nn(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(nn(t.slice(i),i>0,!1)),a.join(``)}function nn(e,t,n){let r=0,i=e.length;if(t){let t=e.codePointAt(r);for(;t===$t||t===en;)r++,t=e.codePointAt(r)}if(n){let t=e.codePointAt(i-1);for(;t===$t||t===en;)i--,t=e.codePointAt(i-1)}return i>r?e.slice(r,i):``}function rn(e,t){let n={type:`text`,value:tn(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function an(e,t){let n={type:`element`,tagName:`hr`,properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}var on={blockquote:kt,break:At,code:jt,delete:Mt,emphasis:Nt,footnoteReference:Pt,heading:Ft,html:It,imageReference:Rt,image:zt,inlineCode:Bt,linkReference:Vt,link:Ht,listItem:Ut,list:Kt,paragraph:qt,root:Jt,strong:Yt,table:Xt,tableCell:Qt,tableRow:Zt,text:rn,thematicBreak:an,toml:U,yaml:U,definition:U,footnoteDefinition:U};function U(){}var{defineProperty:sn}=Object,cn=typeof self==`object`?self:globalThis,ln=(e,t)=>{switch(e){case`Function`:case`SharedWorker`:case`Worker`:case`eval`:case`setInterval`:case`setTimeout`:throw TypeError(`unable to deserialize `+e)}return new cn[e](t)},un=(e,t)=>{let n=(t,n)=>(e.set(n,t),t),r=i=>{if(e.has(i))return e.get(i);let[a,o]=t[i];switch(a){case 0:case-1:return n(o,i);case 1:{let e=n([],i);for(let t of o)e.push(r(t));return e}case 2:{let e=n({},i);for(let[t,n]of o){let i=r(t),a=r(n);i===`__proto__`?sn(e,i,{value:a,configurable:!0,enumerable:!0,writable:!0}):e[i]=a}return e}case 3:return n(new Date(o),i);case 4:{let{source:e,flags:t}=o;return n(new RegExp(e,t),i)}case 5:{let e=n(new Map,i);for(let[t,n]of o)e.set(r(t),r(n));return e}case 6:{let e=n(new Set,i);for(let t of o)e.add(r(t));return e}case 7:{let{name:e,message:t}=o;return n(typeof cn[e]==`function`?ln(e,t):Error(t),i)}case 8:return n(BigInt(o),i);case`BigInt`:return n(Object(BigInt(o)),i);case`ArrayBuffer`:return n(new Uint8Array(o).buffer,o);case`DataView`:{let{buffer:e}=new Uint8Array(o);return n(new DataView(e),o)}case`-0`:return-0}return n(ln(a,o),i)};return r},dn=e=>un(new Map,e)(0),W=``,{toString:fn}={},{keys:pn,is:mn}=Object,G=e=>{let t=typeof e;if(t!==`object`||!e)return[0,t];let n=fn.call(e).slice(8,-1);switch(n){case`Array`:return[1,W];case`Object`:return[2,W];case`Date`:return[3,W];case`RegExp`:return[4,W];case`Map`:return[5,W];case`Set`:return[6,W];case`DataView`:return[1,n]}return n.includes(`Array`)?[1,n]:e instanceof Error?[7,e.name||`Error`]:[2,n]},K=([e,t])=>e===0&&(t===`function`||t===`symbol`),hn=(e,t,n,r)=>{let i=(e,t)=>{let i=r.push(e)-1;return n.set(t,i),i},a=o=>{if(n.has(o))return n.get(o);let[s,c]=G(o);switch(s){case 0:{let t=o;switch(c){case`bigint`:s=8,t=o.toString();break;case`number`:if(!o&&mn(o,-0))return r.push([`-0`])-1;break;case`function`:case`symbol`:if(e)throw TypeError(`unable to serialize `+c);t=null;break;case`undefined`:return i([-1],o)}return i([s,t],o)}case 1:{if(c){let e=o;return c===`DataView`?e=new Uint8Array(o.buffer):c===`ArrayBuffer`&&(e=new Uint8Array(o)),i([c,[...e]],o)}let e=[],t=i([s,e],o);for(let t of o)e.push(a(t));return t}case 2:{if(c)switch(c){case`BigInt`:return i([c,o.toString()],o);case`Boolean`:case`Number`:case`String`:return i([c,o.valueOf()],o)}if(t&&`toJSON`in o)return a(o.toJSON());let n=[],r=i([s,n],o);for(let t of pn(o))(e||!K(G(o[t])))&&n.push([a(t),a(o[t])]);return r}case 3:return i([s,isNaN(o.getTime())?W:o.toISOString()],o);case 4:{let{source:e,flags:t}=o;return i([s,{source:e,flags:t}],o)}case 5:{let t=[],n=i([s,t],o);for(let[n,r]of o)(e||!(K(G(n))||K(G(r))))&&t.push([a(n),a(r)]);return n}case 6:{let t=[],n=i([s,t],o);for(let n of o)(e||!K(G(n)))&&t.push(a(n));return n}}let{message:l}=o;return i([s,{name:c,message:l}],o)};return a},gn=(e,{json:t,lossy:n}={})=>{let r=[];return hn(!(t||n),!!t,new Map,r)(e),r},q=typeof structuredClone==`function`?(e,t)=>t&&(`json`in t||`lossy`in t)?dn(gn(e,t)):structuredClone(e):(e,t)=>dn(gn(e,t));function _n(e,t){let n=[{type:`text`,value:`↩`}];return t>1&&n.push({type:`element`,tagName:`sup`,properties:{},children:[{type:`text`,value:String(t)}]}),n}function vn(e,t){return`Back to reference `+(e+1)+(t>1?`-`+t:``)}function yn(e){let t=typeof e.options.clobberPrefix==`string`?e.options.clobberPrefix:`user-content-`,n=e.options.footnoteBackContent||_n,r=e.options.footnoteBackLabel||vn,i=e.options.footnoteLabel||`Footnotes`,a=e.options.footnoteLabelTagName||`h2`,o=e.options.footnoteLabelProperties||{className:[`sr-only`]},s=[],c=-1;for(;++c<e.footnoteOrder.length;){let i=e.footnoteById.get(e.footnoteOrder[c]);if(!i)continue;let a=e.all(i),o=String(i.identifier).toUpperCase(),l=x(o.toLowerCase()),u=0,d=[],f=e.footnoteCounts.get(o);for(;f!==void 0&&++u<=f;){d.length>0&&d.push({type:`text`,value:` `});let e=typeof n==`string`?n:n(c,u);typeof e==`string`&&(e={type:`text`,value:e}),d.push({type:`element`,tagName:`a`,properties:{href:`#`+t+`fnref-`+l+(u>1?`-`+u:``),dataFootnoteBackref:``,ariaLabel:typeof r==`string`?r:r(c,u),className:[`data-footnote-backref`]},children:Array.isArray(e)?e:[e]})}let p=a[a.length-1];if(p&&p.type===`element`&&p.tagName===`p`){let e=p.children[p.children.length-1];e&&e.type===`text`?e.value+=` `:p.children.push({type:`text`,value:` `}),p.children.push(...d)}else a.push(...d);let m={type:`element`,tagName:`li`,properties:{id:t+`fn-`+l},children:e.wrap(a,!0)};e.patch(i,m),s.push(m)}if(s.length!==0)return{type:`element`,tagName:`section`,properties:{dataFootnotes:!0,className:[`footnotes`]},children:[{type:`element`,tagName:a,properties:{...q(o),id:`footnote-label`},children:[{type:`text`,value:i}]},{type:`text`,value:`
7
- `},{type:`element`,tagName:`ol`,properties:{},children:e.wrap(s,!0)},{type:`text`,value:`
8
- `}]}}var J=(function(e){if(e==null)return Cn;if(typeof e==`function`)return Y(e);if(typeof e==`object`)return Array.isArray(e)?bn(e):xn(e);if(typeof e==`string`)return Sn(e);throw Error(`Expected function, string, or object as test`)});function bn(e){let t=[],n=-1;for(;++n<e.length;)t[n]=J(e[n]);return Y(r);function r(...e){let n=-1;for(;++n<t.length;)if(t[n].apply(this,e))return!0;return!1}}function xn(e){let t=e;return Y(n);function n(n){let r=n,i;for(i in e)if(r[i]!==t[i])return!1;return!0}}function Sn(e){return Y(t);function t(t){return t&&t.type===e}}function Y(e){return t;function t(t,n,r){return!!(wn(t)&&e.call(this,t,typeof n==`number`?n:void 0,r||void 0))}}function Cn(){return!0}function wn(e){return typeof e==`object`&&!!e&&`type`in e}function Tn(e){return e}var En=[];function Dn(e,t,n,r){let i;typeof t==`function`&&typeof n!=`function`?(r=n,n=t):i=t;let a=J(i),o=r?-1:1;s(e,void 0,[])();function s(e,i,c){let l=e&&typeof e==`object`?e:{};if(typeof l.type==`string`){let t=typeof l.tagName==`string`?l.tagName:typeof l.name==`string`?l.name:void 0;Object.defineProperty(u,"name",{value:`node (`+Tn(e.type+(t?`<`+t+`>`:``))+`)`})}return u;function u(){let l=En,u,d,f;if((!t||a(e,i,c[c.length-1]||void 0))&&(l=On(n(e,c)),l[0]===!1))return l;if(`children`in e&&e.children){let t=e;if(t.children&&l[0]!==`skip`)for(d=(r?t.children.length:-1)+o,f=c.concat(t);d>-1&&d<t.children.length;){let e=t.children[d];if(u=s(e,d,f)(),u[0]===!1)return u;d=typeof u[1]==`number`?u[1]:d+o}}return l}}}function On(e){return Array.isArray(e)?e:typeof e==`number`?[!0,e]:e==null?En:[e]}function kn(e,t,n,r){let i,a,o;typeof t==`function`&&typeof n!=`function`?(a=void 0,o=t,i=n):(a=t,o=n,i=r),Dn(e,a,s,i);function s(e,t){let n=t[t.length-1],r=n?n.children.indexOf(e):void 0;return o(e,r,n)}}var An={}.hasOwnProperty,jn={};function Mn(e,t){let n=t||jn,r=new Map,i=new Map,a={all:s,applyData:Pn,definitionById:r,footnoteById:i,footnoteCounts:new Map,footnoteOrder:[],handlers:{...on,...n.handlers},one:o,options:n,patch:Nn,wrap:In};return kn(e,function(e){if(e.type===`definition`||e.type===`footnoteDefinition`){let t=e.type===`definition`?r:i,n=String(e.identifier).toUpperCase();t.has(n)||t.set(n,e)}}),a;function o(e,t){let n=e.type,r=a.handlers[n];if(An.call(a.handlers,n)&&r)return r(a,e,t);if(a.options.passThrough&&a.options.passThrough.includes(n)){if(`children`in e){let{children:t,...n}=e,r=q(n);return r.children=a.all(e),r}return q(e)}return(a.options.unknownHandler||Fn)(a,e,t)}function s(e){let t=[];if(`children`in e){let n=e.children,r=-1;for(;++r<n.length;){let i=a.one(n[r],e);if(i){if(r&&n[r-1].type===`break`&&(!Array.isArray(i)&&i.type===`text`&&(i.value=Ln(i.value)),!Array.isArray(i)&&i.type===`element`)){let e=i.children[0];e&&e.type===`text`&&(e.value=Ln(e.value))}Array.isArray(i)?t.push(...i):t.push(i)}}}return t}}function Nn(e,t){e.position&&(t.position=Fe(e))}function Pn(e,t){let n=t;if(e&&e.data){let t=e.data.hName,r=e.data.hChildren,i=e.data.hProperties;typeof t==`string`&&(n.type===`element`?n.tagName=t:n={type:`element`,tagName:t,properties:{},children:`children`in n?n.children:[n]}),n.type===`element`&&i&&Object.assign(n.properties,q(i)),`children`in n&&n.children&&r!=null&&(n.children=r)}return n}function Fn(e,t){let n=t.data||{},r=`value`in t&&!(An.call(n,`hProperties`)||An.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 In(e,t){let n=[],r=-1;for(t&&n.push({type:`text`,value:`
9
- `});++r<e.length;)r&&n.push({type:`text`,value:`
10
- `}),n.push(e[r]);return t&&e.length>0&&n.push({type:`text`,value:`
11
- `}),n}function Ln(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function Rn(e,t){let n=Mn(e,t),r=n.one(e,void 0),i=yn(n),a=Array.isArray(r)?{type:`root`,children:r}:r||{type:`root`,children:[]};return i&&(`children`in a,a.children.push({type:`text`,value:`
12
- `},i)),a}function zn(e,t){return e&&`run`in e?async function(n,r){let i=Rn(n,{file:r,...t});await e.run(i,r)}:function(n,r){return Rn(n,{file:r,...e||t})}}function Bn(e){if(e)throw e}var Vn=r(i(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,a=Object.getOwnPropertyDescriptor,o=function(e){return typeof Array.isArray==`function`?Array.isArray(e):r.call(e)===`[object Array]`},s=function(e){if(!e||r.call(e)!==`[object Object]`)return!1;var t=n.call(e,`constructor`),i=e.constructor&&e.constructor.prototype&&n.call(e.constructor.prototype,`isPrototypeOf`);if(e.constructor&&!t&&!i)return!1;for(var a in e);return a===void 0||n.call(e,a)},c=function(e,t){i&&t.name===`__proto__`?i(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(e,t){if(t===`__proto__`){if(!n.call(e,t))return;if(a)return a(e,t).value}return e[t]};t.exports=function e(){var t,n,r,i,a,u,d=arguments[0],f=1,p=arguments.length,m=!1;for(typeof d==`boolean`&&(m=d,d=arguments[1]||{},f=2),(d==null||typeof d!=`object`&&typeof d!=`function`)&&(d={});f<p;++f)if(t=arguments[f],t!=null)for(n in t)r=l(d,n),i=l(t,n),d!==i&&(m&&i&&(s(i)||(a=o(i)))?(a?(a=!1,u=r&&o(r)?r:[]):u=r&&s(r)?r:{},c(d,{name:n,newValue:e(m,u,i)})):i!==void 0&&c(d,{name:n,newValue:i}));return d}}))(),1);function Hn(e){if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function Un(){let e=[],t={run:n,use:r};return t;function n(...t){let n=-1,r=t.pop();if(typeof r!=`function`)throw TypeError(`Expected function as last argument, not `+r);i(null,...t);function i(a,...o){let s=e[++n],c=-1;if(a){r(a);return}for(;++c<t.length;)(o[c]===null||o[c]===void 0)&&(o[c]=t[c]);t=o,s?Wn(s,i)(...o):r(null,...o)}}function r(n){if(typeof n!=`function`)throw TypeError("Expected `middelware` to be a function, not "+n);return e.push(n),t}}function Wn(e,t){let n;return r;function r(...t){let r=e.length>t.length,o;r&&t.push(i);try{o=e.apply(this,t)}catch(e){let t=e;if(r&&n)throw t;return i(t)}r||(o&&o.then&&typeof o.then==`function`?o.then(a,i):o instanceof Error?i(o):a(o))}function i(e,...r){n||(n=!0,t(e,...r))}function a(e){i(null,e)}}var X={basename:Gn,dirname:Kn,extname:qn,join:Jn,sep:`/`};function Gn(e,t){if(t!==void 0&&typeof t!=`string`)throw TypeError(`"ext" argument must be a string`);Z(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?``:e.slice(n,r)}if(t===e)return``;let o=-1,s=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else o<0&&(a=!0,o=i+1),s>-1&&(e.codePointAt(i)===t.codePointAt(s--)?s<0&&(r=i):(s=-1,r=o));return n===r?r=o:r<0&&(r=e.length),e.slice(n,r)}function Kn(e){if(Z(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||=!0;return t<0?e.codePointAt(0)===47?`/`:`.`:t===1&&e.codePointAt(0)===47?`//`:e.slice(0,t)}function qn(e){Z(e);let t=e.length,n=-1,r=0,i=-1,a=0,o;for(;t--;){let s=e.codePointAt(t);if(s===47){if(o){r=t+1;break}continue}n<0&&(o=!0,n=t+1),s===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?``:e.slice(i,n)}function Jn(...e){let t=-1,n;for(;++t<e.length;)Z(e[t]),e[t]&&(n=n===void 0?e[t]:n+`/`+e[t]);return n===void 0?`.`:Yn(n)}function Yn(e){Z(e);let t=e.codePointAt(0)===47,n=Xn(e,!t);return n.length===0&&!t&&(n=`.`),n.length>0&&e.codePointAt(e.length-1)===47&&(n+=`/`),t?`/`+n:n}function Xn(e,t){let n=``,r=0,i=-1,a=0,o=-1,s,c;for(;++o<=e.length;){if(o<e.length)s=e.codePointAt(o);else if(s===47)break;else s=47;if(s===47){if(i!==o-1&&a!==1){if(i!==o-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(c=n.lastIndexOf(`/`),c!==n.length-1){c<0?(n=``,r=0):(n=n.slice(0,c),r=n.length-1-n.lastIndexOf(`/`)),i=o,a=0;continue}}else if(n.length>0){n=``,r=0,i=o,a=0;continue}}t&&(n=n.length>0?n+`/..`:`..`,r=2)}else n.length>0?n+=`/`+e.slice(i+1,o):n=e.slice(i+1,o),r=o-i-1}i=o,a=0}else s===46&&a>-1?a++:a=-1}return n}function Z(e){if(typeof e!=`string`)throw TypeError(`Path must be a string. Received `+JSON.stringify(e))}var Zn={cwd:Qn};function Qn(){return`/`}function $n(e){return!!(typeof e==`object`&&e&&`href`in e&&e.href&&`protocol`in e&&e.protocol&&e.auth===void 0)}function er(e){if(typeof e==`string`)e=new URL(e);else if(!$n(e)){let t=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:`){let e=TypeError(`The URL must be of scheme file`);throw e.code=`ERR_INVALID_URL_SCHEME`,e}return tr(e)}function tr(e){if(e.hostname!==``){let e=TypeError(`File URL host must be "localhost" or empty on darwin`);throw e.code=`ERR_INVALID_FILE_URL_HOST`,e}let t=e.pathname,n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){let e=t.codePointAt(n+2);if(e===70||e===102){let e=TypeError(`File URL path must not include encoded / characters`);throw e.code=`ERR_INVALID_FILE_URL_PATH`,e}}return decodeURIComponent(t)}var nr=[`history`,`path`,`basename`,`stem`,`extname`,`dirname`],rr=class{constructor(e){let t;t=e?$n(e)?{path:e}:typeof e==`string`||sr(e)?{value:e}:e:{},this.cwd=`cwd`in t?``:Zn.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let n=-1;for(;++n<nr.length;){let e=nr[n];e in t&&t[e]!==void 0&&t[e]!==null&&(this[e]=e===`history`?[...t[e]]:t[e])}let r;for(r in t)nr.includes(r)||(this[r]=t[r])}get basename(){return typeof this.path==`string`?X.basename(this.path):void 0}set basename(e){ar(e,`basename`),ir(e,`basename`),this.path=X.join(this.dirname||``,e)}get dirname(){return typeof this.path==`string`?X.dirname(this.path):void 0}set dirname(e){or(this.basename,`dirname`),this.path=X.join(e||``,this.basename)}get extname(){return typeof this.path==`string`?X.extname(this.path):void 0}set extname(e){if(ir(e,`extname`),or(this.dirname,`extname`),e){if(e.codePointAt(0)!==46)throw Error("`extname` must start with `.`");if(e.includes(`.`,1))throw Error("`extname` cannot contain multiple dots")}this.path=X.join(this.dirname,this.stem+(e||``))}get path(){return this.history[this.history.length-1]}set path(e){$n(e)&&(e=er(e)),ar(e,`path`),this.path!==e&&this.history.push(e)}get stem(){return typeof this.path==`string`?X.basename(this.path,this.extname):void 0}set stem(e){ar(e,`stem`),ir(e,`stem`),this.path=X.join(this.dirname||``,e+(this.extname||``))}fail(e,t,n){let r=this.message(e,t,n);throw r.fatal=!0,r}info(e,t,n){let r=this.message(e,t,n);return r.fatal=void 0,r}message(e,t,n){let r=new B(e,t,n);return this.path&&(r.name=this.path+`:`+r.name,r.file=this.path),r.fatal=!1,this.messages.push(r),r}toString(e){return this.value===void 0?``:typeof this.value==`string`?this.value:new TextDecoder(e||void 0).decode(this.value)}};function ir(e,t){if(e&&e.includes(X.sep))throw Error("`"+t+"` cannot be a path: did not expect `"+X.sep+"`")}function ar(e,t){if(!e)throw Error("`"+t+"` cannot be empty")}function or(e,t){if(!e)throw Error("Setting `"+t+"` requires `path` to be set too")}function sr(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var cr=(function(e){let t=this.constructor.prototype,n=t[e],r=function(){return n.apply(r,arguments)};return Object.setPrototypeOf(r,t),r}),lr={}.hasOwnProperty,ur=new class e extends cr{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=Un()}copy(){let t=new e,n=-1;for(;++n<this.attachers.length;){let e=this.attachers[n];t.use(...e)}return t.data((0,Vn.default)(!0,{},this.namespace)),t}data(e,t){return typeof e==`string`?arguments.length===2?(pr(`data`,this.frozen),this.namespace[e]=t,this):lr.call(this.namespace,e)&&this.namespace[e]||void 0:e?(pr(`data`,this.frozen),this.namespace=e,this):this.namespace}freeze(){if(this.frozen)return this;let e=this;for(;++this.freezeIndex<this.attachers.length;){let[t,...n]=this.attachers[this.freezeIndex];if(n[0]===!1)continue;n[0]===!0&&(n[0]=void 0);let r=t.call(e,...n);typeof r==`function`&&this.transformers.use(r)}return this.frozen=!0,this.freezeIndex=1/0,this}parse(e){this.freeze();let t=gr(e),n=this.parser||this.Parser;return dr(`parse`,n),n(String(t),t)}process(e,t){let n=this;return this.freeze(),dr(`process`,this.parser||this.Parser),fr(`process`,this.compiler||this.Compiler),t?r(void 0,t):new Promise(r);function r(r,i){let a=gr(e),o=n.parse(a);n.run(o,a,function(e,t,r){if(e||!t||!r)return s(e);let i=t,a=n.stringify(i,r);vr(a)?r.value=a:r.result=a,s(e,r)});function s(e,n){e||!n?i(e):r?r(n):t(void 0,n)}}}processSync(e){let t=!1,n;return this.freeze(),dr(`processSync`,this.parser||this.Parser),fr(`processSync`,this.compiler||this.Compiler),this.process(e,r),hr(`processSync`,`process`,t),n;function r(e,r){t=!0,Bn(e),n=r}}run(e,t,n){mr(e),this.freeze();let r=this.transformers;return!n&&typeof t==`function`&&(n=t,t=void 0),n?i(void 0,n):new Promise(i);function i(i,a){let o=gr(t);r.run(e,o,s);function s(t,r,o){let s=r||e;t?a(t):i?i(s):n(void 0,s,o)}}}runSync(e,t){let n=!1,r;return this.run(e,t,i),hr(`runSync`,`run`,n),r;function i(e,t){Bn(e),r=t,n=!0}}stringify(e,t){this.freeze();let n=gr(t),r=this.compiler||this.Compiler;return fr(`stringify`,r),mr(e),r(e,n)}use(e,...t){let n=this.attachers,r=this.namespace;if(pr(`use`,this.frozen),e!=null){if(typeof e==`function`)s(e,t);else if(typeof e==`object`)Array.isArray(e)?o(e):a(e);else throw TypeError("Expected usable value, not `"+e+"`")}return this;function i(e){if(typeof e==`function`)s(e,[]);else if(typeof e==`object`){if(Array.isArray(e)){let[t,...n]=e;s(t,n)}else a(e)}else throw TypeError("Expected usable value, not `"+e+"`")}function a(e){if(!(`plugins`in e)&&!(`settings`in e))throw 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");o(e.plugins),e.settings&&(r.settings=(0,Vn.default)(!0,r.settings,e.settings))}function o(e){let t=-1;if(e!=null){if(Array.isArray(e))for(;++t<e.length;){let n=e[t];i(n)}else throw TypeError("Expected a list of plugins, not `"+e+"`")}}function s(e,t){let r=-1,i=-1;for(;++r<n.length;)if(n[r][0]===e){i=r;break}if(i===-1)n.push([e,...t]);else if(t.length>0){let[r,...a]=t,o=n[i][1];Hn(o)&&Hn(r)&&(r=(0,Vn.default)(!0,o,r)),n[i]=[e,r,...a]}}}}().freeze();function dr(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `parser`")}function fr(e,t){if(typeof t!=`function`)throw TypeError("Cannot `"+e+"` without `compiler`")}function pr(e,t){if(t)throw Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function mr(e){if(!Hn(e)||typeof e.type!=`string`)throw TypeError("Expected node, got `"+e+"`")}function hr(e,t,n){if(!n)throw Error("`"+e+"` finished async. Use `"+t+"` instead")}function gr(e){return _r(e)?e:new rr(e)}function _r(e){return!!(e&&typeof e==`object`&&`message`in e&&`messages`in e)}function vr(e){return typeof e==`string`||yr(e)}function yr(e){return!!(e&&typeof e==`object`&&`byteLength`in e&&`byteOffset`in e)}var Q=o(),$=r(e(),1),br=[],xr={allowDangerousHtml:!0},Sr=/^(https?|ircs?|mailto|xmpp)$/i,Cr=[{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:`className`,id:`remove-classname`},{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 wr(e){let t=Tr(e),n=Er(e);return Dr(t.runSync(t.parse(n),n),e)}function Tr(e){let t=e.rehypePlugins||br,n=e.remarkPlugins||br,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...xr}:xr;return ur().use(Ot).use(n).use(zn,r).use(t)}function Er(e){let t=e.children||``,n=new rr;return typeof t==`string`?n.value=t:``+t,n}function Dr(e,t){let n=t.allowedElements,r=t.allowElement,i=t.components,a=t.disallowedElements,o=t.skipHtml,s=t.unwrapDisallowed,c=t.urlTransform||Or;for(let e of Cr)Object.hasOwn(t,e.from)&&``+e.from+(e.to?"use `"+e.to+"` instead":`remove it`)+e.id;return kn(e,l),Ke(e,{Fragment:Q.Fragment,components:i,ignoreInvalidStyle:!0,jsx:Q.jsx,jsxs:Q.jsxs,passKeys:!0,passNode:!0});function l(e,t,i){if(e.type===`raw`&&i&&typeof t==`number`)return o?i.children.splice(t,1):i.children[t]={type:`text`,value:e.value},t;if(e.type===`element`){let t;for(t in pt)if(Object.hasOwn(pt,t)&&Object.hasOwn(e.properties,t)){let n=e.properties[t],r=pt[t];(r===null||r.includes(e.tagName))&&(e.properties[t]=c(String(n||``),t,e))}}if(e.type===`element`){let o=n?!n.includes(e.tagName):a?a.includes(e.tagName):!1;if(!o&&r&&typeof t==`number`&&(o=!r(e,t,i)),o&&i&&typeof t==`number`)return s&&e.children?i.children.splice(t,1,...e.children):i.children.splice(t,1),t}}}function Or(e){let t=e.indexOf(`:`),n=e.indexOf(`?`),r=e.indexOf(`#`),i=e.indexOf(`/`);return t===-1||i!==-1&&t>i||n!==-1&&t>n||r!==-1&&t>r||Sr.test(e.slice(0,t))?e:``}function kr(e,t){let n=String(e);if(typeof t!=`string`)throw TypeError(`Expected character`);let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}function Ar(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replace(/[|\\{}()[\]^$+*?.]/g,`\\$&`).replace(/-/g,`\\x2d`)}function jr(e,t,n){let r=J((n||{}).ignore||[]),i=Mr(t),a=-1;for(;++a<i.length;)Dn(e,`text`,o);function o(e,t){let n=-1,i;for(;++n<t.length;){let e=t[n],a=i?i.children:void 0;if(r(e,a?a.indexOf(e):void 0,i))return;i=e}if(i)return s(e,t)}function s(e,t){let n=t[t.length-1],r=i[a][0],o=i[a][1],s=0,c=n.children.indexOf(e),l=!1,u=[];r.lastIndex=0;let d=r.exec(e.value);for(;d;){let n=d.index,i={index:d.index,input:d.input,stack:[...t,e]},a=o(...d,i);if(typeof a==`string`&&(a=a.length>0?{type:`text`,value:a}:void 0),a===!1?r.lastIndex=n+1:(s!==n&&u.push({type:`text`,value:e.value.slice(s,n)}),Array.isArray(a)?u.push(...a):a&&u.push(a),s=n+d[0].length,l=!0),!r.global)break;d=r.exec(e.value)}return l?(s<e.value.length&&u.push({type:`text`,value:e.value.slice(s)}),n.children.splice(c,1,...u)):u=[e],c+u.length}}function Mr(e){let t=[];if(!Array.isArray(e))throw TypeError(`Expected find and replace tuple or list of tuples`);let n=!e[0]||Array.isArray(e[0])?e:[e],r=-1;for(;++r<n.length;){let e=n[r];t.push([Nr(e[0]),Pr(e[1])])}return t}function Nr(e){return typeof e==`string`?new RegExp(Ar(e),`g`):e}function Pr(e){return typeof e==`function`?e:function(){return e}}var Fr=`phrasing`,Ir=[`autolink`,`link`,`image`,`label`];function Lr(){return{transforms:[Gr],enter:{literalAutolink:zr,literalAutolinkEmail:Br,literalAutolinkHttp:Br,literalAutolinkWww:Br},exit:{literalAutolink:Wr,literalAutolinkEmail:Ur,literalAutolinkHttp:Vr,literalAutolinkWww:Hr}}}function Rr(){return{unsafe:[{character:`@`,before:`[+\\-.\\w]`,after:`[\\-.\\w]`,inConstruct:Fr,notInConstruct:Ir},{character:`.`,before:`[Ww]`,after:`[\\-.\\w]`,inConstruct:Fr,notInConstruct:Ir},{character:`:`,before:`[ps]`,after:`\\/`,inConstruct:Fr,notInConstruct:Ir}]}}function zr(e){this.enter({type:`link`,title:null,url:``,children:[]},e)}function Br(e){this.config.enter.autolinkProtocol.call(this,e)}function Vr(e){this.config.exit.autolinkProtocol.call(this,e)}function Hr(e){this.config.exit.data.call(this,e);let t=this.stack[this.stack.length-1];t.type,t.url=`http://`+this.sliceSerialize(e)}function Ur(e){this.config.exit.autolinkEmail.call(this,e)}function Wr(e){this.exit(e)}function Gr(e){jr(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Kr],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,qr]],{ignore:[`link`,`linkReference`]})}function Kr(e,t,n,r,i){let a=``;if(!Xr(i)||(/^w/i.test(t)&&(n=t+n,t=``,a=`http://`),!Jr(n)))return!1;let o=Yr(n+r);if(!o[0])return!1;let s={type:`link`,title:null,url:a+t+o[0],children:[{type:`text`,value:t+o[0]}]};return o[1]?[s,{type:`text`,value:o[1]}]:s}function qr(e,t,n,r){return!Xr(r,!0)||/[-\d_]$/.test(n)?!1:{type:`link`,title:null,url:`mailto:`+t+`@`+n,children:[{type:`text`,value:t+`@`+n}]}}function Jr(e){let 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 Yr(e){let t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(`)`),i=kr(e,`(`),a=kr(e,`)`);for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(`)`),a++;return[e,n]}function Xr(e,t){let n=e.input.charCodeAt(e.index-1);return(e.index===0||h(n)||f(n))&&(!t||n!==47)}oi.peek=ai;function Zr(){this.buffer()}function Qr(e){this.enter({type:`footnoteReference`,identifier:``,label:``},e)}function $r(){this.buffer()}function ei(e){this.enter({type:`footnoteDefinition`,identifier:``,label:``,children:[]},e)}function ti(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=b(this.sliceSerialize(e)).toLowerCase(),n.label=t}function ni(e){this.exit(e)}function ri(e){let t=this.resume(),n=this.stack[this.stack.length-1];n.type,n.identifier=b(this.sliceSerialize(e)).toLowerCase(),n.label=t}function ii(e){this.exit(e)}function ai(){return`[`}function oi(e,t,n,r){let i=n.createTracker(r),a=i.move(`[^`),o=n.enter(`footnoteReference`),s=n.enter(`reference`);return a+=i.move(n.safe(n.associationId(e),{after:`]`,before:a})),s(),o(),a+=i.move(`]`),a}function si(){return{enter:{gfmFootnoteCallString:Zr,gfmFootnoteCall:Qr,gfmFootnoteDefinitionLabelString:$r,gfmFootnoteDefinition:ei},exit:{gfmFootnoteCallString:ti,gfmFootnoteCall:ni,gfmFootnoteDefinitionLabelString:ri,gfmFootnoteDefinition:ii}}}function ci(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:oi},unsafe:[{character:`[`,inConstruct:[`label`,`phrasing`,`reference`]}]};function n(e,n,r,i){let a=r.createTracker(i),o=a.move(`[^`),s=r.enter(`footnoteDefinition`),c=r.enter(`label`);return o+=a.move(r.safe(r.associationId(e),{before:o,after:`]`})),c(),o+=a.move(`]:`),e.children&&e.children.length>0&&(a.shift(4),o+=a.move((t?`
13
- `:` `)+r.indentLines(r.containerFlow(e,a.current()),t?ui:li))),s(),o}}function li(e,t,n){return t===0?e:ui(e,t,n)}function ui(e,t,n){return(n?``:` `)+e}var di=[`autolink`,`destinationLiteral`,`destinationRaw`,`reference`,`titleQuote`,`titleApostrophe`];gi.attention=_i,gi.peek=vi;function fi(){return{canContainEols:[`delete`],enter:{strikethrough:mi},exit:{strikethrough:hi}}}function pi(){return{handlers:{delete:gi},unsafe:[{character:`~`,inConstruct:`phrasing`,notInConstruct:di}]}}function mi(e){this.enter({type:`delete`,children:[],position:void 0},e)}function hi(e){this.exit(e)}function gi(e,t,n,r){let i=n.createTracker(r),a=n.stack.includes(`strikethrough`)?`~`:`~~`,o=n.enter(`strikethrough`),s=i.move(a);return s+=n.containerPhrasing(e,{...i.current(),before:s,after:`~`}),s+=i.move(a),o(),s}function _i(){return{construct:`strikethrough`,markers:[`~`],sizes:[2,1]}}function vi(){return`~`}function yi(e){return e.length}function bi(e,t){let n=t||{},r=(n.align||[]).concat(),i=n.stringLength||yi,a=[],o=[],s=[],c=[],l=0,u=-1;for(;++u<e.length;){let t=[],r=[],a=-1;for(e[u].length>l&&(l=e[u].length);++a<e[u].length;){let o=xi(e[u][a]);if(n.alignDelimiters!==!1){let e=i(o);r[a]=e,(c[a]===void 0||e>c[a])&&(c[a]=e)}t.push(o)}o[u]=t,s[u]=r}let d=-1;if(typeof r==`object`&&`length`in r)for(;++d<l;)a[d]=Si(r[d]);else{let e=Si(r);for(;++d<l;)a[d]=e}d=-1;let f=[],p=[];for(;++d<l;){let e=a[d],t=``,r=``;e===99?(t=`:`,r=`:`):e===108?t=`:`:e===114&&(r=`:`);let i=n.alignDelimiters===!1?1:Math.max(1,c[d]-t.length-r.length),o=t+`-`.repeat(i)+r;n.alignDelimiters!==!1&&(i=t.length+i+r.length,i>c[d]&&(c[d]=i),p[d]=i),f[d]=o}o.splice(1,0,f),s.splice(1,0,p),u=-1;let m=[];for(;++u<o.length;){let e=o[u],t=s[u];d=-1;let r=[];for(;++d<l;){let i=e[d]||``,o=``,s=``;if(n.alignDelimiters!==!1){let e=c[d]-(t[d]||0),n=a[d];n===114?o=` `.repeat(e):n===99?e%2?(o=` `.repeat(e/2+.5),s=` `.repeat(e/2-.5)):(o=` `.repeat(e/2),s=o):s=` `.repeat(e)}n.delimiterStart!==!1&&!d&&r.push(`|`),n.padding!==!1&&(n.alignDelimiters!==!1||i!==``)&&(n.delimiterStart!==!1||d)&&r.push(` `),n.alignDelimiters!==!1&&r.push(o),r.push(i),n.alignDelimiters!==!1&&r.push(s),n.padding!==!1&&r.push(` `),(n.delimiterEnd!==!1||d!==l-1)&&r.push(`|`)}m.push(n.delimiterEnd===!1?r.join(``).replace(/ +$/,``):r.join(``))}return m.join(`
14
- `)}function xi(e){return e==null?``:String(e)}function Si(e){let 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}var Ci=J([`break`,`delete`,`emphasis`,`footnote`,`footnoteReference`,`image`,`imageReference`,`inlineCode`,`inlineMath`,`link`,`linkReference`,`mdxJsxTextElement`,`mdxTextExpression`,`strong`,`text`,`textDirective`]);function wi(e,t,n,r){let i=n.enter(`blockquote`),a=n.createTracker(r);a.move(`> `),a.shift(2);let o=n.indentLines(n.containerFlow(e,a.current()),Ti);return i(),o}function Ti(e,t,n){return`>`+(n?``:` `)+e}function Ei(e,t){return Di(e,t.inConstruct,!0)&&!Di(e,t.notInConstruct,!1)}function Di(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 Oi(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;){let e=n.unsafe[i];if(e.character===`
15
- `&&!e.before&&!e.after&&Ei(n.stack,e))return/[\t ]/.test(r.before)?``:` `}return`\\
16
- `}function ki(e,t){let n=String(e),r=n.indexOf(t),i=r,a=0,o=0;if(typeof t!=`string`)throw TypeError(`Expected substring`);for(;r!==-1;)r===i?++a>o&&(o=a):a=1,i=r+t.length,r=n.indexOf(t,i);return o}function Ai(e,t){return!(t.options.fences!==!1||!e.value||e.lang||!/[^\n\r ]/.test(e.value)||/^[\t ]*(?:[\n\r]|$)|(?:^|[\n\r])[\t ]*$/.test(e.value))}function ji(e){let t=e.options.fence||"`";if(t!=="`"&&t!==`~`)throw Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function Mi(e,t,n,r){let i=ji(n),a=e.value||``;if(Ai(e,n)){let e=n.enter(`codeIndented`),t=n.indentLines(a,Ni);return e(),t}let o=n.createTracker(r),s=i.repeat(Math.max(ki(a,i)+1,3)),c=n.enter(`codeFenced`),l=i==="`"?`GraveAccent`:`Tilde`,u=o.move(s);if(e.lang){let t=n.enter(`codeFencedLang${l}`);u+=o.move(n.safe(e.lang,{before:u,after:` `,encode:["`"],...o.current()})),t()}if(e.lang&&e.meta){let t=n.enter(`codeFencedMeta${l}`);u+=o.move(` `),u+=o.move(n.safe(e.meta,{before:u,after:`
17
- `,encode:["`"],...o.current()})),t()}return u+=o.move(`
18
- `),a&&(u+=o.move(a+`
19
- `)),u+=o.move(s),c(),u}function Ni(e,t,n){return(n?``:` `)+e}function Pi(e){let t=e.options.quote||`"`;if(t!==`"`&&t!==`'`)throw Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function Fi(e,t,n,r){let i=Pi(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.enter(`definition`),s=n.enter(`label`),c=n.createTracker(r),l=c.move(`[`);return l+=c.move(n.safe(n.associationId(e),{before:l,after:`]`,...c.current()})),l+=c.move(`]: `),s(),!e.url||/[\0- \u007F]/.test(e.url)?(s=n.enter(`destinationLiteral`),l+=c.move(`<`),l+=c.move(n.safe(e.url,{before:l,after:`>`,...c.current()})),l+=c.move(`>`)):(s=n.enter(`destinationRaw`),l+=c.move(n.safe(e.url,{before:l,after:e.title?` `:`
20
- `,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),o(),l}function Ii(e){let t=e.options.emphasis||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}Li.attention=Ri,Li.peek=zi;function Li(e,t,n,r){let i=n.enter(`phrasing`),a=n.containerPhrasing({type:`root`,children:[e]},r);return i(),a}function Ri(e,t){return{construct:`emphasis`,markers:Ii(t)===`*`?[`*`,`_`]:[`_`,`*`],sizes:[1]}}function zi(e,t,n){return n.options.emphasis||`*`}function Bi(e){return`&#x`+e.toString(16).toUpperCase()+`;`}function Vi(e,t){let n=!1;return kn(e,function(e){if(`value`in e&&/\r?\n|\r/.test(e.value)||e.type===`break`)return n=!0,!1}),!!((!e.depth||e.depth<3)&&ht(e)&&(t.options.setext||n))}function Hi(e,t,n,r){let i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(Vi(e,n)){let t=n.enter(`headingSetext`),r=n.enter(`phrasing`),o=n.containerPhrasing(e,{...a.current(),before:`
21
- `,after:`
22
- `});return r(),t(),o+`
23
- `+(i===1?`=`:`-`).repeat(o.length-(Math.max(o.lastIndexOf(`\r`),o.lastIndexOf(`
24
- `))+1))}let o=`#`.repeat(i),s=n.enter(`headingAtx`),c=n.enter(`phrasing`);a.move(o+` `);let l=n.containerPhrasing(e,{before:`# `,after:`
25
- `,...a.current()}),u=l.charCodeAt(0);return(u===9||u===32)&&(l=Bi(u)+l.slice(1)),l=l?o+` `+l:o,n.options.closeAtx&&(l+=` `+o),c(),s(),l}Ui.peek=Wi;function Ui(e){return e.value||``}function Wi(){return`<`}Gi.peek=Ki;function Gi(e,t,n,r){let i=Pi(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.enter(`image`),s=n.enter(`label`),c=n.createTracker(r),l=c.move(`![`);return l+=c.move(n.safe(e.alt,{before:l,after:`]`,...c.current()})),l+=c.move(`](`),s(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(s=n.enter(`destinationLiteral`),l+=c.move(`<`),l+=c.move(n.safe(e.url,{before:l,after:`>`,...c.current()})),l+=c.move(`>`)):(s=n.enter(`destinationRaw`),l+=c.move(n.safe(e.url,{before:l,after:e.title?` `:`)`,...c.current()}))),s(),e.title&&(s=n.enter(`title${a}`),l+=c.move(` `+i),l+=c.move(n.safe(e.title,{before:l,after:i,...c.current()})),l+=c.move(i),s()),l+=c.move(`)`),o(),l}function Ki(){return`!`}qi.peek=Ji;function qi(e,t,n,r){let i=e.referenceType,a=n.enter(`imageReference`),o=n.enter(`label`),s=n.createTracker(r),c=s.move(`![`),l=n.safe(e.alt,{before:c,after:`]`,...s.current()});c+=s.move(l+`][`),o();let u=n.stack;n.stack=u.filter(function(e){return e!==`phrasing`}),o=n.enter(`reference`);let d=n.safe(n.associationId(e),{before:c,after:`]`,...s.current()});return o(),n.stack=u,a(),i===`full`||!l||l!==d?c+=s.move(d+`]`):i===`shortcut`?c=c.slice(0,-1):c+=s.move(`]`),c}function Ji(){return`!`}Yi.peek=Xi;function Yi(e,t,n){let r=e.value||``,i="`",a=-1;for(;RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^\n\r ]/.test(r)&&(/^[\n\r ]/.test(r)&&/[\n\r ]$/.test(r)||/^`|`$/.test(r))&&(r=` `+r+` `);++a<n.unsafe.length;){let e=n.unsafe[a],t=n.compilePattern(e);if(!e.atBreak)continue;let i;for(;i=t.exec(r);){let e=i.index;r.charCodeAt(e)===10&&r.charCodeAt(e-1)===13&&e--,r=r.slice(0,e)+` `+r.slice(i.index+1)}}return i+r+i}function Xi(){return"`"}function Zi(e,t){let n=ht(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))}Qi.peek=$i;function Qi(e,t,n,r){let i=Pi(n),a=i===`"`?`Quote`:`Apostrophe`,o=n.createTracker(r);if(Zi(e,n)){let t=n.stack;n.stack=t.filter(function(e){return e!==`phrasing`});let r=n.enter(`autolink`),i=o.move(`<`);return i+=o.move(n.containerPhrasing(e,{before:i,after:`>`,...o.current()})),i+=o.move(`>`),r(),n.stack=t,i}let s=n.enter(`link`),c=n.enter(`label`),l=o.move(`[`);return l+=o.move(n.containerPhrasing(e,{before:l,after:`](`,...o.current()})),l+=o.move(`](`),c(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(c=n.enter(`destinationLiteral`),l+=o.move(`<`),l+=o.move(n.safe(e.url,{before:l,after:`>`,...o.current()})),l+=o.move(`>`)):(c=n.enter(`destinationRaw`),l+=o.move(n.safe(e.url,{before:l,after:e.title?` `:`)`,...o.current()}))),c(),e.title&&(c=n.enter(`title${a}`),l+=o.move(` `+i),l+=o.move(n.safe(e.title,{before:l,after:i,...o.current()})),l+=o.move(i),c()),l+=o.move(`)`),s(),l}function $i(e,t,n){return Zi(e,n)?`<`:`[`}ea.peek=ta;function ea(e,t,n,r){let i=e.referenceType,a=n.enter(`linkReference`),o=n.enter(`label`),s=n.createTracker(r),c=s.move(`[`),l=n.containerPhrasing(e,{before:c,after:`]`,...s.current()});c+=s.move(l+`][`),o();let u=n.stack;n.stack=u.filter(function(e){return e!==`phrasing`}),o=n.enter(`reference`);let d=n.safe(n.associationId(e),{before:c,after:`]`,...s.current()});return o(),n.stack=u,a(),i===`full`||!l||l!==d?c+=s.move(d+`]`):i===`shortcut`?c=c.slice(0,-1):c+=s.move(`]`),c}function ta(){return`[`}function na(e){let t=e.options.bullet||`*`;if(t!==`*`&&t!==`+`&&t!==`-`)throw Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function ra(e){let t=na(e),n=e.options.bulletOther;if(!n)return t===`*`?`-`:`*`;if(n!==`*`&&n!==`+`&&n!==`-`)throw Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function ia(e){let t=e.options.bulletOrdered||`.`;if(t!==`.`&&t!==`)`)throw Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function aa(e){let t=e.options.rule||`*`;if(t!==`*`&&t!==`-`&&t!==`_`)throw Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function oa(e,t,n,r){let i=n.enter(`list`),a=n.bulletCurrent,o=e.ordered?ia(n):na(n),s=e.ordered?o===`.`?`)`:`.`:ra(n),c=t&&n.bulletLastUsed?o===n.bulletLastUsed:!1;if(!e.ordered){let t=e.children?e.children[0]:void 0;if((o===`*`||o===`-`)&&t&&(!t.children||!t.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&&(c=!0),aa(n)===o&&t){let t=-1;for(;++t<e.children.length;){let n=e.children[t];if(n&&n.type===`listItem`&&n.children&&n.children[0]&&n.children[0].type===`thematicBreak`){c=!0;break}}}}c&&(o=s),n.bulletCurrent=o;let l=n.containerFlow(e,r);return n.bulletLastUsed=o,n.bulletCurrent=a,i(),l}function sa(e){let t=e.options.listItemIndent||`one`;if(t!==`tab`&&t!==`one`&&t!==`mixed`)throw Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function ca(e,t,n,r){let i=sa(n),a=n.bulletCurrent||na(n);t&&t.type===`list`&&t.ordered&&(a=(typeof t.start==`number`&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let o=a.length+1;(i===`tab`||i===`mixed`&&(t&&t.type===`list`&&t.spread||e.spread))&&(o=Math.ceil(o/4)*4);let s=n.createTracker(r);s.move(a+` `.repeat(o-a.length)),s.shift(o);let c=n.enter(`listItem`),l=n.indentLines(n.containerFlow(e,s.current()),u);return c(),l;function u(e,t,n){return t?(n?``:` `.repeat(o))+e:(n?a:a+` `.repeat(o-a.length))+e}}function la(e,t,n,r){let i=n.enter(`paragraph`),a=n.enter(`phrasing`),o=n.containerPhrasing(e,r);return a(),i(),o}function ua(e,t,n,r){if(!e.children.some(function(e){return Ci(e)}))return n.containerFlow(e,r);let i=n.enter(`phrasing`),a=n.containerPhrasing(e,r);return i(),a}function da(e){let t=e.options.strong||`*`;if(t!==`*`&&t!==`_`)throw Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}fa.attention=pa,fa.peek=ma;function fa(e,t,n,r){let i=n.enter(`phrasing`),a=n.containerPhrasing({type:`root`,children:[e]},r);return i(),a}function pa(e,t){return{construct:`strong`,markers:da(t)===`*`?[`*`,`_`]:[`_`,`*`],sizes:[2]}}function ma(e,t,n){return n.options.strong||`*`}function ha(e,t,n,r){return n.safe(e.value,r)}function ga(e){let t=e.options.ruleRepetition||3;if(t<3)throw Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function _a(e,t,n){let r=(aa(n)+(n.options.ruleSpaces?` `:``)).repeat(ga(n));return n.options.ruleSpaces?r.slice(0,-1):r}var va={blockquote:wi,break:Oi,code:Mi,definition:Fi,emphasis:Li,hardBreak:Oi,heading:Hi,html:Ui,image:Gi,imageReference:qi,inlineCode:Yi,link:Qi,linkReference:ea,list:oa,listItem:ca,paragraph:la,root:ua,strong:fa,text:ha,thematicBreak:_a};function ya(){return{enter:{table:ba,tableData:wa,tableHeader:wa,tableRow:Sa},exit:{codeText:Ta,table:xa,tableData:Ca,tableHeader:Ca,tableRow:Ca}}}function ba(e){let t=e._align;this.enter({type:`table`,align:t.map(function(e){return e===`none`?null:e}),children:[]},e),this.data.inTable=!0}function xa(e){this.exit(e),this.data.inTable=void 0}function Sa(e){this.enter({type:`tableRow`,children:[]},e)}function Ca(e){this.exit(e)}function wa(e){this.enter({type:`tableCell`,children:[]},e)}function Ta(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,Ea));let n=this.stack[this.stack.length-1];n.type,n.value=t,this.exit(e)}function Ea(e,t){return t===`|`?t:e}function Da(e){let t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?` `:`|`;return{unsafe:[{character:`\r`,inConstruct:`tableCell`},{character:`
26
- `,inConstruct:`tableCell`},{atBreak:!0,character:`|`,after:`[ :-]`},{character:`|`,inConstruct:`tableCell`},{atBreak:!0,character:`:`,after:`-`},{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{inlineCode:f,table:o,tableCell:c,tableRow:s}};function o(e,t,n,r){return l(u(e,n,r),e.align)}function s(e,t,n,r){let i=l([d(e,n,r)]);return i.slice(0,i.indexOf(`
27
- `))}function c(e,t,n,r){let i=n.enter(`tableCell`),o=n.enter(`phrasing`),s=n.containerPhrasing(e,{...r,before:a,after:a});return o(),i(),s}function l(e,t){return bi(e,{align:t,alignDelimiters:r,padding:n,stringLength:i})}function u(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`table`);for(;++i<r.length;)a[i]=d(r[i],t,n);return o(),a}function d(e,t,n){let r=e.children,i=-1,a=[],o=t.enter(`tableRow`);for(;++i<r.length;)a[i]=c(r[i],e,t,n);return o(),a}function f(e,t,n){let r=va.inlineCode(e,t,n);return n.stack.includes(`tableCell`)&&(r=r.replace(/\|/g,`\\$&`)),r}}function Oa(){return{exit:{taskListCheckValueChecked:Aa,taskListCheckValueUnchecked:Aa,paragraph:ja}}}function ka(){return{unsafe:[{atBreak:!0,character:`-`,after:`[:|-]`}],handlers:{listItem:Ma}}}function Aa(e){let t=this.stack[this.stack.length-2];t.type,t.checked=e.type===`taskListCheckValueChecked`}function ja(e){let t=this.stack[this.stack.length-2];if(t&&t.type===`listItem`&&typeof t.checked==`boolean`){let e=this.stack[this.stack.length-1];e.type;let n=e.children[0];if(n&&n.type===`text`){let r=t.children,i=-1,a;for(;++i<r.length;){let e=r[i];if(e.type===`paragraph`){a=e;break}}a===e&&(n.value=n.value.slice(1),n.value.length===0?e.children.shift():e.position&&n.position&&typeof n.position.start.offset==`number`&&(n.position.start.column++,n.position.start.offset++,e.position.start=Object.assign({},n.position.start)))}}this.exit(e)}function Ma(e,t,n,r){let i=e.children[0],a=typeof e.checked==`boolean`&&i&&i.type===`paragraph`,o=`[`+(e.checked?`x`:` `)+`] `,s=n.createTracker(r);a&&s.move(o);let c=va.listItem(e,t,n,{...r,...s.current()});return a&&(c=c.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,l)),c;function l(e){return e+o}}function Na(){return[Lr(),si(),fi(),ya(),Oa()]}function Pa(e){return{extensions:[Rr(),ci(e),pi(),Da(e),ka()]}}var Fa={};function Ia(e){let t=this,n=e||Fa,r=t.data(),i=r.micromarkExtensions||=[],a=r.fromMarkdownExtensions||=[],o=r.toMarkdownExtensions||=[];i.push(_(n)),a.push(Na()),o.push(Pa(n))}var La={kind:`local`},Ra=/(?:^|\/)worktrees\/[^/]+\/\.tasks\/([0-9A-HJKMNP-TV-Z]{26})(?:\/(.*))?$/,za=/^[a-z][a-z0-9+.-]*:/i,Ba=/:(\d+)(?::\d+)?$/,Va=/#L(\d+)/,Ha=/^[^/?#:]*\.[^/?#:]*:\d+(?::\d+)?(?:[?#].*)?$/;function Ua(e){return Ha.test(e)}function Wa(e){let t=Ba.exec(e),n=Number(t?.[1]);return t===null||!(n>0)?{path:e}:{path:e.slice(0,t.index),line:n}}function Ga(e){let t=[];for(let n of e.split(`/`))if(n!==``&&n!==`.`){if(n===`..`){if(t.pop()===void 0)return null;continue}t.push(n)}return t.join(`/`)}function Ka(e){let t=e.lastIndexOf(`/`);return t===-1?``:e.slice(0,t)}function qa(e){try{return decodeURIComponent(e)}catch{return e}}function Ja(e,t){if(e===void 0||e===``)return La;if(e.startsWith(`#`)||e.startsWith(`//`)||za.test(e)&&!Ua(e))return null;let n=Wa(qa(e.replace(/[?#].*$/,``))),r=n.path,i=Number(Va.exec(e)?.[1]),a=n.line??(i>0?i:void 0),o=a===void 0?{}:{line:a},s=Ra.exec(r);if(s?.[1]!==void 0){let e=Ga(s[2]??``);return e===null?La:{kind:`task-file`,taskId:s[1],path:e,...o}}if(t!==void 0&&!r.startsWith(`/`)){let e=Ga(`${t.dir}/${r}`);return e===null?La:{kind:`task-file`,taskId:t.taskId,path:e,...o}}return La}var Ya={png:`image/png`,jpg:`image/jpeg`,jpeg:`image/jpeg`,gif:`image/gif`,webp:`image/webp`,avif:`image/avif`,bmp:`image/bmp`,ico:`image/x-icon`,svg:`image/svg+xml`};function Xa(e){let t=e.slice(e.lastIndexOf(`/`)+1),n=t.lastIndexOf(`.`);return n<=0?``:t.slice(n+1).toLowerCase()}function Za(e){return Ya[Xa(e)]??null}function Qa(e){let t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e+=1)n[e]=t.charCodeAt(e);return n}function $a(e){try{let t=new TextDecoder(`utf-8`,{fatal:!0}).decode(e);return t.includes(`\0`)?null:t}catch{return null}}function eo(e,t){let n=[],r=[],i=``,a=!1;for(let o=0;o<e.length;o+=1){let s=e.charAt(o);a?s===`"`?e.charAt(o+1)===`"`?(i+=`"`,o+=1):a=!1:i+=s:s===`"`&&i===``?a=!0:s===t?(r.push(i),i=``):s===`
28
- `||s===`\r`?(s===`\r`&&e.charAt(o+1)===`
29
- `&&(o+=1),r.push(i),n.push(r),r=[],i=``):i+=s}return(i!==``||r.length>0)&&(r.push(i),n.push(r)),n}function to(e,t){let n=Za(e);if(n!==null)return{kind:`image`,type:n};let r=$a(t);if(r===null)return{kind:`binary`};let i=Xa(e);return i===`md`||i===`markdown`?{kind:`markdown`,text:r}:i===`csv`||i===`tsv`?{kind:`table`,rows:eo(r,i===`csv`?`,`:` `)}:{kind:`text`,text:r}}var no=new Set([`p`,`h1`,`h2`,`h3`,`h4`,`h5`,`h6`,`li`,`pre`,`blockquote`,`table`,`tr`,`hr`]);function ro(e){return t=>{let n=[],r=e=>{e.tagName!==void 0&&no.has(e.tagName)&&e.position&&n.push({node:e,start:e.position.start.line,end:e.position.end.line});for(let t of e.children??[])r(t)};r(t);let{line:i}=e,a=n.filter(e=>e.start<=i&&i<=e.end).at(-1)??n.find(e=>e.start>i);if(a!==void 0){let e=a.node.properties?.className;a.node.properties={...a.node.properties,className:[...Array.isArray(e)?e:[],`line-target`]}}}}function io(e){if(e.status===`deleted`)return`deleted`;let t=e.added===null||e.removed===null?`binary`:e.status===`added`?`+${e.added}`:`+${e.added} −${e.removed}`;return e.status===`added`?`new · ${t}`:t}function ao(e){if(e===``)return[];let t=0;return e.split(`
30
- `).map(e=>{let n=/^@@ -\d+(?:,\d+)? \+(\d+)(?:,\d+)? @@/.exec(e);return n===null?e.startsWith(`-`)?{kind:`removed`,text:e}:e.startsWith(`\\`)?{kind:`note`,text:e}:(t+=1,{kind:e.startsWith(`+`)?`added`:`context`,text:e,line:t-1}):(t=Number(n[1]),{kind:`hunk`,text:e})})}function oo(e){let t=[...[...e.folders.values()].map(oo).toSorted((e,t)=>e.name.localeCompare(t.name)),...e.files.toSorted((e,t)=>e.name.localeCompare(t.name))],{name:n,path:r}=e,[i]=t;e.path!==``&&t.length===1&&i?.kind===`dir`&&(n=`${n}/${i.name}`,r=i.path,t=[...i.children]);let a=0,o;for(let e of t){a+=e.kind===`dir`?e.files:1;let t=e.kind===`dir`?e.lastChange:e.change.lastChange;t!==void 0&&(o===void 0||t.at>o.at)&&(o=t)}return{kind:`dir`,name:n,path:r,children:t,files:a,...o===void 0?{}:{lastChange:o}}}function so(e){let t={name:``,path:``,folders:new Map,files:[]};for(let n of e){let e=n.path.split(`/`),r=t;for(let t of e.slice(0,-1)){let e=r.folders.get(t);e===void 0&&(e={name:t,path:r.path===``?t:`${r.path}/${t}`,folders:new Map,files:[]},r.folders.set(t,e)),r=e}r.files.push({kind:`file`,name:e.at(-1)??n.path,change:n})}return oo(t)}function co(e,t=24){let n=new Set,r=e.children.length,i=e.children.filter(e=>e.kind===`dir`);for(let e=i.shift();e!==void 0;e=i.shift())r+e.children.length>t||(n.add(e.path),r+=e.children.length,i.push(...e.children.filter(e=>e.kind===`dir`)));return n}function lo(e){if(e<1024)return`${e} B`;let t=e/1024;return t<1024?`${t.toFixed(1)} KB`:`${(t/1024).toFixed(1)} MB`}var uo=new Set([`code`,`inlineCode`,`link`,`linkReference`,`html`]);function fo(e){let t=[],n=0;for(let r of e.matchAll(y)){let i=(r.index??0)+(r[1]?.length??0);i>n&&t.push({type:`text`,value:e.slice(n,i)});let a=r[2]??``;t.push({type:`mention`,data:{hName:`span`,hProperties:{className:[`mention`]},hChildren:[{type:`text`,value:`@${a}`}]}}),n=i+a.length+1}return n<e.length&&t.push({type:`text`,value:e.slice(n)}),t}function po(e){e.children!==void 0&&(e.children=e.children.flatMap(e=>e.type===`text`&&e.value!==void 0?fo(e.value):(uo.has(e.type)||po(e),[e])))}function mo(){return e=>po(e)}var ho=`text-fg-primary underline decoration-fg-muted underline-offset-2 hover:decoration-fg-primary`,go=(0,$.createContext)(void 0);function _o(e,t){return(0,$.useMemo)(()=>e==null?null:`data:${t};base64,${e}`,[e,t])}function vo({taskId:e,path:t,line:n,className:r=ho,children:i}){return(0,Q.jsx)(a,{to:`/task/$taskId/files/$`,params:{taskId:e,_splat:t},search:n===void 0?{}:{line:n},title:`${t===``?`The files`:t}${n===void 0?``:`:${n}`} on task/${e}`,className:r,children:i})}function yo({taskId:e,path:t,alt:r}){let i=n(e,t),a=_o(i.data?.kind===`file`?i.data.content:null,Za(t)??`application/octet-stream`),o=r===``?t.split(`/`).at(-1)??t:r;return(0,Q.jsx)(vo,{taskId:e,path:t,children:a===null?(0,Q.jsx)(`span`,{className:`text-meta`,children:i.isPending?`Loading ${o}…`:`${o} cannot be shown here`}):(0,Q.jsx)(`img`,{src:a,alt:r,className:`max-h-[32rem] max-w-full rounded-lg`})})}function bo({href:e,children:t}){return(0,Q.jsx)(`span`,{title:e===void 0||e===``?void 0:`${e}, on a runner's machine`,children:t})}function xo({href:e,children:t}){let n=(0,$.useContext)(go),r=s(e);if(r!==null)return(0,Q.jsx)(c,{kind:r.kind,id:r.id,place:r.place,children:t});let i=Ja(e,n);return i?.kind===`task-file`?(0,Q.jsx)(vo,{taskId:i.taskId,path:i.path,line:i.line,children:t}):i?.kind===`local`?(0,Q.jsx)(bo,{href:e,children:t}):(0,Q.jsx)(`a`,{href:e,target:`_blank`,rel:`noreferrer noopener`,children:t})}function So({src:e,alt:t}){let n=(0,$.useContext)(go),r=Ja(typeof e==`string`?e:void 0,n);if(r?.kind===`task-file`)return(0,Q.jsx)(yo,{taskId:r.taskId,path:r.path,alt:t??``});if(r?.kind===`local`){let n=typeof e==`string`?e:void 0;return(0,Q.jsx)(bo,{href:n,children:t===void 0||t===``?n:t})}return(0,Q.jsx)(`img`,{src:typeof e==`string`?e:void 0,alt:t,className:`max-h-[32rem] max-w-full rounded-lg`})}var Co={a:xo,img:So};function wo(e){return Ua(e)?e:Or(e)}function To({text:e,base:t,line:n}){let r=u(e),i=(0,$.useMemo)(()=>[Ia,[l,{index:r}],mo],[r]),a=(0,$.useMemo)(()=>n===void 0?[]:[[ro,{line:n}]],[n]),o=t?.taskId,s=t?.dir,c=(0,$.useMemo)(()=>o===void 0||s===void 0?void 0:{taskId:o,dir:s},[o,s]);return(0,Q.jsx)(`div`,{className:`board-markdown`,children:(0,Q.jsx)(go,{value:c,children:(0,Q.jsx)(wr,{remarkPlugins:i,rehypePlugins:a,components:Co,urlTransform:wo,children:e})})})}export{io as a,Za as c,Ka as d,ao as f,Qa as i,Ga as l,to as m,vo as n,Wa as o,lo as p,_o as r,so as s,To as t,co as u};
@@ -1 +0,0 @@
1
- import{Bn as e,Un as t,t as n,zn as r}from"./format-B6fjC0_a.js";import{u as i}from"./tasks-DCUj5w_d.js";import{a,s as o}from"./index-CyCty7a2.js";import{t as s}from"./Markdown-c9bCCLHg.js";var c=t(e(),1),l=r(),u=1400;function d({message:e,members:t,now:r,task:d,target:f=!1}){let p=e.body.length>u,[m,h]=(0,c.useState)(null),g=m??f,_=o(),v=e.author===`board`,y=e.step===void 0?null:i(e.step,d),b=(0,c.useRef)(null);return(0,c.useEffect)(()=>{f&&b.current?.scrollIntoView({block:`center`})},[f]),(0,l.jsxs)(`article`,{ref:b,"aria-current":f?`true`:void 0,className:`flex gap-3 px-4 py-2.5 ${v?`opacity-70`:``} ${f?`message-target`:``}`,children:[(0,l.jsx)(a,{name:e.author,members:t}),(0,l.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,l.jsxs)(`header`,{className:`flex min-w-0 items-baseline gap-2`,children:[(0,l.jsx)(`span`,{className:`text-title`,children:_(e.author)}),y===null?null:(0,l.jsx)(`span`,{className:`min-w-0 truncate rounded-md px-1.5 py-px text-[11px] ${y.tone}`,children:y.text}),(0,l.jsx)(`time`,{dateTime:e.ts,title:e.ts,className:`shrink-0 text-meta`,children:n(e.ts,r)})]}),(0,l.jsxs)(`div`,{className:p&&!g?`relative max-h-72 overflow-hidden`:``,children:[(0,l.jsx)(s,{text:e.body}),p&&!g?(0,l.jsx)(`div`,{className:`absolute inset-x-0 bottom-0 h-16 bg-linear-to-t from-surface-1 to-transparent`}):null]}),p?(0,l.jsx)(`button`,{type:`button`,onClick:()=>h(!g),className:`mt-1 text-xs text-fg-tertiary hover:text-fg-primary`,children:g?`Show less`:`Show more`}):null]})]})}export{d as t};
@@ -1 +0,0 @@
1
- import{W as e,Wt as t,b as n,r,t as i,y as a,zn as o}from"./format-B6fjC0_a.js";import{g as s,k as c,s as l}from"./index-CyCty7a2.js";import{n as u,t as d}from"./Pane-CLjdfBMM.js";import{n as f}from"./Overview-BveU1yJj.js";var p=o(),m=[{window:`24h`,label:`24 hours`},{window:`7d`,label:`7 days`},{window:`all`,label:`All time`}],h={stage:`a stage to take`,mention:`a mention`,user_post:`your post`,heartbeat:`a heartbeat`,task_done:`a finished task`,proposal_decided:`a decided proposal`,ops_event:`a signal`,onboarding:`joining`,manual:`your wake`},g=new Intl.DateTimeFormat(`en`,{month:`short`,day:`numeric`,timeZone:`UTC`});function _(e,t){return t===0?``:`${Math.round(e/t*100)}%`}function v(e){return e.toFixed(1).replace(/\.0$/,``)}function y({part:e,whole:t}){return(0,p.jsxs)(p.Fragment,{children:[e,(0,p.jsx)(`span`,{className:`ml-1.5 inline-block w-9 text-right text-fg-muted`,children:e===0?``:_(e,t)})]})}function b({children:e}){return(0,p.jsx)(`p`,{className:`text-sm text-fg-primary`,children:e})}function x({children:e}){return(0,p.jsx)(`p`,{className:`mt-1 text-meta`,children:e})}function S({label:e,columns:t,rows:n}){return n.length===0?null:(0,p.jsxs)(`table`,{"aria-label":e,className:`mt-3 w-full table-fixed text-sm`,children:[(0,p.jsxs)(`colgroup`,{children:[(0,p.jsx)(`col`,{}),t.slice(1).map(e=>(0,p.jsx)(`col`,{className:`w-24`},e))]}),(0,p.jsx)(`thead`,{children:(0,p.jsx)(`tr`,{children:t.map((e,t)=>(0,p.jsx)(`th`,{scope:`col`,className:`text-caps pb-1 font-normal ${t===0?`text-left`:`text-right`}`,children:e},e))})}),(0,p.jsx)(`tbody`,{children:n.map((e,t)=>(0,p.jsx)(`tr`,{className:`border-t border-line/50`,children:e.map((e,t)=>(0,p.jsx)(`td`,{className:`py-1.5 ${t===0?`pr-3 text-fg-primary`:`text-right text-fg-secondary tabular-nums`}`,children:e},t))},t))})]})}function C({name:e}){let n=l();return e===`user`?(0,p.jsx)(`span`,{children:n(e)}):(0,p.jsx)(t,{to:`/citizen/$name`,params:{name:e},className:`hover:underline`,children:e})}function w(e){return e.window===`24h`?1:e.window===`7d`?7:Math.max(1,e.decisions.byDay.length)}function T(){let{window:o=`7d`}=c({from:`/metrics`}),l=a(o),T=n(6e4),E=(0,p.jsx)(`nav`,{"aria-label":`Window`,className:`flex shrink-0 gap-1`,children:m.map(e=>(0,p.jsx)(t,{to:`/metrics`,search:{window:e.window},"aria-current":e.window===o?`page`:void 0,className:`rounded-md px-2 py-1 text-xs transition-colors ${e.window===o?`bg-surface-2 text-fg-primary`:`text-fg-tertiary hover:bg-surface-2/70 hover:text-fg-primary`}`,children:e.label},e.window))}),D=(0,p.jsx)(d,{title:`Metrics`,subtitle:`How the society works, counted from its event log`,trailing:E});if(l.data===void 0)return(0,p.jsxs)(p.Fragment,{children:[D,(0,p.jsx)(u,{children:l.error instanceof e?l.error.message:`Counting the event log…`})]});let{idle:O,sentBack:k,messages:A,latency:j,decisions:M,blocked:N}=l.data,P=w(l.data);return(0,p.jsxs)(p.Fragment,{children:[D,(0,p.jsxs)(`div`,{className:`flex-1 space-y-5 overflow-y-auto px-4 py-4`,children:[(0,p.jsxs)(f,{title:`Turns that did nothing`,children:[O.turns===0?(0,p.jsx)(x,{children:`No finished turns in this window.`}):(0,p.jsxs)(b,{children:[O.idle,` of `,O.turns,` turns changed nothing on the board`,` `,(0,p.jsx)(`span`,{className:`text-fg-muted`,children:_(O.idle,O.turns)})]}),(0,p.jsxs)(x,{children:[`A turn that took no board action: no post, claim, handover, plan, proposal, decision, or knowledge. Reflections are left out, since they write memory.`,O.unknown>0?` ${O.unknown} ${O.unknown===1?`turn`:`turns`} kept no transcript and could not be counted.`:``]}),(0,p.jsx)(S,{label:`By what woke them`,columns:[`Woken by`,`Turns`,`Did nothing`],rows:O.byTrigger.map(e=>[h[e.trigger]??e.trigger,e.turns,(0,p.jsx)(y,{part:e.idle,whole:e.turns},`idle`)])}),(0,p.jsx)(S,{label:`By citizen`,columns:[`Citizen`,`Turns`,`Did nothing`],rows:O.byAgent.map(e=>[(0,p.jsxs)(`span`,{children:[(0,p.jsx)(C,{name:e.agent}),e.role===null?null:(0,p.jsxs)(`span`,{className:`text-meta`,children:[` · `,e.role]})]},`who`),e.turns,(0,p.jsx)(y,{part:e.idle,whole:e.turns},`idle`)])})]}),(0,p.jsxs)(f,{title:`Work sent back`,children:[k.finished===0?(0,p.jsx)(x,{children:`No task finished in this window.`}):(0,p.jsxs)(b,{children:[k.tasksSentBack,` of `,k.finished,` finished tasks were sent back,`,` `,k.sendBacks,` `,k.sendBacks===1?`time`:`times`,` in all`]}),(0,p.jsx)(S,{label:`Where work came back from`,columns:[`Came back from`,`Times`],rows:k.byStage.map(e=>[`${e.project} · ${e.stage}`,e.count])}),(0,p.jsx)(S,{label:`Who sent work back`,columns:[`Sent back by`,`Times`],rows:k.bySender.map(e=>[(0,p.jsx)(C,{name:e.agent},`who`),e.count])})]}),(0,p.jsxs)(f,{title:`Messages per finished task`,children:[A.finished===0?(0,p.jsx)(x,{children:`No task finished in this window.`}):(0,p.jsxs)(b,{children:[v(A.messages/A.finished),` posts a task, across`,` `,A.finished,` finished `,A.finished===1?`task`:`tasks`]}),(0,p.jsx)(x,{children:`Posts in each finished task's thread, handovers included, the board's own left out.`}),(0,p.jsx)(S,{label:`By project`,columns:[`Project`,`Tasks`,`Posts a task`],rows:A.byProject.map(e=>[e.project,e.finished,v(e.messages/e.finished)])}),(0,p.jsx)(S,{label:`Most talked-over tasks`,columns:[`Task`,`Posts`],rows:A.busiest.map(e=>[(0,p.jsx)(s,{kind:`task`,id:e.taskId,children:e.title},`task`),e.messages])})]}),(0,p.jsxs)(f,{title:`Wake latency`,children:[j.medianMs===null||j.slowestMs===null?(0,p.jsx)(x,{children:`No mention led to a turn in this window.`}):(0,p.jsxs)(b,{children:[r(j.medianMs),` from a mention to its turn, at the median; the slowest took`,` `,r(j.slowestMs)]}),(0,p.jsxs)(x,{children:[`From a post that mentions a citizen to the start of its turn in the same conversation, debounce included.`,j.unanswered>0?` ${j.unanswered} ${j.unanswered===1?`mention has`:`mentions have`} no turn yet.`:``]}),(0,p.jsx)(S,{label:`By citizen`,columns:[`Citizen`,`Mentions`,`Median`,`Slowest`],rows:j.byAgent.map(e=>[(0,p.jsx)(C,{name:e.agent},`who`),e.mentions,r(e.medianMs),r(e.slowestMs)])})]}),(0,p.jsxs)(f,{title:`Your decisions`,children:[M.total===0?(0,p.jsx)(x,{children:`You decided nothing in this window.`}):(0,p.jsxs)(b,{children:[M.total,` `,M.total===1?`decision`:`decisions`,`, about`,` `,v(M.total/P),` a day`]}),(0,p.jsx)(x,{children:`Proposals you decided, questions to you that you answered, and stages you passed or sent back.`}),(0,p.jsx)(S,{label:`By day`,columns:[`Day`,`Proposals`,`Answers`,`Stages`],rows:M.byDay.map(e=>[g.format(new Date(`${e.day}T00:00:00Z`)),e.proposals,e.answers,e.stages])})]}),(0,p.jsx)(f,{title:`Blocked on a capability`,children:N.length===0?(0,p.jsx)(x,{children:`No task waited for a capability no runner offers.`}):(0,p.jsx)(`ul`,{className:`space-y-2`,children:N.map(e=>(0,p.jsxs)(`li`,{children:[(0,p.jsxs)(`p`,{className:`text-sm text-fg-primary`,children:[(0,p.jsx)(s,{kind:`task`,id:e.taskId,children:e.title??e.taskId}),(0,p.jsx)(`span`,{className:e.holds?`text-amber-300`:`text-fg-muted`,children:e.holds?` · blocked now`:` · cleared`})]}),(0,p.jsxs)(`p`,{className:`text-meta`,children:[e.summary,` · since `,i(e.firstAt,T)]})]},e.taskId))})})]})]})}export{T as MetricsView};
@@ -1 +0,0 @@
1
- import{Wt as e,b as t,n,t as r,x as i,zn as a}from"./format-B6fjC0_a.js";import{o}from"./governance-RBQ4Lam0.js";import{S as s,_ as c,s as l}from"./index-CyCty7a2.js";import{n as u,t as d}from"./Pane-CLjdfBMM.js";var f=a(),p=[{kind:`proposal`,label:`Proposals to decide`},{kind:`stage`,label:`Stages that name you`},{kind:`request`,label:`Asked of you`}],m=`block rounded-xl px-3 py-2.5 transition-colors hover:bg-surface-2/50`;function h({title:e,meta:t}){return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(`span`,{className:`text-title block truncate`,children:e}),(0,f.jsx)(`span`,{className:`mt-1 block truncate text-meta`,children:t})]})}function g(){let a=s(),g=i(),_=t(3e4),v=l(),y=e=>g.data?.find(t=>t.slug===e)?.name??e;return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(d,{title:`Needs you`,subtitle:a.length===0?`Nothing waits on you`:`${a.length} waiting on you, oldest first`}),(0,f.jsx)(`div`,{className:`flex-1 overflow-y-auto px-2 py-2`,children:a.length===0?(0,f.jsx)(u,{children:`Nothing waits on you. Proposals you may decide, stages that name you, and questions citizens ask you with @user appear here until you answer where they asked.`}):p.map(({kind:t,label:i})=>{let s=a.filter(e=>e.kind===t);return s.length===0?null:(0,f.jsxs)(`section`,{className:`mb-3`,children:[(0,f.jsxs)(`h3`,{className:`px-3 pt-2 pb-1 text-[11px] font-semibold tracking-wider text-fg-muted uppercase`,children:[i,` · `,s.length]}),(0,f.jsx)(`ul`,{children:s.map(t=>{if(t.kind===`proposal`)return(0,f.jsx)(`li`,{children:(0,f.jsx)(e,{to:`/proposal/$proposalId`,params:{proposalId:t.proposal.id},className:m,children:(0,f.jsx)(h,{title:o(t.proposal),meta:`proposed by ${v(t.proposal.proposedBy)} ${r(t.since,_)}`})})},t.proposal.id);if(t.kind===`stage`)return(0,f.jsx)(`li`,{children:(0,f.jsx)(e,{to:`/task/$taskId`,params:{taskId:t.task.id},className:m,children:(0,f.jsx)(h,{title:t.task.title,meta:`${t.stage.name}${t.stage.gate?` (gate)`:``} in ${y(t.task.project)} · waiting since ${r(t.since,_)}`})})},t.task.id);let i=`${v(t.message.author)} in ${t.thread===null?`#${t.message.channel}`:t.thread.title} ${r(t.since,_)}`,a=(0,f.jsx)(h,{title:(0,f.jsx)(c,{text:n(t.message.body,160),links:!1}),meta:i}),s=t.thread?.subject;return(0,f.jsx)(`li`,{children:s?.kind===`task`?(0,f.jsx)(e,{to:`/task/$taskId`,params:{taskId:s.id},className:m,children:a}):s?.kind===`proposal`?(0,f.jsx)(e,{to:`/proposal/$proposalId`,params:{proposalId:s.id},className:m,children:a}):t.thread===null?(0,f.jsx)(e,{to:`/c/$`,params:{_splat:t.message.channel},className:m,children:a}):(0,f.jsx)(e,{to:`/thread/$threadId`,params:{threadId:t.thread.id},className:m,children:a})},t.message.id)})})]},t)})})]})}export{g as NeedsYouView};
@@ -1,2 +0,0 @@
1
- import{A as e,B as t,Bn as n,Bt as r,C as i,E as a,M as o,R as s,Rn as c,Rt as l,S as u,Un as d,Ut as f,Vt as p,W as m,Wt as h,_ as g,b as _,ct as v,dt as y,ft as b,ht as x,lt as S,mt as ee,st as C,t as w,ut as te,x as ne,z as re,zn as ie,zt as ae}from"./format-B6fjC0_a.js";import{n as oe,t as T}from"./Button-Yoe21NQ2.js";import{t as se}from"./CliIcon-DbMYJdlU.js";import{a as ce}from"./tasks-DCUj5w_d.js";import{c as E,d as D,l as O,n as k,o as A,r as j,s as M}from"./governance-RBQ4Lam0.js";import{A as N,i as P,o as F,s as I}from"./index-CyCty7a2.js";import{p as L,t as R}from"./Markdown-c9bCCLHg.js";import{n as z,r as B}from"./ThreadForms-D2y5dXSC.js";import{n as V,t as le}from"./Pane-CLjdfBMM.js";import{t as H}from"./StickyList-7tAlUDCN.js";import{t as U}from"./BackLink-CD-iuy-h.js";import{StatusChip as W}from"./ProposalsView-BZHivSEm.js";import{t as ue}from"./SubjectThread-CCq6ZAnR.js";var G=d(n(),1),K=ie();function de({proposal:t,consequence:n}){let{api:r}=e(),i=c(),a=g(),[o,s]=(0,G.useState)(null),[l,u]=(0,G.useState)(``),d=(0,G.useRef)(null);(0,G.useEffect)(()=>{o!==null&&d.current?.focus()},[o]);let f=oe({mutationFn:()=>{let e=l.trim();return o===`reject`?r.reject({proposal_id:t.id,reason:e}):r.approve({proposal_id:t.id,...e===``?{}:{reason:e}})},onSuccess:()=>{let e=[[`proposals`],[`proposal`,t.id],[`threads`],[`thread`,t.id]];for(let t of e)i.invalidateQueries({queryKey:t});s(null),u(``)}}),p=(a.data??[]).find(e=>e.name===t.proposedBy&&e.status===`active`&&e.cli!==null),m=p===void 0?`Your decision is posted in the proposal's thread, which closes.`:`Your decision is posted in the proposal's thread, which closes, and wakes ${p.name}, who proposed it.`;if(o===null)return(0,K.jsxs)(`div`,{className:`flex items-center gap-2 border-t border-line px-4 py-3`,children:[(0,K.jsx)(`p`,{className:`min-w-0 flex-1 truncate text-meta`,children:`This proposal waits on you.`}),(0,K.jsx)(T,{onClick:()=>s(`reject`),children:`Reject`}),(0,K.jsx)(T,{variant:`primary`,onClick:()=>s(`approve`),children:`Approve`})]});let h=o===`approve`;return(0,K.jsxs)(`form`,{"aria-label":h?`Approve the proposal`:`Reject the proposal`,className:`space-y-2 border-t border-line bg-surface-2/20 p-3`,onSubmit:e=>{e.preventDefault(),f.mutate()},children:[(0,K.jsx)(`textarea`,{ref:d,value:l,rows:2,placeholder:h?`Why approve? Optional.`:`Why not? It is posted with the decision.`,"aria-label":h?`Reason for approving`:`Reason for rejecting`,onChange:e=>u(e.target.value),className:`${z} resize-none`}),(0,K.jsxs)(`p`,{className:`text-[11px] leading-relaxed text-fg-muted`,children:[h?n:`Nothing is created, and the proposal's thread closes.`,` `,m]}),(0,K.jsxs)(`div`,{className:`flex items-center justify-end gap-2`,children:[(0,K.jsx)(T,{onClick:()=>{s(null),f.reset()},children:`Cancel`}),(0,K.jsx)(T,{variant:`primary`,type:`submit`,disabled:f.isPending||!h&&l.trim()===``,children:f.isPending?`Deciding…`:h?`Confirm approval`:`Confirm rejection`})]}),(0,K.jsx)(B,{error:f.error})]})}function q({children:e}){return(0,K.jsx)(`dl`,{className:`mt-2 space-y-1.5`,children:e})}function J({label:e,children:t}){return(0,K.jsxs)(`div`,{className:`grid grid-cols-[9rem_1fr] gap-3 text-sm`,children:[(0,K.jsx)(`dt`,{className:`text-meta`,children:e}),(0,K.jsx)(`dd`,{className:`min-w-0 break-words text-fg-secondary`,children:t})]})}function Y(e){return e.length===0?`none`:e.join(`, `)}function X({name:e,change:t}){return(0,K.jsxs)(`span`,{className:`inline-block rounded-md px-1.5 py-px font-mono text-[11px] ${t===`added`?`bg-emerald-500/15 text-emerald-300`:t===`removed`?`bg-red-500/15 text-red-300 line-through`:`bg-surface-2/70 text-fg-tertiary`}`,children:[t===`added`?`+ `:t===`removed`?`− `:``,e]})}function Z({children:e}){return(0,K.jsx)(`div`,{className:`mt-2 rounded-xl bg-surface-2/30 px-3.5 py-3 shadow-[inset_0_0_0_1px_rgba(255,255,255,0.06)]`,children:e})}function Q({next:e,current:t,compare:n}){let r=t===void 0?null:E(t,e),i=r!==null&&r.verbsAdded.length===0&&r.verbsRemoved.length===0&&r.changes.length===0&&!r.purposeChanged;return(0,K.jsxs)(K.Fragment,{children:[n?r===null?(0,K.jsx)(`p`,{className:`mt-2 text-meta`,children:`A new role: no charter by this name exists yet.`}):i?(0,K.jsx)(`p`,{className:`mt-2 text-meta`,children:`The same as the charter the role has now.`}):(0,K.jsxs)(Z,{children:[(0,K.jsx)(`p`,{className:`text-caps`,children:`Against the charter it has now`}),r.verbsAdded.length+r.verbsRemoved.length===0?null:(0,K.jsxs)(`p`,{className:`mt-2 flex flex-wrap gap-1`,children:[r.verbsAdded.map(e=>(0,K.jsx)(X,{name:e,change:`added`},e)),r.verbsRemoved.map(e=>(0,K.jsx)(X,{name:e,change:`removed`},e))]}),r.changes.length===0?null:(0,K.jsx)(q,{children:r.changes.map(e=>(0,K.jsxs)(J,{label:e.field,children:[e.from,` → `,(0,K.jsx)(`span`,{className:`text-fg-primary`,children:e.to})]},e.field))}),r.purposeChanged?(0,K.jsx)(`p`,{className:`mt-2 text-xs text-fg-secondary`,children:`The purpose is rewritten.`}):null]}):null,(0,K.jsxs)(q,{children:[(0,K.jsx)(J,{label:`Role`,children:e.name}),(0,K.jsx)(J,{label:`Purpose`,children:e.purpose}),(0,K.jsx)(J,{label:`Verbs`,children:(0,K.jsx)(`span`,{className:`flex flex-wrap gap-1`,children:e.verbs.map(e=>(0,K.jsx)(X,{name:e},e))})}),(0,K.jsx)(J,{label:`Wake triggers`,children:Y(e.wakeTriggers)}),(0,K.jsx)(J,{label:`Replicas per project`,children:e.maxReplicas}),(0,K.jsx)(J,{label:`Warm session`,children:e.resident?`yes`:`no`}),(0,K.jsx)(J,{label:`Society role`,children:e.societyScope?`yes, in no project`:`no`}),(0,K.jsx)(J,{label:`Reflects`,children:e.reflects?`yes`:`no`})]})]})}function fe({proposal:e,reallocation:t,current:n,compare:r}){let{role:i,changes:a,description:o}=t,s=e.provision?.changed,c=Array.isArray(s)?s.filter(e=>typeof e==`string`):null;return r&&n!=null?(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(Q,{next:x(n,a),current:n,compare:!0}),(0,K.jsx)(q,{children:(0,K.jsx)(J,{label:`Why`,children:o})})]}):(0,K.jsxs)(q,{children:[(0,K.jsx)(J,{label:`Role`,children:i}),r&&n===null?(0,K.jsx)(J,{label:`Role now`,children:`none by this name; approving it will fail`}):null,c===null?(0,K.jsxs)(K.Fragment,{children:[a.maxReplicas===void 0?null:(0,K.jsx)(J,{label:`Replicas per project`,children:a.maxReplicas}),a.backlogThreshold===void 0?null:(0,K.jsx)(J,{label:`Backlog per member`,children:a.backlogThreshold}),a.wakeTriggers===void 0?null:(0,K.jsx)(J,{label:`Wake triggers`,children:Y(a.wakeTriggers)}),a.verbs===void 0?null:(0,K.jsx)(J,{label:`Verbs`,children:(0,K.jsx)(`span`,{className:`flex flex-wrap gap-1`,children:a.verbs.map(e=>(0,K.jsx)(X,{name:e},e))})})]}):(0,K.jsx)(J,{label:`Changed`,children:c.map(e=>(0,K.jsx)(`span`,{className:`block`,children:e},e))}),(0,K.jsx)(J,{label:`Why`,children:o})]})}function pe({proposal:e,slug:t,reason:n,members:r}){let i=ne(),a=s(t),o=i.data?.find(e=>e.slug===t),c=e.status===`proposed`,l=c?(r??[]).filter(e=>e.status===`active`&&e.memberships.includes(t)).map(e=>e.name):e.provision?.members??[],u=(a.data??[]).filter(ce).length;return(0,K.jsxs)(q,{children:[(0,K.jsxs)(J,{label:`Project`,children:[(0,K.jsx)(h,{to:`/p/$slug`,params:{slug:t},className:`hover:text-fg-primary`,children:o?.name??t}),o?.name===void 0||o.name===t?null:` · ${t}`]}),(0,K.jsx)(J,{label:c?`Members who leave`:`Members who left`,children:Array.isArray(l)?Y(l.filter(e=>typeof e==`string`)):`none`}),c?(0,K.jsx)(J,{label:`Tasks in play`,children:a.data===void 0?`reading…`:u===0?`none`:`${u}: approval is refused until they are done, abandoned, or filed elsewhere`}):null,(0,K.jsx)(J,{label:`Reason`,children:n}),(0,K.jsx)(J,{label:`After`,children:`Its open threads close and nothing more is posted, filed, or joined there; its channels, tasks, repository, and history stay readable.`})]})}function me({proposal:e,name:t}){let n=e.skillFiles,r=i(e.id,n!==void 0),[a,o]=(0,G.useState)(new Set);if(n===void 0)return(0,K.jsx)(`p`,{className:`mt-2 text-sm text-fg-secondary`,children:e.status===`proposed`?`The board takes skills/${t}/ from ${e.proposedBy}'s home when the turn that proposed it ends.`:`The board took no files for it.`});if(r.data===void 0)return(0,K.jsx)(`p`,{className:`mt-2 text-meta`,children:r.isError?`Could not read its files.`:`Loading…`});let s=r.data.find(e=>e.path===`SKILL.md`),c=r.data.filter(e=>e.path!==`SKILL.md`),l=e=>{o(t=>{let n=new Set(t);return n.delete(e)||n.add(e),n})};return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(q,{children:(0,K.jsxs)(J,{label:`Taken from`,children:[e.proposedBy,`'s home at`,` `,(0,K.jsx)(`span`,{className:`font-mono`,children:n.commit.slice(0,7)})]})}),s===void 0||s.text===null?null:(0,K.jsx)(Z,{children:(0,K.jsx)(R,{text:O(s.text)})}),c.length===0?null:(0,K.jsx)(`ul`,{className:`mt-2`,children:c.map(e=>{let t=a.has(e.path);return(0,K.jsxs)(`li`,{children:[(0,K.jsxs)(`button`,{type:`button`,"aria-expanded":t,title:e.path,onClick:()=>l(e.path),className:`group flex w-full items-baseline gap-2 rounded-md py-0.5 text-left text-sm hover:bg-surface-2/40 ${t?`bg-surface-2/30`:``}`,children:[(0,K.jsx)(`span`,{"aria-hidden":`true`,className:`inline-block w-2.5 shrink-0 text-[10px] text-fg-muted transition-transform ${t?`rotate-90`:``}`,children:`▸`}),(0,K.jsx)(`span`,{className:`min-w-0 truncate ${t?`text-fg-primary`:`text-fg-secondary group-hover:text-fg-primary`}`,children:e.path}),(0,K.jsxs)(`span`,{className:`shrink-0 text-meta`,children:[L(e.size),e.executable?` · executable`:``]})]}),t?e.text===null?(0,K.jsx)(`p`,{className:`mt-1 mb-2 ml-[18px] text-meta`,children:`A binary file; it is published as it is.`}):(0,K.jsxs)(`pre`,{className:`mt-1 mb-2 ml-[18px] max-h-96 overflow-auto rounded-lg bg-surface-2/40 p-3 font-mono text-[11px] leading-relaxed text-fg-secondary`,children:[e.text,e.truncated?`
2
- …`:``]}):null]},e.path)})})]})}function he({proposal:e,roles:t,members:n}){let r=e.status===`proposed`,{charter:i}=e;switch(e.kind){case`member`:{let e=te.safeParse(i);if(!e.success)break;let t=e.data;return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsxs)(q,{children:[(0,K.jsx)(J,{label:`Citizen`,children:(0,K.jsxs)(`span`,{className:`inline-flex items-center gap-1.5`,children:[(0,K.jsx)(se,{cli:t.cli,size:13}),t.name]})}),(0,K.jsx)(J,{label:`Role`,children:t.role}),(0,K.jsxs)(J,{label:`CLI and model`,children:[t.cli,` · `,t.model??`cli default`]}),(0,K.jsx)(J,{label:`Projects`,children:Y(t.memberships)}),(0,K.jsx)(J,{label:`Also follows`,children:Y(t.subscriptions)}),t.homeRunner===void 0?null:(0,K.jsx)(J,{label:`Runs on`,children:t.homeRunner})]}),t.seedInstructions===void 0?null:(0,K.jsxs)(Z,{children:[(0,K.jsx)(`p`,{className:`text-caps`,children:`Seed instructions`}),(0,K.jsx)(`div`,{className:`mt-1.5`,children:(0,K.jsx)(R,{text:t.seedInstructions})})]})]})}case`role`:{let n=M(e);if(n===null)break;return(0,K.jsx)(Q,{next:n,current:t?.find(e=>e.name===n.name),compare:r})}case`skill`:{let t=ee.safeParse(i);if(!t.success)break;return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsxs)(q,{children:[(0,K.jsx)(J,{label:`Skill`,children:t.data.name}),(0,K.jsx)(J,{label:`Summary`,children:t.data.summary})]}),t.data.body===void 0?(0,K.jsx)(me,{proposal:e,name:t.data.name}):(0,K.jsx)(Z,{children:(0,K.jsx)(R,{text:O(t.data.body)})})]})}case`channel`:{let e=v.safeParse(i);if(!e.success)break;return(0,K.jsxs)(q,{children:[(0,K.jsxs)(J,{label:`Channel`,children:[`#`,l(e.data.project,e.data.name)]}),(0,K.jsx)(J,{label:`Purpose`,children:e.data.purpose})]})}case`retirement`:{let e=b.safeParse(i);if(!e.success)break;let t=n?.find(t=>t.name===e.data.agent);return(0,K.jsxs)(q,{children:[(0,K.jsxs)(J,{label:`Citizen`,children:[(0,K.jsx)(F,{name:e.data.agent,members:n}),t===void 0?null:` · ${t.role}`]}),(0,K.jsx)(J,{label:`Holds now`,children:t===void 0?`unknown`:t.claimsHeld===1?`1 stage`:`${t.claimsHeld} stages`}),(0,K.jsx)(J,{label:`Reason`,children:e.data.reason})]})}case`archive`:{let t=C.safeParse(i);if(!t.success)break;return(0,K.jsx)(pe,{proposal:e,slug:t.data.project,reason:t.data.reason,members:n})}case`reallocation`:{let n=y.safeParse(i);if(!n.success){let e=S.safeParse(i);if(!e.success)break;return(0,K.jsx)(q,{children:(0,K.jsx)(J,{label:`Reallocation`,children:e.data.description})})}return(0,K.jsx)(fe,{proposal:e,reallocation:n.data,current:t===void 0?void 0:t.find(e=>e.name===n.data.role)??null,compare:r})}}return(0,K.jsx)(`pre`,{className:`mt-2 overflow-x-auto rounded-lg bg-surface-2/40 p-3 font-mono text-[11px] text-fg-tertiary`,children:JSON.stringify(i,null,2)})}var ge=p({agent:f().optional(),channel:f().optional(),role:f().optional(),skill:f().optional(),replaced:r().optional(),releasedTasks:ae(f()).optional(),project:f().optional()});function $({proposal:e}){let t=ge.safeParse(e.provision??{});if(e.provision===void 0||!t.success)return null;let n=t.data,r=`text-fg-primary underline decoration-fg-muted underline-offset-2`;if(e.kind===`member`&&n.agent!==void 0)return(0,K.jsxs)(`p`,{className:`mt-1`,children:[`Created`,` `,(0,K.jsx)(h,{to:`/citizen/$name`,params:{name:n.agent},className:r,children:n.agent}),`.`]});if(e.kind===`channel`&&n.channel!==void 0)return(0,K.jsxs)(`p`,{className:`mt-1`,children:[`Created`,` `,(0,K.jsxs)(h,{to:`/c/$`,params:{_splat:n.channel},className:r,children:[`#`,n.channel]}),`.`]});if(e.kind===`retirement`&&n.agent!==void 0){let e=n.releasedTasks?.length??0;return(0,K.jsxs)(`p`,{className:`mt-1`,children:[`Retired `,n.agent,`; `,e===1?`1 stage went`:`${e} stages went`,` back to open.`]})}return e.kind===`archive`&&n.project!==void 0?(0,K.jsxs)(`p`,{className:`mt-1`,children:[`Archived`,` `,(0,K.jsx)(h,{to:`/p/$slug`,params:{slug:n.project},className:r,children:n.project}),`; its members left and its threads closed.`]}):n.role===void 0?n.skill===void 0?null:(0,K.jsxs)(`p`,{className:`mt-1`,children:[n.replaced===!0?`Replaced`:`Published`,` the society's skill `,n.skill,`.`]}):(0,K.jsxs)(`p`,{className:`mt-1`,children:[n.replaced===!0?`Rewrote`:`Added`,` the role `,n.role,`.`]})}function _e(){let{proposalId:e}=N({from:`/proposal/$proposalId`}),n=u(e),r=g(),i=a(),s=o(),c=t(),l=_(3e4),d=I(),f=re(c.data?.some(t=>t.id===e)===!0?e:null);if(n.data===void 0)return(0,K.jsx)(V,{children:n.error instanceof m&&n.error.status===404?`There is no proposal ${e}.`:`Reading the proposal…`});let p=n.data,v=p.status===`proposed`,y=r.data?.find(e=>e.name===p.proposedBy)?.role,b=c.data?.find(e=>e.id===p.id),x=p.status===`rejected`?`Rejected`:`Approved`,S=k(p,{members:r.data??[],roles:i.data??[],skills:s.data??[]});return(0,K.jsxs)(K.Fragment,{children:[(0,K.jsx)(le,{leading:(0,K.jsx)(U,{fallback:(0,K.jsx)(h,{to:`/proposals`,"aria-label":`Back to the proposals`,className:`grid size-7 shrink-0 place-items-center rounded-lg text-fg-tertiary hover:bg-surface-2/70 hover:text-fg-primary`,children:`←`})}),title:A(p),subtitle:`${p.kind} proposal by ${d(p.proposedBy)} ${w(p.createdAt,l)}${v?` · for ${j(p,y)} to decide`:``}`,trailing:(0,K.jsx)(W,{status:p.status})}),(0,K.jsxs)(H,{stick:!1,follow:!1,ids:f.data?.messages.map(e=>e.id),className:`px-4 py-4`,children:[v?(0,K.jsxs)(`p`,{className:`rounded-lg bg-sky-400/10 px-3 py-2 text-xs leading-relaxed text-sky-200`,children:[`If approved: `,S]}):(0,K.jsxs)(`div`,{className:`rounded-lg bg-surface-2/40 px-3 py-2 text-xs leading-relaxed text-fg-secondary`,children:[(0,K.jsxs)(`p`,{children:[x,` by `,d(p.decidedBy??`someone`),p.decidedAt===void 0?``:` ${w(p.decidedAt,l)}`,p.reason===void 0?`.`:`: ${p.reason}`]}),(0,K.jsx)($,{proposal:p})]}),p.body.trim()===``||b!==void 0?null:(0,K.jsxs)(`section`,{className:`mt-5`,children:[(0,K.jsx)(`h3`,{className:`text-section`,children:`Why`}),(0,K.jsx)(`div`,{className:`mt-2`,children:(0,K.jsx)(R,{text:p.body})})]}),(0,K.jsxs)(`section`,{className:`mt-5 border-t border-line pt-4`,children:[(0,K.jsx)(`h3`,{className:`text-section`,children:v?`What it would make`:p.status===`provisioned`?`What it made`:`What it proposed`}),(0,K.jsx)(he,{proposal:p,roles:i.data,members:r.data})]}),(0,K.jsxs)(`section`,{"aria-label":`Thread`,className:`mt-5 border-t border-line pt-4`,children:[(0,K.jsx)(`h3`,{className:`text-section`,children:`Thread`}),b===void 0?(0,K.jsx)(`p`,{className:`mt-2 text-meta`,children:c.data===void 0?`Reading the thread…`:`This proposal is older than proposal threads; its thread opens when it is decided.`}):(0,K.jsx)(ue,{thread:b,now:l,empty:`Nothing said yet. The pitch and the decision are posted here.`})]})]},p.id),b?.state===`open`?(0,K.jsx)(P,{target:{threadId:p.id},placeholder:`Write in the proposal's thread`}):null,D(p)?(0,K.jsx)(de,{proposal:p,consequence:S}):null]})}export{_e as ProposalView};